-
Notifications
You must be signed in to change notification settings - Fork 430
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
Running setup.py directly is deprecated #737
Changes from all commits
672a395
38bc4eb
fe2850a
933eefb
17f53a6
bc4684b
20f37b5
c864ba5
f3cd270
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,15 @@ or from source. | |
|
||
To install using `pip`,:: | ||
|
||
$ pip install -U django-celery-beat | ||
$ pip install --upgrade django-celery-beat | ||
|
||
Installing the current default branch | ||
------------------------------------- | ||
|
||
$ python3 -m venv .venv | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here: #737 (comment) With these changes, it looks like the steps are more about venvs, not the actual goal of the doc. |
||
$ source .venv/bin/activate | ||
$ pip install --upgrade pip | ||
$ pip install git+https://github.com/celery/django-celery-beat.git | ||
|
||
Downloading and installing from source | ||
-------------------------------------- | ||
|
@@ -16,13 +24,13 @@ http://pypi.python.org/pypi/django-celery-beat | |
|
||
You can install it by doing the following,:: | ||
|
||
$ python3 -m venv .venv | ||
$ source .venv/bin/activate | ||
$ pip install --upgrade build pip | ||
$ tar xvfz django-celery-beat-0.0.0.tar.gz | ||
$ cd django-celery-beat-0.0.0 | ||
$ python setup.py build | ||
# python setup.py install | ||
|
||
The last command must be executed as a privileged user if | ||
you are not currently using a virtualenv. | ||
$ python -m build | ||
$ pip install . | ||
|
||
Using the development version | ||
----------------------------- | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
|
||
import pytest | ||
# we have to import the pytest plugin fixtures here, | ||
# in case user did not do the `python setup.py develop` yet, | ||
# in case user did not yet `pip install ".[develop]"`, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Doesn't it make better sense with "yet" at end of the sentence, as the before? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It felt like a dangling participle when I read it. (But I would bet dollars to doughnuts that it is not a participle. 😃) |
||
# that installs the pytest plugin into the setuptools registry. | ||
from celery.contrib.pytest import (celery_app, celery_config, | ||
celery_enable_logging, celery_parameters, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure venv management should be covered here. There are tons of ways of to manage a venv, and forcing one in a tutorial ends up badly in my experience. Just a mention of a venv should be enough, as is before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is Python's built-in way of creating and enabling a venv. Users are free to choose alternative methods but I prefer explicit steps here to document what we know works and avoid issues being opened around implicit steps.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be easily paraphrased as "pushing an opinionated tooling", which worries me. IMO, for anything related to venv, considering how every detail of that topic is open for a million different debates, it's better to keep an equal distance to all options.
Of course, you can ignore my comment; it's not a big thing, but I believe these types of details are more important than most people care for.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Opinionated tooling would have been a suggestion to use
uv
. 😄I do tons of responding to Node.js and node-gyp issues. It is there (and elsewhere) that I have learned the hard way that incomplete directions and assumptions lead to long-winded discussions.
I think suggesting the one that is built-in and requires zero third-party software is relatively safe.