-
Notifications
You must be signed in to change notification settings - Fork 0
feat: add fastapi + service_info endpoint #78
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
Conversation
|
oh, a possible TODO here is that ruff includes a fastapi-specific set of lints we could use |
korikuzma
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sweet 🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like there's still some merge conflicts that need resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch
#231) * implement GenomicMedLab/software-templates#78 * Don't introduce env logic into DB construction, since I know that's a whole can of worms (but it would be nice to do this eventually). * Filled in some more documentation to have a place to briefly describe this. --------- Co-authored-by: Kori Kuzma <[email protected]>
Add `python-dotenv` to backend entry points. This is a simple quality-of-life improvement driven by my unending frustration with the mountain of environment variables upon which metakb sits. Store a `.env` file in `server/` and it'll load env vars from there. * I have aspirations for a more featureful configuration experience. I'd made an initial attempt [here](GenomicMedLab/software-templates#78) but I'm not totally happy with it. I have an issue [here](GenomicMedLab/software-templates#106) to take up someday where I try and do something better, but I think that would entail implementation in all of the library dependencies first. For now I think this PR is just fine though.
Add `python-dotenv` to backend entry points. This is a simple quality-of-life improvement driven by my unending frustration with the mountain of environment variables upon which metakb sits. Store a `.env` file in `server/` and it'll load env vars from there. * I have aspirations for a more featureful configuration experience. I'd made an initial attempt [here](GenomicMedLab/software-templates#78) but I'm not totally happy with it. I have an issue [here](GenomicMedLab/software-templates#106) to take up someday where I try and do something better, but I think that would entail implementation in all of the library dependencies first. For now I think this PR is just fine though.
Add `python-dotenv` to backend entry points. This is a simple quality-of-life improvement driven by my unending frustration with the mountain of environment variables upon which metakb sits. Store a `.env` file in `server/` and it'll load env vars from there. * I have aspirations for a more featureful configuration experience. I'd made an initial attempt [here](GenomicMedLab/software-templates#78) but I'm not totally happy with it. I have an issue [here](GenomicMedLab/software-templates#106) to take up someday where I try and do something better, but I think that would entail implementation in all of the library dependencies first. For now I think this PR is just fine though.
close #75
this became much bigger than planned, but it reflects a few aspirations for what a service-like application should probably look like
api.pymodule, including a/service_infoendpoint conforming to the GA4GH spec. I didn't bother implementingupdatedAt(it's optional) because I think it'd be kind of a hassle to update a datetime object every time we make a release. Maybe there's a way to automate this but not a priority IMO.testanddebug) are sort of general/predictive of what we might need in a given app. Lots of examples online also set aDB URLor DB connection configs here as well. (I also looked atpydantic-settingsfor this but I think it's a lot more than we need. )FASTrules fromruff.The service info spec lets you add your own additional fields if desired. For DGIdb, Adam added a "data version" field, for example. There's probably things we could do there for many of our APIs.