Skip to content
This repository has been archived by the owner on May 14, 2024. It is now read-only.

Commit

Permalink
chore: un-pin pylint (required hack in pylintrc_tweaks)
Browse files Browse the repository at this point in the history
  • Loading branch information
bradenmacdonald committed Oct 12, 2022
1 parent 7994665 commit 701ffe2
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 24 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ html_coverage: ## Generate HTML coverage report

quality: ## Run quality checks
${VENV_BIN}/pycodestyle --config=pycodestyle blockstore *.py
${VENV_BIN}/pylint --django-settings-module=blockstore.settings.test --rcfile=pylintrc blockstore *.py
${VENV_BIN}/pylint --django-settings-module=blockstore.settings.test blockstore *.py

validate: test quality ## Run tests and quality checks

Expand Down
2 changes: 1 addition & 1 deletion blockstore/apps/bundles/store.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
from django.core.files.base import ContentFile, File
from django.dispatch import Signal
import attr
from pyblake2 import blake2b
from pyblake2 import blake2b # pylint:disable=no-name-in-module

from .links import Dependency, Link, LinkCollection, LinkChangeSet
from .storage import default_asset_storage
Expand Down
2 changes: 1 addition & 1 deletion blockstore/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
urlpatterns += make_docs_urls(api_info)

if settings.DEBUG: # pragma: no cover
import debug_toolbar # pylint: disable=import-error
import debug_toolbar # pylint: disable=import-error,useless-suppression
urlpatterns.append(url(r'^__debug__/', include(debug_toolbar.urls)))

if settings.DEBUG or os.environ['DJANGO_SETTINGS_MODULE'] == 'blockstore.settings.test':
Expand Down
5 changes: 3 additions & 2 deletions pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,13 @@
# SERIOUSLY.
#
# ------------------------------
# Generated by edx-lint version: 5.2.5
# Generated by edx-lint version: 5.3.0
# ------------------------------
[MASTER]
ignore = ,migrations, settings, setup.py, wsgi.py
persistent = yes
load-plugins = edx_lint.pylint,pylint_django,pylint_celery
init-hook = 'import sys; sys.path.append(".")'

[MESSAGES CONTROL]
enable =
Expand Down Expand Up @@ -382,4 +383,4 @@ int-import-graph =
[EXCEPTIONS]
overgeneral-exceptions = Exception

# af4b89c321cd6c4fd061d9367951e9d91f546565
# 7893f9eb6eac7abb607e7296f02caa1230b3e738
2 changes: 2 additions & 0 deletions pylintrc_tweaks
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
[MASTER]
ignore+= ,migrations, settings, setup.py, wsgi.py
# For some reason, pylint 2.15+ isn't working without this hack
init-hook='import sys; sys.path.append(".")'

[BASIC]
const-rgx = (([A-Z_][A-Z0-9_]*)|(__.*__)|log|urlpatterns|logger|User)$
Expand Down
7 changes: 0 additions & 7 deletions requirements/constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,3 @@
boto3<2.0

django>3.2,<3.3

# pylint 2.15.0 through 2.15.4 is currently not working with Blockstore
# it gives "django.core.exceptions.ImproperlyConfigured" due to
# "ModuleNotFoundError: No module named 'blockstore'"
# This is a temporary constraint while we investigate the issue, so as not to
# block other upgrades; it should be removed ASAP.
pylint<2.15.0
8 changes: 2 additions & 6 deletions requirements/local.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ asgiref==3.5.2
# via
# -r requirements/test.txt
# django
astroid==2.11.7
astroid==2.12.11
# via
# -r requirements/test.txt
# pylint
Expand Down Expand Up @@ -265,9 +265,8 @@ pyjwt[crypto]==2.5.0
# -r requirements/test.txt
# edx-auth-backends
# social-auth-core
pylint==2.14.5
pylint==2.15.4
# via
# -c requirements/constraints.txt
# -r requirements/test.txt
# edx-lint
# pylint-celery
Expand Down Expand Up @@ -447,6 +446,3 @@ wrapt==1.14.1
# via
# -r requirements/test.txt
# astroid

# The following packages are considered to be unsafe in a requirements file:
# setuptools
8 changes: 2 additions & 6 deletions requirements/test.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ asgiref==3.5.2
# via
# -r requirements/base.txt
# django
astroid==2.11.7
astroid==2.12.11
# via
# -r requirements/test.in
# pylint
Expand Down Expand Up @@ -207,9 +207,8 @@ pyjwt[crypto]==2.5.0
# -r requirements/base.txt
# edx-auth-backends
# social-auth-core
pylint==2.14.5
pylint==2.15.4
# via
# -c requirements/constraints.txt
# edx-lint
# pylint-celery
# pylint-django
Expand Down Expand Up @@ -329,6 +328,3 @@ urllib3==1.26.12
# requests
wrapt==1.14.1
# via astroid

# The following packages are considered to be unsafe in a requirements file:
# setuptools

0 comments on commit 701ffe2

Please sign in to comment.