feat: ofsted data points optional for gias submission #1794
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
AB#241881 - AB#246016
Change proposed in this pull request
New gias input schema created. Following the existing pattern for input schemas
default
for the existing schema for historic processing and a new2024
with the following columns omitted.OfstedRating (name)
OfstedLastInsp
Changes to
prepare_schools_data
inpre_processing\ancillary\schools.py
to accommodate the above.The omitted columns are required to write to the db and
OfstedRating (name)
is a factor for rag calculations.Therefore if not present in the submission these columns are created with default values.
OfstedRating (name)
as an empty string. Later inrag.py
this will resolve to"other"
and not be considered for rag rating calculations. ie!= "outstanding"
OfstedLastInsp
asNone
(NaT
forpd.to_datetime
,NULL
for the db)This aligns with current behaviour when these values are missing for a row.
If present in the submission the current behaviour is preserved.
Tests added to confirm the above.
Guidance to review
When running locally no changes to 2021 - 2023 default runs should be observed.
For 2024
all_schools.parquet
OfstedRating (name)
andOfstedLastInsp
should only contain the default values.Also for a 2024 run the latest gias all establishment data > establishment fields can be processed without error.
Checklist (add/remove as appropriate)