Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update setup.py, newly in uwsgitop==0.11 #56

Closed
wants to merge 2 commits into from
Closed

Update setup.py, newly in uwsgitop==0.11 #56

wants to merge 2 commits into from

Conversation

corvofeng
Copy link

In my server, the pip-7.1.0 and pip-8.1.1 also exist, and when I install the uwsgitop.

>  /usr/local/bin/pip install -V
pip 7.1.0 from /usr/local/lib/python2.7/dist-packages (python 2.7)

> /usr/local/bin/pip install -U uwsgitop
You are using pip version 7.1.0, however version 18.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting uwsgitop
  Downloading http://pypi.doubanio.com/packages/8a/7a/9501084f6d2739b8a7d35ef5fb9cb539edb6e0a0d559366598b82bb7a96e/uwsgitop-0.11.tar.gz
    Complete output from command python setup.py egg_info:
    error in uwsgitop setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers; Expected version spec in argparse;python_version<"3" at ;python_version<"3"
    
    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-DMc9_S/uwsgitop

There are many servers that keep the old pip version, I believe that people with old pip will also encounter this problem, hope you can accept my pull request.

In my server, the pip-7.1.0 and pip-8.1.1 also exist,  and when I install the uwsgitop.
```
>  /usr/local/bin/pip install -V
pip 7.1.0 from /usr/local/lib/python2.7/dist-packages (python 2.7)

> /usr/local/bin/pip install -U uwsgitop
You are using pip version 7.1.0, however version 18.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting uwsgitop
  Downloading http://pypi.doubanio.com/packages/8a/7a/9501084f6d2739b8a7d35ef5fb9cb539edb6e0a0d559366598b82bb7a96e/uwsgitop-0.11.tar.gz
    Complete output from command python setup.py egg_info:
    error in uwsgitop setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers; Expected version spec in argparse;python_version<"3" at ;python_version<"3"
    
    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-DMc9_S/uwsgitop
```

There are many servers that keep the old pip version, I believe that people with old pip will also encounter this problem, hope you can accept my pull request.
@xrmx
Copy link
Owner

xrmx commented Jan 4, 2019

Which version of setuptools do you have? I think you need at least setuptools 20.5 which has been released in march 2016.

@corvofeng
Copy link
Author

Which version of setuptools do you have?

pip --version
pip 7.1.0 from /usr/local/lib/python2.7/dist-packages (python 2.7)

python -c 'import setuptools; print setuptools.__version__'
18.1

Maybe we can get some inspiration from here: install-requires-vs-requirements.

@xrmx
Copy link
Owner

xrmx commented Jan 5, 2019

@corvofeng have you tried to upgrade setuptools to at least 20.5?

@corvofeng
Copy link
Author

@xrmx

Yeah, I have already tried to upgrade the setuptools, it worked.
Thanks for your advice.

And why I made this pull request isn't to ask the solution.
I have so many servers to upgrade. it's a long term job.
As a library, I hope this project will be more stabilize.

Here I found the docs from Building and Distributing Packages with Setuptools:

install_requires:
    A string or list of strings specifying what other distributions need to be
    installed when this one is. See the section below on Declaring
    Dependencies for details and examples of the format of this argument.

A string of list of strings, I don't know why two install_requires
written together, after all, the install_requires support the list.

Hope you could accept my pull request and follow the
official documentation instructions.

Thanks for you time, you could chose accept my PR, or close it.

Sorry for my poor English expression, I'm not an native English speaker.

@xrmx
Copy link
Owner

xrmx commented Jan 7, 2019

If you have old machines I'd to say to just stick with 0.10, no need to upgrade. Cannot accept PR because i think is wrong: python_version<3 is not a correct install_requires.

@xrmx
Copy link
Owner

xrmx commented Jan 8, 2019

@corvofeng i think you are misunderstanding the issue, that syntax means that argparse is required only for python<3 not that python<3 is required.

@corvofeng
Copy link
Author

Thank you for your explanation, And I found some docs which help the newcomers. Maybe some people like me don't know this new grammar

Conditional Python Dependencies
PEP 508 -- Dependency specification for Python Software Packages

Maybe uwsgitop can reomve this dependency in next year, or in 0.12.

Best wishes.

@corvofeng corvofeng closed this Jan 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants