Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor setting of PROPERTIES columns across Modules #1429

Closed

Conversation

willGraham01
Copy link
Collaborator

@willGraham01 willGraham01 commented Jul 19, 2024

Concerns #1428 |

Large portion of the additions in the diff are the PROPERTIES attributes of the modules being linted by tox check and split over multiple lines, so apologies for that to any reviewers.

Key changes introduced are within the core module though - specifically the new default_value that Propertys now take and the abstractly implemented initialise_population method. Changes to disease modules should mostly be deletions of the explicit setting of columns and addition of default values for categories where necessary.

…set of Categories, and add class typehints to Property and Module
…e property - was never referenced in the codebase
…ptom_code property - was never referenced in the codebase"

This reverts commit 778dc2e.
…t pop.

All these modules pass-ed this method.
Since there are no properties defined by these modules, this is what the
inherited method will do without need to redefine it in the module again.
@tamuri
Copy link
Collaborator

tamuri commented Jul 23, 2024

I suggest breaking this PR into several PRs. One adding the new functionality, the others refactoring specific modules to use the new functionality. This does mean that we end up supporting both old and new approaches for a time, but it is easier to work with modellers to update and check their modules and also identify any regressions easily.

@willGraham01
Copy link
Collaborator Author

I suggest breaking this PR into several PRs. One adding the new functionality, the others refactoring specific modules to use the new functionality. This does mean that we end up supporting both old and new approaches for a time, but it is easier to work with modellers to update and check their modules and also identify any regressions easily.

No problem, it should just be a case of cherry-picking the various commits from this branch (they're on a per-module basis). Will get started on this.

@willGraham01
Copy link
Collaborator Author

Closing in favour of (the first of many) starting with #1436. Leaving the branch here for cherry-picking purposes.

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.

2 participants