Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Widen django-gcp dependencies #41

Merged
merged 4 commits into from
May 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
130 changes: 67 additions & 63 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,70 +7,74 @@
"service": "web",
"workspaceFolder": "/workspace",
// Set *default* container specific settings.json values on container create.
"settings": {
"austin.mode": "Wall time",
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
"esbonio.server.enabled": true,
"esbonio.sphinx.confDir": "${workspaceFolder}/docs/source",
"jupyter.widgetScriptSources": ["jsdelivr.com", "unpkg.com"],
"prettier.prettierPath": "/usr/local/prettier",
"python.defaultInterpreterPath": "/usr/local/bin/python",
"python.formatting.autopep8Path": "/usr/local/py-utils/bin/autopep8",
"python.formatting.blackPath": "/usr/local/py-utils/bin/black",
"python.formatting.provider": "black",
"python.formatting.yapfPath": "/usr/local/py-utils/bin/yapf",
"python.languageServer": "Pylance",
"python.linting.banditPath": "/usr/local/py-utils/bin/bandit",
"python.linting.enabled": true,
"python.linting.flake8Path": "/usr/local/py-utils/bin/flake8",
"python.linting.mypyPath": "/usr/local/py-utils/bin/mypy",
"python.linting.pycodestylePath": "/usr/local/py-utils/bin/pycodestyle",
"python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle",
// Line length to match black settings
// Disabling specific messages:
// - To find the details do: /usr/local/py-utils/bin/pylint --list-msgs
// - Disable missing-module-docstring (C0114) because we don't document modules routinely, just their members
// - Disable invalid-name (C0103) because pylint thinks that eg 'x', 'df', 'np' are invalid due to their lengths
"python.linting.pylintArgs": [
"--max-line-length=120",
"--disable=missing-module-docstring,invalid-name",
"--load-plugins",
"pylint_django",
"--django-settings-module",
"tests.settings"
],
"python.linting.pylintEnabled": true,
"python.linting.pylintPath": "/usr/local/py-utils/bin/pylint",
"python.testing.pytestEnabled": true,
"python.testing.pytestPath": "/usr/local/bin/pytest",
"python.testing.pytestArgs": [],
"python.testing.cwd": "/workspace",
// Scrolling the editor is a nice idea but it doesn't work, always out of sync and impossible to manage
"restructuredtext.preview.scrollEditorWithPreview": false,
"restructuredtext.preview.scrollPreviewWithEditor": false,
"terminal.integrated.defaultProfile.linux": "zsh"
},
"customizations": {
"vscode": {
"settings": {
"austin.mode": "Wall time",
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
"esbonio.server.enabled": true,
"esbonio.sphinx.confDir": "${workspaceFolder}/docs/source",
"jupyter.widgetScriptSources": ["jsdelivr.com", "unpkg.com"],
"prettier.prettierPath": "/usr/local/prettier",
"python.defaultInterpreterPath": "/usr/local/bin/python",
"python.formatting.autopep8Path": "/usr/local/py-utils/bin/autopep8",
"python.formatting.blackPath": "/usr/local/py-utils/bin/black",
"python.formatting.provider": "black",
"python.formatting.yapfPath": "/usr/local/py-utils/bin/yapf",
"python.languageServer": "Pylance",
"python.linting.banditPath": "/usr/local/py-utils/bin/bandit",
"python.linting.enabled": true,
"python.linting.flake8Path": "/usr/local/py-utils/bin/flake8",
"python.linting.mypyPath": "/usr/local/py-utils/bin/mypy",
"python.linting.pycodestylePath": "/usr/local/py-utils/bin/pycodestyle",
"python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle",
// Line length to match black settings
// Disabling specific messages:
// - To find the details do: /usr/local/py-utils/bin/pylint --list-msgs
// - Disable missing-module-docstring (C0114) because we don't document modules routinely, just their members
// - Disable invalid-name (C0103) because pylint thinks that eg 'x', 'df', 'np' are invalid due to their lengths
"python.linting.pylintArgs": [
"--max-line-length=120",
"--disable=missing-module-docstring,invalid-name",
"--load-plugins",
"pylint_django",
"--django-settings-module",
"tests.settings"
],
"python.linting.pylintEnabled": true,
"python.linting.pylintPath": "/usr/local/py-utils/bin/pylint",
"python.testing.pytestEnabled": true,
"python.testing.pytestPath": "/usr/local/bin/pytest",
"python.testing.pytestArgs": [],
"python.testing.cwd": "/workspace",
// Scrolling the editor is a nice idea but it doesn't work, always out of sync and impossible to manage
"restructuredtext.preview.scrollEditorWithPreview": false,
"restructuredtext.preview.scrollPreviewWithEditor": false,
"terminal.integrated.defaultProfile.linux": "zsh"
},

// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"[email protected]",
"irongeek.vscode-env",
"lextudio.restructuredtext",
"me-dutour-mathieu.vscode-github-actions",
"mikestead.dotenv",
"ms-python.python",
"ms-python.vscode-pylance",
"ms-toolsai.jupyter",
"ms-toolsai.jupyter-renderers",
"ms-toolsai.jupyter-keymap",
"ms-vsliveshare.vsliveshare",
"p403n1x87.austin-vscode",
"ritwickdey.liveserver",
"shamanu4.django-intellisense",
"thebarkman.vscode-djaneiro",
"trond-snekvik.simple-rst"
],
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"[email protected]",
"irongeek.vscode-env",
"lextudio.restructuredtext",
"me-dutour-mathieu.vscode-github-actions",
"mikestead.dotenv",
"ms-python.python",
"ms-python.vscode-pylance",
"ms-toolsai.jupyter",
"ms-toolsai.jupyter-renderers",
"ms-toolsai.jupyter-keymap",
"ms-vsliveshare.vsliveshare",
"p403n1x87.austin-vscode",
"ritwickdey.liveserver",
"shamanu4.django-intellisense",
"thebarkman.vscode-djaneiro",
"trond-snekvik.simple-rst"
]
}
},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [80, 443, 5000, 7045, 7046, 7047, 7048, 7049, 8000, 8080],
Expand Down
21 changes: 8 additions & 13 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,17 @@ repos:
- id: black
args: ["--line-length", "120"]

- repo: https://gitlab.com/pycqa/flake8
rev: 3.8.1
- repo: https://github.com/pycqa/flake8
rev: 6.0.0
hooks:
- id: flake8
args: ["--config=setup.cfg"]
language_version: python3

- repo: https://github.com/timothycrosley/isort
rev: 5.0.9
- repo: https://github.com/pycqa/isort
rev: 5.11.5
hooks:
- id: isort
require_serial: true

- repo: https://github.com/windpioneers/pre-commit-hooks
rev: 0.0.5
Expand All @@ -58,21 +57,17 @@ repos:
- id: prettier

- repo: https://github.com/octue/pre-commit-hooks
rev: 0.6.0
rev: 0.8.1
hooks:
- id: check-commit-message-is-conventional
stages: [commit-msg]
args:
- --maximum-body-line-length=2000

- repo: https://github.com/thclark/pre-commit-sphinx
rev: 0.0.1
hooks:
- id: build-docs
language_version: python3
# Use dev dependencies to install sphinx and related libraries
# as well as installing the root module (required for autodoc)
additional_dependencies:
- "Sphinx>=4,<5"
- "sphinx-rtd-theme==1.0.0"
- "sphinx-tabs==3.2.0"
- "sphinx-math-dollar==1.2.0"
- "sphinx-charts==0.1.2"
- "django_twined@file://localhost/workspace#egg=django_twined"
1 change: 0 additions & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
"sphinx_tabs.tabs",
"sphinx.ext.mathjax",
"sphinx.ext.ifconfig",
"sphinx_charts.charts",
]

# Add any paths that contain templates here, relative to this directory.
Expand Down
17 changes: 1 addition & 16 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "django-twined"
version = "0.4.1"
version = "0.4.2"
description = "A django app to manage octue services"
authors = ["Tom Clark <[email protected]>"]
license = "MIT"
Expand All @@ -25,7 +25,7 @@ django = ">=3.0,<4.0"
channels = ">=3.0,<4.0"
octue = "^0.39.0"
pika = "^1.2.0"
django-gcp = "^0.7.3"
django-gcp = ">=0.7.3,<0.10"
django-jsoneditor = "^0.2.2"
django-model-utils = "^4.2.0"

Expand All @@ -45,7 +45,6 @@ pytest-django = "^4.5.2"
pytest-sugar = "^0.9.4"
sphinx-rtd-theme = "^1.0.0"
sphinx-tabs = "^3.2.0"
sphinx-charts = "^0.1.2"
Sphinx = "^4.4.0"
tox = "^3.24.5"
tox-gh-actions = "^2.9.1"
Expand Down