Skip to content

Port over to fastapi #519#524

Draft
joshdimanteto wants to merge 37 commits intorefactor-dg-api-model-to-pydantic-522from
port-over-to-fastapi-#519
Draft

Port over to fastapi #519#524
joshdimanteto wants to merge 37 commits intorefactor-dg-api-model-to-pydantic-522from
port-over-to-fastapi-#519

Conversation

@joshdimanteto
Copy link

@joshdimanteto joshdimanteto commented Jan 14, 2026

This PR will close #519

Description

Enter a description of the changes here

Testing Instructions

Add a set up instructions describing how the reviewer should test the code

  • Review code
  • Check GitHub Actions build
  • If icatdb Generator Script Consistency Test CI job fails, is this because of a deliberate change made to the script to change generated data (which isn't actually a problem) or is here an underlying issue with the changes made?
  • Review changes to test coverage
  • Does this change mean a new patch, minor or major version should be made? If so, does one of the commit messages feature fix:, feat: or BREAKING CHANGE: so a release is automatically made via GitHub Actions upon merge?
  • {more steps here}

Agile Board Tracking

Connect to #519

Notes

  • In the models all the relationships fields so ONE to ONE , ONE to MANY and MANY to MANY are optional. This was done because the model are deeply nested and can cascade. When they cascade they use the id generated by the parent for the given field e.g. so if you can create jobs in Applications, the job object would have the application id. This is a complex when it comes to Investigation when there is 4 levels deep so investigation - dataset - data file etc. for this to work you have to create many custom models of existing entities. So it is more efficient to make them optional. The ATTRIBUTES can be optional or mandatory depending on the SQL schema.

  • The NULL values have been removed from the returns on the endpoints, this is because in some of the get endpoints you can use DISTINCT should only shows certain fields. If the other fields are None pydantic would fill it in with None values. This make object large for no benefit.

- implement session bearer to add session id in header
- add TODO for issue found with post and patch requesr #525
@joshdimanteto joshdimanteto mentioned this pull request Feb 9, 2026
6 tasks
@joshdimanteto joshdimanteto force-pushed the port-over-to-fastapi-#519 branch 6 times, most recently from b5b99ba to 2e204de Compare February 10, 2026 14:57
@joshdimanteto joshdimanteto force-pushed the port-over-to-fastapi-#519 branch from 2e204de to 5750aa9 Compare February 10, 2026 15:13
@joshdimanteto joshdimanteto force-pushed the port-over-to-fastapi-#519 branch from 0f4320e to 8ab0d9a Compare February 10, 2026 16:44
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.

1 participant