[bug] Hub install regex_match throwing error in python3.11
faizan1041 opened this issue · comments
Using guardrails-ai==0.4.3
Python 3.11.7 installed on Ubuntu 22.04
guardrails hub install hub://guardrails/regex_match
Gives following error:
Installing hub://guardrails/regex_match...
[ =] Downloading dependenciesWARNING: Target directory env/lib/python3.11/site-packages/guardrails/hub/guardrails/regex_match/validator already exists. Specify --upgrade to force replacement.
WARNING: Target directory env/lib/python3.11/site-packages/guardrails/hub/guardrails/regex_match/regex_match-0.0.0.dist-info already exists. Specify --upgrade to force replacement.
[=== ] Downloading dependenciesERROR: unknown command "inspect"
Failed to inspect
Exit code: 1
stdout: b''
Hello @faizan1041, looking at this now. Did you already install this validator sometime before? If yes, can you please try running a fresh virtual environment?
I've seen this before! pip inspect
was only released in a recent-ish (1-2yr old) version of pip. Please confirm your pip version and try agian
If upgrading pip resolves this error for you, let's keep this issue open and use it to track the addition of a feature where we
- match on this error
- check the pip version on the client
- throw a better error that includes the pip version context
Hi @faizan1041 - were you able to try this out?
I also faced a similar issue. As mentioned above, upgrading pip version = 24 resolved the issue.
I also faced a similar issue. As mentioned above, upgrading pip version = 24 resolved the issue.
yes, It works