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

Create PyPI package with namespace packages #16

Open
JBurkinshaw opened this issue Jul 27, 2021 · 2 comments
Open

Create PyPI package with namespace packages #16

JBurkinshaw opened this issue Jul 27, 2021 · 2 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@JBurkinshaw
Copy link
Collaborator

JBurkinshaw commented Jul 27, 2021

The application currently refers to the separation of concerns in the code as "backend" for business logic and "frontend" which deals with receiving requests and sending responses. To make this clearer and more consistent with other applications, the backend ("app") should be renamed to "core" and the frontend (fastapi) should be renamed to "application".

Update the application to publish an oaff PyPI package with two namespace packages/subpackages - oaff.core and oaff.application.

This approach is based on the approach taken by TiTiler which has a similar separation of concerns. It will make the terminology in this application and PyPI package clearer and more consistent with common practices elsewhere.

Another good approach which could be an alternative is stac-fastapi.

@JBurkinshaw JBurkinshaw self-assigned this Jul 27, 2021
@JBurkinshaw JBurkinshaw added the enhancement New feature or request label Jul 27, 2021
@JBurkinshaw
Copy link
Collaborator Author

One idea from @cuttlefish

For the packaging, I’m not sure what the current recommendations on dependencies in setup.{py|cfg} vs requirments.txt are. One option is to loosely pin the dependencies in setup.* (e.g. using ~= instead of ==) and then generate a requirments.txt (using pip freeze) with hard pinned (== + patch numbers) and use that when building the container images.
I haven’t used poetry, but apparently it has version pinning, which would be nice.

@jbants jbants modified the milestones: v0.1.0, v0.2.0, EPIC, v0.3.0, v0.4.0, v0.5.0 Aug 10, 2021
@JBurkinshaw
Copy link
Collaborator Author

Use STACTOOLS' release.yml to inform the workflow here. It pushes to PyPI and creates a GHCR docker image with a latest tag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants