Skip to content

Commit 1b6b3af

Browse files
authored
Merge pull request #3010 from GSA/main
10/15/25 Production Release
2 parents 3f5e21d + f716b7a commit 1b6b3af

File tree

363 files changed

+6344
-10749
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

363 files changed

+6344
-10749
lines changed

.cfignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,6 @@ target/
7979
.vscode
8080

8181
# Frontend dependencies and compiled assets
82-
app/assets/stylesheets/govuk_template/.sass-cache/
8382
.sass-cache/
8483
cache/
8584
node_modules

.ds.baseline

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@
161161
"filename": "app/config.py",
162162
"hashed_secret": "577a4c667e4af8682ca431857214b3a920883efc",
163163
"is_verified": false,
164-
"line_number": 120,
164+
"line_number": 118,
165165
"is_secret": false
166166
}
167167
],
@@ -507,7 +507,7 @@
507507
"filename": "tests/app/main/views/test_accept_invite.py",
508508
"hashed_secret": "07f0a6c13923fc3b5f0c57ffa2d29b715eb80d71",
509509
"is_verified": false,
510-
"line_number": 632,
510+
"line_number": 641,
511511
"is_secret": false
512512
}
513513
],
@@ -629,10 +629,10 @@
629629
"filename": "tests/conftest.py",
630630
"hashed_secret": "f8377c90fcfd699f0ddbdcb30c2c9183d2d933ea",
631631
"is_verified": false,
632-
"line_number": 3287,
632+
"line_number": 3291,
633633
"is_secret": false
634634
}
635635
]
636636
},
637-
"generated_at": "2025-10-01T14:58:39Z"
637+
"generated_at": "2025-10-07T17:43:26Z"
638638
}

.github/workflows/deploy-demo.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
LOGIN_DOT_GOV_INITIAL_SIGNIN_URL: "https://secure.login.gov/openid_connect/authorize?acr_values=http%3A%2F%2Fidmanagement.gov%2Fns%2Fassurance%2Fial%2F1&client_id=urn:gov:gsa:openidconnect.profiles:sp:sso:gsa:notify-gov&nonce=NONCE&prompt=select_account&redirect_uri=https://notify-demo.app.cloud.gov/sign-in&response_type=code&scope=openid+email&state=STATE"
6565
LOGIN_DOT_GOV_CERTS_URL: "https://secure.login.gov/api/openid_connect/certs"
6666
API_PUBLIC_URL: ${{ secrets.API_PUBLIC_URL }}
67-
API_PUBLIC_WS_URL: ${{ secrets.API_PUBLIC_WS_URL }}
6867
with:
6968
cf_username: ${{ secrets.CLOUDGOV_USERNAME }}
7069
cf_password: ${{ secrets.CLOUDGOV_PASSWORD }}
@@ -90,7 +89,6 @@ jobs:
9089
--var LOGIN_DOT_GOV_CERTS_URL="$LOGIN_DOT_GOV_CERTS_URL"
9190
--var LOGIN_PEM="$LOGIN_PEM"
9291
--var API_PUBLIC_URL="$API_PUBLIC_URL"
93-
--var API_PUBLIC_WS_URL="$API_PUBLIC_WS_URL"
9492
--strategy rolling
9593
9694
- name: Deploy egress proxy

.github/workflows/deploy-prod.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
LOGIN_DOT_GOV_INITIAL_SIGNIN_URL: "https://secure.login.gov/openid_connect/authorize?acr_values=http%3A%2F%2Fidmanagement.gov%2Fns%2Fassurance%2Fial%2F1&client_id=urn:gov:gsa:openidconnect.profiles:sp:sso:gsa:notify-gov&nonce=NONCE&prompt=select_account&redirect_uri=https://beta.notify.gov/sign-in&response_type=code&scope=openid+email&state=STATE"
6565
LOGIN_DOT_GOV_CERTS_URL: "https://secure.login.gov/api/openid_connect/certs"
6666
API_PUBLIC_URL: ${{ secrets.API_PUBLIC_URL }}
67-
API_PUBLIC_WS_URL: ${{ secrets.API_PUBLIC_WS_URL }}
6867
with:
6968
cf_username: ${{ secrets.CLOUDGOV_USERNAME }}
7069
cf_password: ${{ secrets.CLOUDGOV_PASSWORD }}
@@ -90,7 +89,6 @@ jobs:
9089
--var LOGIN_DOT_GOV_CERTS_URL="$LOGIN_DOT_GOV_CERTS_URL"
9190
--var LOGIN_PEM="$LOGIN_PEM"
9291
--var API_PUBLIC_URL="$API_PUBLIC_URL"
93-
--var API_PUBLIC_WS_URL="$API_PUBLIC_WS_URL"
9492
--strategy rolling
9593
9694
- name: Deploy egress proxy

.github/workflows/deploy.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ jobs:
7070
LOGIN_DOT_GOV_INITIAL_SIGNIN_URL: "https://secure.login.gov/openid_connect/authorize?acr_values=http%3A%2F%2Fidmanagement.gov%2Fns%2Fassurance%2Fial%2F1&client_id=urn:gov:gsa:openidconnect.profiles:sp:sso:gsa:notify-gov&nonce=NONCE&prompt=select_account&redirect_uri=https://notify-staging.app.cloud.gov/sign-in&response_type=code&scope=openid+email&state=STATE"
7171
LOGIN_DOT_GOV_CERTS_URL: "https://secure.login.gov/api/openid_connect/certs"
7272
API_PUBLIC_URL: ${{ secrets.API_PUBLIC_URL }}
73-
API_PUBLIC_WS_URL: ${{ secrets.API_PUBLIC_WS_URL }}
7473
with:
7574
cf_username: ${{ secrets.CLOUDGOV_USERNAME }}
7675
cf_password: ${{ secrets.CLOUDGOV_PASSWORD }}
@@ -96,7 +95,6 @@ jobs:
9695
--var LOGIN_DOT_GOV_CERTS_URL="$LOGIN_DOT_GOV_CERTS_URL"
9796
--var LOGIN_PEM="$LOGIN_PEM"
9897
--var API_PUBLIC_URL="$API_PUBLIC_URL"
99-
--var API_PUBLIC_WS_URL="$API_PUBLIC_WS_URL"
10098
--strategy rolling
10199
102100

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ htmlcov/
8181
.coverage.*
8282
.cache
8383
.pytest_cache
84+
.hypothesis/
8485
coverage/
8586
coverage.xml
8687
test_results.xml
@@ -150,3 +151,6 @@ playwright/
150151
backstop_data/bitmaps_test/
151152
backstop_data/html_report/
152153
backstop_data/engine_scripts/playwright/
154+
155+
# Pa11y
156+
pa11y-results.txt

.pre-commit-config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,15 @@ repos:
1818
args: [--allow-missing-credentials]
1919
- id: detect-private-key
2020
- id: mixed-line-ending
21+
- repo: https://github.com/pycqa/flake8
22+
rev: 7.1.1
23+
hooks:
24+
- id: flake8
25+
- repo: https://github.com/pycqa/isort
26+
rev: 5.13.2
27+
hooks:
28+
- id: isort
29+
args: ["--profile", "black"]
2130
- repo: https://github.com/Yelp/detect-secrets
2231
rev: v1.5.0
2332
hooks:

app/__init__.py

Lines changed: 7 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -102,22 +102,16 @@
102102
from app.notify_client.performance_dashboard_api_client import (
103103
performance_dashboard_api_client,
104104
)
105-
from app.notify_client.platform_stats_api_client import (
106-
platform_stats_api_client,
107-
)
105+
from app.notify_client.platform_stats_api_client import platform_stats_api_client
108106
from app.notify_client.service_api_client import service_api_client
109107
from app.notify_client.status_api_client import status_api_client
110-
from app.notify_client.template_folder_api_client import (
111-
template_folder_api_client,
112-
)
113-
from app.notify_client.template_statistics_api_client import (
114-
template_statistics_client,
115-
)
108+
from app.notify_client.template_folder_api_client import template_folder_api_client
109+
from app.notify_client.template_statistics_api_client import template_statistics_client
116110
from app.notify_client.upload_api_client import upload_api_client
117111
from app.notify_client.user_api_client import user_api_client
118112
from app.url_converters import SimpleDateTypeConverter, TemplateTypeConverter
119113
from app.utils.api_health import is_api_down
120-
from app.utils.govuk_frontend_jinja.flask_ext import init_govuk_frontend
114+
from app.utils.nunjucks_jinja.flask_ext import init_nunjucks_environment
121115
from notifications_python_client.errors import HTTPError
122116
from notifications_utils import logging, request_helper
123117
from notifications_utils.formatters import (
@@ -149,7 +143,6 @@
149143
def _csp(config):
150144
asset_domain = config["ASSET_DOMAIN"]
151145
api_public_url = config["API_PUBLIC_URL"]
152-
api_public_ws_url = config["API_PUBLIC_WS_URL"]
153146

154147
return {
155148
"default-src": ["'self'", asset_domain],
@@ -168,7 +161,6 @@ def _csp(config):
168161
"https://www.googletagmanager.com",
169162
"https://www.google-analytics.com",
170163
"https://dap.digitalgov.gov",
171-
"https://cdn.socket.io",
172164
],
173165
"connect-src": list(
174166
dict.fromkeys(
@@ -177,7 +169,6 @@ def _csp(config):
177169
"https://gov-bam.nr-data.net",
178170
"https://www.google-analytics.com",
179171
f"{api_public_url}",
180-
f"{api_public_ws_url}",
181172
]
182173
)
183174
),
@@ -198,17 +189,8 @@ def inject_is_api_down():
198189

199190
# @application.context_processor
200191
# def inject_feature_flags():
201-
# this is where feature flags can be easily added as a dictionary within context
202-
# feature_socket_enabled = application.config.get("FEATURE_SOCKET_ENABLED", True)
203-
204-
# current_app.logger.info(
205-
# f"FEATURE_SOCKET_ENABLED value in __init__.py coming \
206-
# from config is {application.config.get('FEATURE_SOCKET_ENABLED')} and \
207-
# the ending value is {feature_socket_enabled}"
208-
# )
209-
# return dict(
210-
# FEATURE_SOCKET_ENABLED=feature_socket_enabled,
211-
# )
192+
# this is where feature flags can be easily added as a dictionary within context
193+
# feature_enabled = application.config.get("FEATURE_ENABLED", True)
212194

213195
@application.context_processor
214196
def inject_initial_signin_url():
@@ -246,7 +228,7 @@ def inject_initial_signin_url():
246228
if "extensions" not in application.jinja_options:
247229
application.jinja_options["extensions"] = []
248230

249-
init_govuk_frontend(application)
231+
init_nunjucks_environment(application)
250232
init_jinja(application)
251233

252234
for client in (

app/assets/error_pages/5xx.html

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -92,10 +92,7 @@ <h2 class="usa-sr-only">Support links</h2>
9292
d="M421.5 142.8V.1l-50.7 32.3v161.1h112.4v-50.7zm-122.3-9.6A47.12 47.12 0 0 1 221 97.8c0-26 21.1-47.1 47.1-47.1 16.7 0 31.4 8.7 39.7 21.8l42.7-27.2A97.63 97.63 0 0 0 268.1 0c-36.5 0-68.3 20.1-85.1 49.7A98 98 0 0 0 97.8 0C43.9 0 0 43.9 0 97.8s43.9 97.8 97.8 97.8c36.5 0 68.3-20.1 85.1-49.7a97.76 97.76 0 0 0 149.6 25.4l19.4 22.2h3v-87.8h-80l24.3 27.5zM97.8 145c-26 0-47.1-21.1-47.1-47.1s21.1-47.1 47.1-47.1 47.2 21 47.2 47S123.8 145 97.8 145" />
9393
</svg>
9494
<span class="usa-footer__licence-description">
95-
All content is available under the
96-
<a class="usa-footer__link"
97-
href="https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/" rel="license">Open
98-
Government Licence v3.0</a>, except where otherwise stated
95+
All content is available under <a href="https://open.gsa.gov/oss/">GSA's Open Source Policy</a>, except where otherwise stated
9996
</span>
10097
</div>
10198
</div>

app/assets/javascripts/activityChart.js

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -239,10 +239,10 @@
239239
}
240240

241241
const data = await response.json();
242-
labels = [];
243-
deliveredData = [];
244-
failedData = [];
245-
pendingData = [];
242+
let labels = [];
243+
let deliveredData = [];
244+
let failedData = [];
245+
let pendingData = [];
246246
let totalMessages = 0;
247247

248248
for (var dateString in data) {
@@ -399,19 +399,19 @@
399399
dropdown.addEventListener('change', handleDropdownChange);
400400
});
401401

402-
// Resize chart on window resize
403-
window.addEventListener('resize', function() {
404-
if (labels.length > 0 && deliveredData.length > 0 && failedData.length > 0 && pendingData.length > 0) {
405-
createChart('#weeklyChart', labels, deliveredData, failedData, pendingData);
406-
createTable('weeklyTable', 'activityChart', labels, deliveredData, failedData, pendingData);
407-
}
408-
});
402+
// Resize chart on window resize
403+
window.addEventListener('resize', function() {
404+
if (labels.length > 0 && deliveredData.length > 0 && failedData.length > 0 && pendingData.length > 0) {
405+
createChart('#weeklyChart', labels, deliveredData, failedData, pendingData);
406+
createTable('weeklyTable', 'activityChart', labels, deliveredData, failedData, pendingData);
407+
}
408+
});
409409

410-
// Export functions for testing
411-
window.createChart = createChart;
412-
window.createTable = createTable;
413-
window.handleDropdownChange = handleDropdownChange;
414-
window.fetchData = fetchData;
415-
}
410+
// Export functions for testing
411+
window.createChart = createChart;
412+
window.createTable = createTable;
413+
window.handleDropdownChange = handleDropdownChange;
414+
window.fetchData = fetchData;
415+
}
416416

417417
})(window);

0 commit comments

Comments
 (0)