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.
recently on every launch install.py the message keep poping up on launch
this is due to improper version comparison in
install.py
comparable_version()
ininstall.py
retrunsTuple of strings
sd-webui-controlnet/install.py
Lines 15 to 16 in b63899a
until recently directly comparing
Tuple of strings
work good enough but opencv-python updated to vesrion4.10.x.x
when checking for
opencv-python>=4.8.0
the
Tuple of strings
('4', '10', '0', '84')
>=('4', '8', '0')
this retrunsFalse
due to the string
'10'
is < string'8'
solution
as far as I'm aware the best way of passing version number is to use
from packaging.version import parse
as this also handles more exotic version numbers such as the ones with suffixes
alternatively if you wish to not packaging then one could either write complex regex to handle special cases
or just assume that there's no special version numbers and simply convert str to int
which can be done by modifying
comparable_version