Repository navigation
refactor: move the FastAPI server to pylinkage-editor - #48
Merged
Merged
Conversation
api/ was the backend of pylinkage-editor and nothing else. It was never part of the wheel, so pip install pylinkage[api] installed fastapi and uvicorn for code that was not there, and anyone setting up the editor had to find the server by reading this repository's source (#46). It now lives in pylinkage-editor/server with pylinkage as a dependency, and this repository is a library again. Removed with it: the [api] extra, task api, and a CONTRIBUTING section that still described a frontend/ directory and a task frontend, neither of which existed. README and CONTRIBUTING point at the editor instead. Not a breaking change: no public name goes away. pip warns on an unknown extra and continues. Closes #46.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Removes
api/, the[api]extra andtask api. The FastAPI server was the backend of pylinkage-editor and nothing else; it now lives there asserver/, with pylinkage as a dependency (HugoFara/pylinkage-editor#2). This repository is a library again.Closes #46.
Why remove rather than deprecate
The deprecation policy in
docs/source/deprecations.mdcovers public names.api/was not one:packages = ["src/pylinkage"]).pip install pylinkage[api]installed fastapi and uvicorn for code that was not there. There is no installed user to break.api.main:app, a top-level package that only resolved from a checkout — notpylinkage.anything.localhost:8000.Dropping the extra is not breaking either: pip warns
does not provide the extra 'api'and continues.Anyone running it from a checkout:
cd pylinkage-editor/server && uv run pylinkage-editor-serverreplacesuv run task api. That's in the changelog under### Removed.Also
frontend/directory and atask frontend, neither of which existed. Replaced with a pointer to the editor repository.uv.lockloses the fastapi/uvicorn/starlette subtree.Sequencing
The editor's server depends on
crank_angle_limits(#47, merged). Its CI will fail until 1.2.0 is on PyPI, so: merge this → cut 1.2.0 → merge the editor PR.Verification
ruff,mypyclean;uv syncresolves.api/,task apior the extra outside the changelog.