1

Getting error 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers when installing a package with pip. The package is an internal package but seems to error when installing one of the dependencies. Any idea how to solve this error?

My python version is 3.8.2, pip version 23.1.2, mac OS Ventura 13.1

Here is a little more info on the error

Running command Preparing metadata (pyproject.toml)
  error in lasso setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers; Expected end or semicolon (after version specifier)
      PyJWT>=1<2 
1
  • 1
    Looks like there's a typo in the pyproject.toml of the internal package. PyJWT>=1<2 isn't a valid requirement specifier. It's probably meant to be >=1,<2 or >=1.2 Jul 9 at 21:29

1 Answer 1

1

The syntax of PyJWT>=1<2 is not correct versioning in pyproject.toml

You can write it as follows:

PyJWT >= 1, < 2

or

PyJWT = "^1.0.0"
1
  • thanks, I updated the syntax and was able to install the package now
    – eia92
    Jul 10 at 7:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.