-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #550 from UW-GAC/maint/use-ruff
Switch to ruff
- Loading branch information
Showing
98 changed files
with
1,677 additions
and
4,887 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
line-length = 120 | ||
exclude = [ | ||
"**/migrations/**", | ||
"*/static/CACHE/*", | ||
"venv", | ||
"docs", | ||
] | ||
|
||
[lint] | ||
extend-select = [ | ||
"E", | ||
"F", | ||
"W", # pycodestyle warnings | ||
"I", # isort | ||
"DJ", # flake8-django | ||
"E501", # line-too-long | ||
] | ||
|
||
[lint.isort] | ||
known-first-party = ["primed", "config", ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -55,27 +55,15 @@ | |
|
||
|
||
# Add accounts to the auth domains. | ||
account_1 = AccountFactory.create( | ||
user__name="Adrienne", verified=True, email="[email protected]" | ||
) | ||
account_2 = AccountFactory.create( | ||
user__name="Ben", verified=True, email="[email protected]" | ||
) | ||
account_3 = AccountFactory.create( | ||
user__name="Matt", verified=True, email="[email protected]" | ||
) | ||
account_4 = AccountFactory.create( | ||
user__name="Stephanie", verified=True, email="[email protected]" | ||
) | ||
account_1 = AccountFactory.create(user__name="Adrienne", verified=True, email="[email protected]") | ||
account_2 = AccountFactory.create(user__name="Ben", verified=True, email="[email protected]") | ||
account_3 = AccountFactory.create(user__name="Matt", verified=True, email="[email protected]") | ||
account_4 = AccountFactory.create(user__name="Stephanie", verified=True, email="[email protected]") | ||
|
||
# Set up collab analysis workspace one | ||
# analyst group | ||
GroupAccountMembershipFactory.create( | ||
account=account_1, group=collaborative_analysis_workspace_1.analyst_group | ||
) | ||
GroupAccountMembershipFactory.create( | ||
account=account_2, group=collaborative_analysis_workspace_1.analyst_group | ||
) | ||
GroupAccountMembershipFactory.create(account=account_1, group=collaborative_analysis_workspace_1.analyst_group) | ||
GroupAccountMembershipFactory.create(account=account_2, group=collaborative_analysis_workspace_1.analyst_group) | ||
# auth domains | ||
GroupAccountMembershipFactory.create( | ||
account=account_1, | ||
|
@@ -84,12 +72,8 @@ | |
|
||
# Set up collab analysis workspace two | ||
# analyst group | ||
GroupAccountMembershipFactory.create( | ||
account=account_3, group=collaborative_analysis_workspace_2.analyst_group | ||
) | ||
GroupAccountMembershipFactory.create( | ||
account=account_4, group=collaborative_analysis_workspace_2.analyst_group | ||
) | ||
GroupAccountMembershipFactory.create(account=account_3, group=collaborative_analysis_workspace_2.analyst_group) | ||
GroupAccountMembershipFactory.create(account=account_4, group=collaborative_analysis_workspace_2.analyst_group) | ||
# auth domains | ||
GroupAccountMembershipFactory.create( | ||
account=account_3, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,15 +57,11 @@ | |
# in our apache configuration. Having in both places causes duplicate header | ||
SECURE_HSTS_SECONDS = 0 | ||
# https://docs.djangoproject.com/en/dev/ref/settings/#secure-hsts-include-subdomains | ||
SECURE_HSTS_INCLUDE_SUBDOMAINS = env.bool( | ||
"DJANGO_SECURE_HSTS_INCLUDE_SUBDOMAINS", default=True | ||
) | ||
SECURE_HSTS_INCLUDE_SUBDOMAINS = env.bool("DJANGO_SECURE_HSTS_INCLUDE_SUBDOMAINS", default=True) | ||
# https://docs.djangoproject.com/en/dev/ref/settings/#secure-hsts-preload | ||
SECURE_HSTS_PRELOAD = env.bool("DJANGO_SECURE_HSTS_PRELOAD", default=True) | ||
# https://docs.djangoproject.com/en/dev/ref/middleware/#x-content-type-options-nosniff | ||
SECURE_CONTENT_TYPE_NOSNIFF = env.bool( | ||
"DJANGO_SECURE_CONTENT_TYPE_NOSNIFF", default=True | ||
) | ||
SECURE_CONTENT_TYPE_NOSNIFF = env.bool("DJANGO_SECURE_CONTENT_TYPE_NOSNIFF", default=True) | ||
# Since we have disabled HSTS above we get a warning when running check --deploy | ||
# we are manually silencing this as we have verified apache is enforcing | ||
# https://docs.djangoproject.com/en/dev/ref/checks/#security | ||
|
@@ -79,9 +75,7 @@ | |
# ------------------------------------------------------------------------------ | ||
# https://docs.djangoproject.com/en/dev/ref/settings/#default-from-email | ||
DEFAULT_FROM_EMAIL = env( | ||
"DJANGO_DEFAULT_FROM_EMAIL", default="gac-django <[email protected]>" | ||
) | ||
DEFAULT_FROM_EMAIL = env("DJANGO_DEFAULT_FROM_EMAIL", default="gac-django <[email protected]>") | ||
# https://docs.djangoproject.com/en/dev/ref/settings/#server-email | ||
SERVER_EMAIL = env("DJANGO_SERVER_EMAIL", default=DEFAULT_FROM_EMAIL) | ||
# https://docs.djangoproject.com/en/dev/ref/settings/#email-subject-prefix | ||
|
@@ -130,12 +124,7 @@ | |
"()": "maintenance_mode.logging.RequireNotMaintenanceMode503", | ||
}, | ||
}, | ||
"formatters": { | ||
"verbose": { | ||
"format": "%(levelname)s %(asctime)s %(module)s " | ||
"%(process)d %(thread)d %(message)s" | ||
} | ||
}, | ||
"formatters": {"verbose": {"format": "%(levelname)s %(asctime)s %(module)s " "%(process)d %(thread)d %(message)s"}}, | ||
"handlers": { | ||
"mail_admins": { | ||
"level": "ERROR", | ||
|
Oops, something went wrong.