Commit Graph

48 Commits

Author SHA1 Message Date
dependabot[bot]
e61a2f01aa Bump lxml from 4.8.0 to 4.9.1
Bumps [lxml](https://github.com/lxml/lxml) from 4.8.0 to 4.9.1.
- [Release notes](https://github.com/lxml/lxml/releases)
- [Changelog](https://github.com/lxml/lxml/blob/master/CHANGES.txt)
- [Commits](https://github.com/lxml/lxml/compare/lxml-4.8.0...lxml-4.9.1)

---
updated-dependencies:
- dependency-name: lxml
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-06 21:50:22 +00:00
Jim Moffet
59b72f4853 add devcontainer configs and docker network orchestration 2022-06-13 13:16:32 -07:00
Ben Thorner
ee8e86f409 Bump utils to version 56.0.0
The only impactful change is the major version itself, where I've
fixed the breaking changes due to the upgrade of PyPDF2 [^1] and
checked there are no deprecation warnings when I run the tests.

[^1]: https://github.com/alphagov/notifications-utils/pull/973
2022-06-01 14:27:25 +01:00
Katie Smith
d17be0354a Pin Werkzeug
We can't use version later than the one currently in requirements.in
because the version of flask-sqlalchemy that we are using won't work
with version 2.1.0 and above.
2022-05-27 09:57:10 +01:00
Katie Smith
4404f9eb12 Upgrade marshmallow-sqlalchemy from 0.23.1 to 0.28.0
This was blocked before due to being on marshmallow 2, but now that we
are on marshmallow 3 we can upgrade this package.
2022-05-26 14:18:51 +01:00
Katie Smith
53aae6f6cb Upgrade marshmallow from 2.21.0 to 3.15.0 2022-05-19 13:46:49 +01:00
Katie Smith
fdee7b5ecb Update cachetools from 5.0.0 to 5.1.0 2022-05-17 10:53:06 +01:00
Katie Smith
2f3da76e81 Update SQLAlchemy from 1.4.35 to 1.4.36 2022-05-17 10:51:49 +01:00
Katie Smith
76e683eeed Update PyJWT from 2.3.0 to 2.4.0 2022-05-17 10:49:30 +01:00
Katie Smith
1d58f47dfe Update jsonschema from 4.4.0 to 4.5.1 2022-05-17 10:45:28 +01:00
Katie Smith
ddec6de3c4 Update flask from 2.1.1 to 2.1.2 2022-05-17 10:36:16 +01:00
Leo Hemsted
cc3035a101 bump utils
mostly to get rid of the security warning on pypdf2
2022-05-03 12:26:38 +01:00
sakisv
0a24b57008 Use our own fork of gds_metrics_python and add shared auth token
This will allow both prometheis (the shared one and our own) to scrape
the /metrics endpoint, each with their own authentication
2022-04-20 19:28:07 +03:00
Katie Smith
9435dfc385 Merge pull request #3512 from alphagov/bump-json-schemas
Bump jsonschema package from 3.2.0 to 4.4.0
2022-04-19 14:34:39 +01:00
Katie Smith
9a249dc530 Use jsonschema[format] instead of jsonschema
`jsonschema[format]` includes all the formatting dependencies of
jsonschema, meaning that we don't have to specify `rfc3339-validator`
and `rfc3987` ourselves in the requirements.in file. This also has the
benefit of meaning that if the underlying formatting packages of
jsonschema change, we will be covered and won't accidentally miss the
fact that we need to change a package.
2022-04-19 13:53:06 +01:00
Katie Smith
ec95163175 Update beautifulsoup4 to 4.11.1
`charset-normalizer` is now used by default if installed instead of
`chardet` (https://pyup.io/changelogs/beautifulsoup4/#4.11.0). We do
have `charset-normalizer` installed because it's a subdependency of the
requests library, so it is being used.

This caused the `test_content_too_long_returns_400` to fail since it
now thought that the encoding of `ŵ` is `{'encoding': 'Big5',
'language': 'Chinese', 'confidence': 1.0}`.

There are two options for fixing this
- change the test content so that it doesn't just contain a single
  letter - the docs state that you shouldn't run character detection on
  very tiny content
- add `chardet` as a requirement, so that the code functions exactly the
  same as before

I've chose the first option, since this avoids adding a dependency and
we should never have messages consisting of a single character.
2022-04-14 16:48:32 +01:00
Katie Smith
5feb38f50a Bump jsonschema from 3.2.0 to 4.4.0
The big breaking change for our code (not mentioned in the changelog) is
that the built-in validator for the `date-time` format now requires the
`rfc3339-validator` package instead of the `strict-rfc3339` package.
This updates the requirements file to use `rfc3339-validator`. Without
this change, wrong `date-time` formats would always silently pass validation.
2022-04-14 14:47:42 +01:00
Katie Smith
f6f6b81e91 Update cachetools from 4.2.1 to 5.0.0
There are breaking changes in the latest version, but these should not
affect our code.
2022-04-14 14:17:41 +01:00
Katie Smith
f4a4dd8822 Update sqlalchemy from 1.4.32 to 1.4.35 2022-04-14 13:46:19 +01:00
Katie Smith
857e7c1ce1 Update prometheus-client from 0.10.1 to 0.14.1 2022-04-14 13:39:31 +01:00
Katie Smith
667d505b5d Update flask-bcrypt from 0.7.1 to 1.0.1
There's no changelog for this, but I've looked through all the commits
and can't see any reason why this needed a major version bump or
anything that should cause us issues.
2022-04-14 13:15:36 +01:00
Katie Smith
1f705f3c29 Update flask from 2.1.0 to 2.1.1 2022-04-14 10:17:20 +01:00
Katie Smith
0cd06dba62 Update celery[sqs] from 5.2.3 to 5.2.6. 2022-04-14 10:13:30 +01:00
Ben Thorner
f393ca4638 Bump utils to 55.1.4 (no changes) 2022-04-12 14:13:53 +01:00
Katie Smith
badd0e0894 Bump Flask and itsdangerous
This bumps Flask to version 2.1.0, which requires some minor changes to
the app code and itsdangerous to also be bumped.
2022-04-05 17:06:08 +01:00
Katie Smith
d32ebe1147 Update werkzeug from 2.0.2 to 2.0.3 2022-03-09 17:22:11 +00:00
Katie Smith
d93f1e3e95 Update beautifulsoup4 from 4.9.3 to 4.10.0 2022-03-09 17:19:49 +00:00
Katie Smith
5fd014eb14 Update sqlalchemy from 1.4.10 to 1.4.32 2022-03-09 16:52:44 +00:00
Katie Smith
97c4ccfdce Update pyjwt from 2.0.1 to 2.3.0 2022-03-09 16:34:42 +00:00
Katie Smith
faec6083fa Update notifications-python-client from 6.0.2 to 6.3.0 2022-03-03 14:17:32 +00:00
Katie Smith
7943010bfb Update lxml from 4.7.1 to 4.8.0 2022-03-03 14:15:16 +00:00
Katie Smith
3a57597266 Update psycopg2-binary from 2.8.6 to 2.9.3 2022-03-03 14:07:11 +00:00
Katie Smith
9e324da311 Update iso8601 from 0.1.14 to 1.0.2
The major version bump is because support for Python 3.6 has been
dropped.
2022-03-03 13:47:47 +00:00
Katie Smith
f74d878a07 Update flask-migrate from 2.7.0 to 3.1.0 2022-03-03 13:47:33 +00:00
Katie Smith
c1a3b4bc24 Update celery from 5.2.0 to 5.2.3
This fixes a security warning.
2022-03-03 13:42:10 +00:00
Leo Hemsted
d34c58925e bump cffi
v1.15 adds arm64 support for macbooks with an m1 chip
2022-02-23 16:43:21 +00:00
Leo Hemsted
ba2479b6e4 pin gunicorn to git commit; bump eventlet
gunicorn doesn't pin eventlet, but functionally, gunicorn==20.1.0
depends on eventlet<=0.30.2 due to a change in eventlet. Gunicorn have
fixed this compat issue, however, haven't released it. By pinning to a
git commit, we're able to bump eventlet up to 0.33, thus solving a
security advisory. (Note that the security advisory didn't actually
impact us as it only affects websockets, however, it was noisy and
distracting).

Note - pip may have cached the old version of gunicorn. You may need to
run `pip install -r requirements.txt --no-cache-dir` to get the updated
version of gunicorn locally.
2022-02-23 16:43:21 +00:00
Chris Hill-Scott
7f72d3a60f Bump utils to 53.0.0
Changes:

53.0.0
---

* `notifications_utils.columns.Columns` has moved to
  `notifications_utils.insensitive_dict.InsensitiveDict`
* `notifications_utils.columns.Rows` has moved to
  `notifications_utils.recipients.Rows`
* `notifications_utils.columns.Cell` has moved to
  `notifications_utils.recipients.Cell`

52.0.0
---

* Deprecate the following unused `redis_client` functions:
  - `redis_client.increment_hash_value`
  - `redis_client.decrement_hash_value`
  - `redis_client.get_all_from_hash`
  - `redis_client.set_hash_and_expire`
  - `redis_client.expire`

51.3.1
---

* Bump govuk-bank-holidays to cache holidays for next year.
2022-02-08 09:45:10 +00:00
Leo Hemsted
19a11e57d2 Merge pull request #3432 from alphagov/cryptography
unpin cryptography
2022-01-24 15:19:31 +00:00
Leo Hemsted
cdab82c1eb unpin cryptography
we previously pinned cryptography to versions less than 3.4 since after
that point, cryptography started using rust as a dependency. This isn't
an issue if you install from wheel, but we found that the version of pip
bundled with the python buildpack was too old to support this. However,
since upgrading from python 3.6 to python 3.9, the pip version has been
bumped and we now no longer need to pin cryptography as it installs
correctly.
2022-01-19 18:46:18 +00:00
Ben Thorner
491b7ce9ee Bump utils to 51.3.0
This brings in new logging for the NotifyCelery base class [1].

[1]: https://github.com/alphagov/notifications-utils/pull/938
2021-12-20 16:45:47 +00:00
Leo Hemsted
b7c1fcb66d bump lxml to fix security warning
two vulnerabilities in <4.6.5 (GHSL-2021-1037 and GHSL-2021-1038)
https://github.com/lxml/lxml/blob/master/CHANGES.txt

also removes docopt as we don't use it except for a dev script (which we
might not need anyway)
2021-12-14 13:47:38 +00:00
Ben Thorner
a7560af9c4 Bump utils to 51.2.1
This includes performance improvements for RecipientCSV, which may
reduce the processing time in some edge cases - this depends on if
the Admin app rejects CSVs with these edge cases.
2021-12-10 16:38:28 +00:00
Chris Hill-Scott
f011254667 Bump notifications-utils to 51.0.0
Just so other people don’t have to merge these changes.

The breaking changes don’t affect this repo because the API doesn’t:
- check the service guestlist before sending a message
- do any visual preview of emergency alert messages

> **51.0.0**
> - Initial argument to RecipientCSV renamed from whitelist to guestlist, in other words consuming code should call RecipientCSV(guestlist=['test@example.com'])
> - RecipientCSV.whitelist property renamed to RecipientCSV.guestlist
>
> **50.0.0**
> - Make icon in broadcast_preview_template.jinja2 an inline SVG (requires changes to the CSS of consumer code)
>
> **49.1.0**
> Add ttl_in_seconds argument to RequestCache.set to let users specify a custom TTL

This commit also changes the format of the line in the requirements
file, copying https://github.com/alphagov/notifications-admin/pull/4074/files
2021-12-06 09:34:15 +00:00
Chris Hill-Scott
4feb3fdc10 Bump utils
This new version of utils implements the transformation of our polygons
to a Cartesian plane. In other words, it converts them from being
defined in spherical degrees to metres.

For the API this means our simplification will be slightly more
accurate.
2021-11-18 15:43:39 +00:00
Ben Thorner
528223ed61 Use central NotifyCelery base class in utils
Note that the new base class doesn't include a bespoke feature we
had here: 'log_on_worker_shutdown'. We've agreed it's reasonable
to remove it for now as it was introduced many years ago and its
use case is unclear - we can always add it back if needed.
2021-11-16 13:58:12 +00:00
Chris Hill-Scott
6c0bda0388 Bump Celery to latest version
This brings in the version 5.2.1 of Kombu, which fixes a security
vulnerability:
> Celery 5.2.0 includes 'kombu' v5.2.1, which includes dependencies
> updates that resolve security issues.
— https://pyup.io/repos/github/alphagov/notifications-api/commits/?page=1#b654c27699a5164cbbe50e042d5d34141f560255

This is the commit from Kombu:
f3b04558fa

I believe the dependency of Kombu which has issues is urllib3, which
has two open advisories for versions less than 1.26.5:
- https://github.com/urllib3/urllib3/security/advisories/GHSA-q2q7-5pp4-w6pg
- https://github.com/urllib3/urllib3/security/advisories/GHSA-5phf-pp7p-vc2r
2021-11-15 11:12:33 +00:00
Leo Hemsted
036bc92245 switch from freeze reqs script to pip-tools
instead of alexey's home-grown script, pip-tools offers a quicker, more
efficient and better supported way to freeze requirements.

see prior art here:

https://github.com/alphagov/notifications-admin/pull/3753
https://github.com/alphagov/notifications-ftp/pull/333
2021-11-11 13:54:21 +00:00