Skip to content

Commit

Permalink
ci: fix isort
Browse files Browse the repository at this point in the history
  • Loading branch information
danihodovic committed Jun 19, 2024
1 parent 8f7f87d commit ddb1d6f
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ ignore-imports=yes
ignore-signatures=yes

# Minimum lines number of a similarity.
min-similarity-lines=4
min-similarity-lines=50


[SPELLING]
Expand Down
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,10 @@ pytest-django = "4.1.0"
[tool.pytest.ini_options]
addopts = "--ds=tests.settings --reuse-db --pdbcls=pudb.debugger:Debugger"
python_files = "tests.py test_*.py"

[tool.black]
exclude = ".*(venv|virtualenv|.poetry|migrations|node_modules)"

[tool.isort]
skip_glob = "**/migrations/*.py,**/fixtures/*.py"
profile = "black"
1 change: 1 addition & 0 deletions sample_deployment/manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ def main():
"""Run administrative tasks."""
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "sample_deployment.settings")
try:
# pylint: disable=import-outside-toplevel
from django.core.management import execute_from_command_line
except ImportError as exc:
raise ImportError(
Expand Down
4 changes: 2 additions & 2 deletions sample_deployment/sample_deployment/example/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class HomePageView(TemplateView):
def get_context_data(self, **kwargs):
context = super().get_context_data(**kwargs)
if self.request.user.is_authenticated:
social_account = SocialAccount.objects.first()
social_account = SocialAccount.objects.first() # pylint: disable=no-member
if social_account:
context["extra_data"] = social_account.extra_data
return context
Expand All @@ -22,7 +22,7 @@ class SocialAccountMetadataView(TemplateView):
def get_context_data(self, **kwargs):
context = super().get_context_data(**kwargs)
if self.request.user.is_authenticated:
social_account = SocialAccount.objects.first()
social_account = SocialAccount.objects.first() # pylint: disable=no-member
if social_account:
context["extra_data"] = social_account.extra_data
json_str = json.dumps(social_account.extra_data, indent=2)
Expand Down

0 comments on commit ddb1d6f

Please sign in to comment.