If there is even a small error in Grasshopper component using ScriptEditor, it download a pip version uploaded before, in this case 2.0.9. It is really annoying because everytime I must close rhino delete all these folders and try again because the pip installable package is always loaded first:
Why this happens?
What triggers pip installation even #r packagename is not defined?
It would be nicer that pacakage that is loaded would be dependent on the version number.
pip does not install anything if there are no #r : <package-spec> entries in your scripts. It does run pip list to collect the installed packages but that is different.
Is there an example you can share that replicates this error? Also I would really like to know why you are not installing compas_wood using the #r: compas_wood entry? Is there a problem with that install?
once the code is ready I ship it to pipy, but the bigger time of work is local not published developed.
everytime the scripteditor goes through import even without specifying #r, if the package is missing it tries to install it through pip, which always conflict with local build.
I know that this point was discussed numerous times. But instead of description, can you provide a set of bash commands how you install local package on your py to Rhino python so that it will not use PyPi in the first place?
I always do this:
C:/Users/petras/.rhinocode/py39-rh8/python.exe -m pip install . (–target did not work for me)
I open rhino and my code
Script Editor tries to install previous PyPi package with the same name
I go to folder and delete manually the PyPi package, so that the 1st step would work
I run the code
After many different iterations code refinement, I publish to PyPi, but this is the very last step for users, not developers.
The PyPi and local package with the same name conflicts all the time even if the local package has the higher version than local one, it still tries to install it.
I got used it by manually deleting files. But it is a bit tedious specially when shifting between mac, windows and linux…
I think ScriptEditor needs a proper McNeel website page with a tutorial from zero to hero for developers.