-
Notifications
You must be signed in to change notification settings - Fork 2
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
Dependency management #14
Conversation
@paulpestov Could you please give me feedback regarding the data structure? |
I think the structure is alright. Maybe one thing, could we switch the key/value of version/project, so the frontend can recognize the affected projects easier: {
"tensorflow": "1.0.0"
} |
You mean within |
Co-authored-by: Konstantin Baierer <kba@users.noreply.github.com>
Description
This PR introduces two new attributes to the
Repo
class:dependencies
anddependency_conflicts
. They have the following structure (example shows the output forcor-asv-ann
) inrepos.json
:The output stated is generated by
venv
for every submodule in ocrd_all (except opencv-python and tesseract since they aren't really part of OCR-D) and installing itpip freeze -l
As output we create two different files:
deps.json
anddep_conflicts.json
. The former lists all dependencies per OCR-D project while the latter makes transparent which packages have been installed by several OCR-D projects, but in different versions. In all cases the dependencies given inOCR-D/core
are omitted because we assume that most OCR-D projects based on Python use this. Both files mentioned above are auxiliary files used by theRepo
class and will be updated on demand (TODO).Repo.dependencies
shows a full list of all dependencies. There is no use case for this information yet, so we might decide to toss it.Repo.dependency_conflicts
is a result of recognizing which projects have a dependency installed in different major versions; We rely on packages to implement semantic versioning correctly and assume that different major versions mean that there are breaking changes between the two versions. Cases where two or more projects have installed the same package in different minor or patch versions are ignored.How to test it
dependency-management
make repos.json
repos.json
Closes #11.