Skip to content

Upgrades#78

Open
OliveraReeves wants to merge 13 commits into
masterfrom
upgrades
Open

Upgrades#78
OliveraReeves wants to merge 13 commits into
masterfrom
upgrades

Conversation

@OliveraReeves

Copy link
Copy Markdown
Contributor

The main change is that the Dockerfile and dependencies have been updated to use Poetry and Python 3.11, with the option to move to Python 3.14 if required. The build script will be updated separately.

Where possible, dependencies have been updated to newer versions; however, some are constrained by transitive dependencies.

Cornflake has been switched from the PyPI package to a Git URL due to a required patch to support newer Python versions.

Looking ahead, it may be worth considering a rewrite of the serializers using Pydantic or Marshmallow, which are more standard within Flask applications. However, this would be a significantly larger refactor and is out of scope for the current changes. this would also remove the need for cornflake as this supersedes it.

Additionally, a number of SQLAlchemy relationships were identified as potentially problematic and have been updated to address these issues. Enums are swapped to use the inbuilt sqla enums and not the extensions( this has been removed)

The use of cls in certain areas has also been replaced with self for correctness and consistency.

Due to updates in SQLAlchemy, the database URL in the settings must use postgresql instead of postgres.

@OliveraReeves
OliveraReeves requested a review from George-D-S June 16, 2026 17:34
@OliveraReeves

OliveraReeves commented Jun 16, 2026

Copy link
Copy Markdown
Contributor Author

I have update this to include ticket RDR-913, RDR-932, this also address UK-228. Locally the dev compose is all working fine, all that needs testing and changing is the production yaml and the docs/ server side changes. After this is merged i will make another pr to fix the linting mypy, ruff issues

@George-D-S

Copy link
Copy Markdown

It would be worth looking at...

[82](https://github.com/renalreg/radar/actions/runs/27636238583/job/81724108678#step:8:883)
pyproject.toml: DEP002 'amqp' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'billiard' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'python-dateutil' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'tzlocal' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'six' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'bleach' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'html5lib' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'openpyxl' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'tablib' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'zxcvbn-python' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'psycopg2-binary' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'psycopg2' defined as a dependency but not used in the codebase
pyproject.toml: DEP002 'setuptools' defined as a dependency but not used in the codebase
radar/auth/passwords.py:4:8: DEP001 'zxcvbn' imported but missing from the dependency definitions
radar/fixtures/forms.py:4:8: DEP001 'pkg_resources' imported but missing from the dependency definitions
radar/utils.py:7:1: DEP001 'dateutil' imported but missing from the dependency definitions
Found 16 dependency issues.

If any are removed there may be some corresponding "types" files mentioned in Tox.ini which can be removed.

I would remove the "migrations" folder from the Tox checks, as it's auto-generated code but still flagging errors.

It might be worth doing "Black" on the code but I wouldn't do that as part of this PR.

@andyatterton

Copy link
Copy Markdown
Contributor

@OliveraReeves has this stalled?

@OliveraReeves

Copy link
Copy Markdown
Contributor Author

@OliveraReeves has this stalled?

have not had a chance this week to look into it but mainly the next steps are national and international branch support( most likely a seperate image for each?), how to setup the docker on the servers in way that has minimal impact on the current process

@George-D-S

Copy link
Copy Markdown

I've unticked Andy and I, just because I don't think we're needed to review this yet. If I'm wrong please add us back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants