Answer the question
In order to leave comments, you need to log in
What solutions are there for determining library versions?
Hello! Given: A product that depends on a certain library. The library is constantly updated, but the same part of the code first gets into the product (so as not to wait for the release of the library) and in parallel - into the library. With the release of a new version of the library, those parts of the code that are already in it are removed from the product. Task: to make a mechanism that will most transparently report parts of the code that need to be removed after moving to a new version of the library.
As I see it: we take the version of the library, check it in the right places and display a message in the console about the need to remove these parts of the code if it is already in the library. To do this, you need to store a version of the library somewhere so that it can be most easily pulled.
A "bicycle" is naturally brewing for me, but I would like to start looking for ready-made solutions. The use case I described seems to be quite trivial, for sure someone has already done something.
Python code, hg is used as CVS.
Thanks to all!
Answer the question
In order to leave comments, you need to log in
composer, npm and other package managers can do this with a bang.
The task is reduced to detecting duplicate code sections. You will have to compare the project root and site-packages/your_library_name. You can try https://sourceforge.net/projects/clonedigger/ as a tool. In addition, the process can be automated by screwing CI.
You can use Requirements Files . In such files, you can specify the exact version, or older than the specified or not older than the specified. Or you can not specify versions at all, but simply specify the package names and then only the latest versions will be installed.
The installed environment is "frozen" with the command: pip freeze
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question