10000 bpo-45442: Add deactivate step to venv tutorial. by ShivnarenSrinivasan · Pull Request #28959 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-45442: Add deactivate step to venv tutorial. #28959

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

Closed
wants to merge 18 commits into from

Conversation

ShivnarenSrinivasan
Copy link
Contributor
@ShivnarenSrinivasan ShivnarenSrinivasan commented Oct 14, 2021

Document process to deactivate virtual environment.

https://bugs.python.org/issue45442

< 8000 input type="hidden" name="oid" value="b057f99445221ef9ca4828e21426e46d346d3dee" autocomplete="off" data-targets="batch-deferred-content.inputs" />
@the-knights-who-say-ni
Copy link

Hello, and thanks for your contribution!

I'm a bot set up to make sure that the project can legally accept this contribution by verifying everyone involved has signed the PSF contributor agreement (CLA).

Recognized GitHub username

We couldn't find a bugs.python.org (b.p.o) account corresponding to the following GitHub usernames:

@ShivnarenSrinivasan

This might be simply due to a missing "GitHub Name" entry in one's b.p.o account settings. This is necessary for legal reasons before we can look at this contribution. Please follow the steps outlined in the CPython devguide to rectify this issue.

You can check yourself to see if the CLA has been received.

Thanks again for the contribution, we look forward to reviewing it!

@bedevere-bot bedevere-bot added the docs Documentation in the Doc dir label Oct 14, 2021
@@ -88,6 +88,9 @@ For example:
'~/envs/tutorial-env/lib/python3.5/site-packages']
>>>

To deactivate a virtual environment, type::
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Error in CI : https://dev.azure.com/Python/cpython/_build/results?buildId=89615&view=logs&j=4db1505a-29e5-5cc0-240b-53a8a2681f75&t=a975920c-8356-5388-147c-613d5fab0171&l=517

Warning, treated as error:
/home/vsts/work/1/s/Doc/tutorial/venv.rst:93:Definition list ends without a blank line; unexpected unindent.
make: *** [Makefile:51: build] Error 2

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hopefully fixed with the second commit

Co-authored-by: Pradyun Gedam <pradyunsg@gmail.com>
To deactivate a virtual environment, type::

deactivate
into the terminal. This is a shell function defined by the script when the virtual environment is activated.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The specific detail about deactivate being a shell function isn't in general correct, though it is true on POSIX and with PowerShell. There is a corresponding deactivate.bat which comes into play on Windows where cmd.exe rather than PowerShell is used. You could just remove this detail, which isn't especially important to know from a user perspective.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got you—will remove the line.

@bedevere-bot
Copy link

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core d 8000 evelopers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

ShivnarenSrinivasan and others added 14 commits October 15, 2021 19:30
Remove two functions from the limited C API:

* PyMarshal_WriteLongToFile()
* PyMarshal_WriteObjectToFile()

The PEP 384 excludes functions expecting "FILE*" from the stable ABI.

Remove also the Py_MARSHAL_VERSION macro from the limited C API.
The <Python.h> header file no longer includes <stdio.h> if the
Py_LIMITED_API macro is defined.
Remove redundant "#ifndef Py_LIMITED_API" in funcobject.h.
Move classobject.h, context.h, genobject.h and longintrepr.h header
files from Include/ to Include/cpython/.

Remove redundant "#ifndef Py_LIMITED_API" in context.h.

Remove explicit #include "longintrepr.h" in C files. It's not needed,
Python.h already includes it.
…28969)

Move the interpreteridobject.h header file from Include/ to
Include/internal/. It only provides private functions.
Move Include/eval.h content into Include/ceval.h and
Include/cpython/ceval.h, and remove Include/eval.h.
…8975)

Rename Include/namespaceobject.h to
Include/internal/pycore_namespace.h.

The _testmultiphase extension is now built with the
Py_BUILD_CORE_MODULE macro defined to access _PyNamespace_Type.

object.c: remove unused "pycore_context.h" include.
@ShivnarenSrinivasan
Copy link
Contributor Author

Bit of a mess, clearly—apologies to all.

Would it be easier to just close this PR and start from scratch? It was meant to be a oneline update to a doc tutorial page.

@ShivnarenSrinivasan ShivnarenSrinivasan deleted the doc-venv branch October 15, 2021 15:02
miss-islington pushed a commit that referenced this pull request Oct 15, 2021
@vsajip Sorry for the trouble—made a [fairly significant] git error in the previous PR.

Have edited the patch as you had said in #28959.

Automerge-Triggered-By: GH:vsajip
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting changes docs Documentation in the Doc dir skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants
0