Skip to content

Commit

Permalink
Merge pull request #49 from networktocode-llc/devel-meet-reqs
Browse files Browse the repository at this point in the history
Devel meet reqs
  • Loading branch information
itdependsnetworks authored Nov 21, 2020
2 parents b73de33 + 3e1e3a8 commit 9a3a723
Show file tree
Hide file tree
Showing 153 changed files with 4,785 additions and 2,294 deletions.
5 changes: 5 additions & 0 deletions .bandit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
skips: []
# No need to check for security issues in the test scripts!
exclude_dirs:
- "./tests/"
4 changes: 4 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
**/*.pyc
**/*.pyo
**/*.log
docs/_build
4 changes: 4 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[flake8]
# E501: Line length is enforced by Black, so flake8 doesn't need to check it
# W503: Black disagrees with this rule, as does PEP 8; Black wins
ignore = E501, W503
132 changes: 129 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,130 @@
.pyc
__pycache__
.venv/
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
.python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# PEP 582; used by e.g. github.com/David-OConnor/pyflow
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/
jsonschema_testing.egg-info
5 changes: 5 additions & 0 deletions .pydocstyle.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[pydocstyle]
convention = google
inherit = false
match = (?!__init__).*\.py
match-dir = (?!tests)[^\.].*
17 changes: 17 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
language: "python"
services:
- "docker"
python:
- 3.7
- 3.8

before_script:
- "pip install invoke"
- "invoke build-test-container -p $TRAVIS_PYTHON_VERSION"
script:
- "invoke black -p $TRAVIS_PYTHON_VERSION"
- "invoke yamllint -p $TRAVIS_PYTHON_VERSION"
- "invoke pylint -p $TRAVIS_PYTHON_VERSION"
- "invoke pytest -p $TRAVIS_PYTHON_VERSION"
- "invoke pydocstyle -p $TRAVIS_PYTHON_VERSION"
57 changes: 37 additions & 20 deletions .yamllint
Original file line number Diff line number Diff line change
@@ -1,41 +1,58 @@
---
extends: "default"

rules:
indentation:
spaces: 2
indent-sequences: "consistent"
braces:
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: -1
max-spaces-inside-empty: -1
brackets:
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: -1
max-spaces-inside-empty: -1
colons:
max-spaces-before: 0
max-spaces-after: 1
hyphens:
max-spaces-after: 1
commas:
max-spaces-before: 0
min-spaces-after: 1
max-spaces-after: 1
comments:
level: "warning"
require-starting-space: true
ignore-shebangs: true
min-spaces-from-content: 1
min-spaces-from-content: 2
comments-indentation:
level: "warning"
document-end: "disable"
document-start:
present: true
empty-lines:
max: 1
max: 2
max-start: 0
max-end: 0
quoted-strings:
quote-type: "double"
empty-values:
forbid-in-block-mappings: true
forbid-in-flow-mappings: true
forbid-in-block-mappings: false
forbid-in-flow-mappings: false
hyphens:
max-spaces-after: 3
indentation:
spaces: "consistent"
indent-sequences: true
check-multi-line-strings: false
key-duplicates: "enable"
key-ordering: "disable"
line-length:
max: 120
allow-non-breakable-words: true
allow-non-breakable-inline-mappings: false
new-line-at-end-of-file: "enable"
quoted-strings:
quote-type: "double"
new-lines:
type: "unix"
octal-values:
forbid-implicit-octal: false
forbid-explicit-octal: false
trailing-spaces: "enable"
truthy:
level: "warning"
trailing-spaces: {}

ignore: |
tests/mocks/
venv/
.venv
12 changes: 12 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ARG PYTHON

FROM python:${PYTHON}-slim

RUN pip install --upgrade pip \
&& pip install poetry

WORKDIR /local
COPY pyproject.toml /local

RUN poetry config virtualenvs.create false \
&& poetry install --no-interaction --no-ansi
Loading

0 comments on commit 9a3a723

Please sign in to comment.