| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
bpo-21016, bpo-1294959: The pydoc and trace modules now use the
sysconfig module to get the path to the Python standard library, to
support uncommon installation path like /usr/lib64/python3.9/ on
Fedora.
Co-Authored-By: Jan Matějek <jmatejek@suse.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is the converse of GH-15353 -- in addition to plenty of
scripts in the tree that are marked with the executable bit
(and so can be directly executed), there are a few that have
a leading `#!` which could let them be executed, but it doesn't
do anything because they don't have the executable bit set.
Here's a command which finds such files and marks them. The
first line finds files in the tree with a `#!` line *anywhere*;
the next-to-last step checks that the *first* line is actually of
that form. In between we filter out files that already have the
bit set, and some files that are meant as fragments to be
consumed by one or another kind of preprocessor.
$ git grep -l '^#!' \
| grep -vxFf <( \
git ls-files --stage \
| perl -lane 'print $F[3] if (!/^100644/)' \
) \
| grep -ve '\.in$' -e '^Doc/includes/' \
| while read f; do
head -c2 "$f" | grep -qxF '#!' \
&& chmod a+x "$f"; \
done
|
|
|
|
|
|
| |
Previously, it was hard to tell whether a function should be awaited. It was also incorrect (per PEP 484) to put this in the type hint for coroutine functions. Added this info to the output of builtins.help and pydoc.
https://bugs.python.org/issue36045
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
(GH-11366)
|
| |
|
|
|
|
|
|
|
| |
Replace time.time() with time.monotonic() in tests to measure time
delta.
test_zipfile64: display progress every minute (60 secs) rather than
every 5 minutes (5*60 seconds).
|
|
|
|
| |
Pydoc now does not duplicate docstrings for aliases of inherited methods.
|
|
|
|
|
| |
For builtin types with builtin subclasses, help() on the type now shows up
to 4 of the subclasses. This partially replaces the exception hierarchy
information previously displayed in Python 2.7.
|
| |
|
|
|
|
|
| |
literals on pydoc. (GH-6701)
Also update the list of string prefixes.
|
|
|
|
|
|
| |
Adds some working and markup fixes that I missed
in the initial commit for this issue.
(Follow-up to GH-6419)
|
|
|
|
|
|
|
|
|
|
| |
The pydoc CLI assumed -m pydoc would add the empty string
to sys.path, and hence got confused when it switched to
adding the full initial working directory instead.
This refactors the pydoc CLI path manipulation to be
more testable, and ensures it won't accidentally
remove the standard library directory containing
pydoc itself from sys.path.
|
|
|
|
| |
In pydoc.py, the reference to Python' documentation was in http.
The link has been updated to use https.
|
|
|
| |
Per PEP 492, 'async' and 'await' should become proper keywords in 3.7.
|
|
|
|
| |
New -n flag allow overriding localhost with custom value,
for example to run from containers.
|
|
|
|
|
|
|
|
|
|
| |
* bpo-31238: pydoc ServerThread.stop() now joins itself
ServerThread.stop() now joins itself to wait until
DocServer.serve_until_quit() completes and then explicitly sets
its docserver attribute to None to break a reference cycle.
* Add NEWS.d entry
|
| |
|
| |
|
|
|
|
| |
constructor signature if __text_signature__ is provided for the class.
|
| |
|
|
|
|
| |
one set by the env var PAGER).
|
|
|
|
| |
one set by the env var PAGER).
|
|\ |
|
| | |
|
|\ \
| |/ |
|
| |
| |
| |
| | |
Patch by Sean Rodman, test by Kaushik N.
|
| |
| |
| |
| | |
to format short Python version.
|
|\ \
| |/ |
|
| |\ |
|
| | |
| | |
| | |
| | | |
Implementation by Antoine Pitrou.
|
|\ \ \
| |/ / |
|
|/ /
| |
| |
| | |
were defined.
|
| | |
|
|\ \
| |/ |
|
| | |
|
| |
| |
| |
| |
| |
| | |
The concept of .pyo files no longer exists. Now .pyc files have an
optional `opt-` tag which specifies if any extra optimizations beyond
the peepholer were applied.
|
| | |
|
|\ \
| |/ |
|
| |
| |
| |
| |
| |
| | |
The previous patch only dealt with KeyboardInterrupt when all of the
data had been consumed by the pager. This deals with the interrupt
when some data is still pending.
|
|\ \
| |/ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, if you hit ctl-c while the pager was active, the python that
launched the subprocess for the pager would see the KeyboardInterrupt in the
__exit__ method of the subprocess context manager where it was waiting for the
subprocess to complete, ending the wait. This would leave the pager running,
while the interactive interpreter, after handling the exception by printing
it, would go back to trying to post a prompt...but the pager would generally
have the terminal in raw mode, and in any case would be still trying to read
from stdin. On some systems, even exiting python at that point would not
restore the terminal mode. The problem with raw mode could also happen if
ctl-C was hit when pydoc was called from the shell command line and the pager
was active.
Instead, we now wait on the subprocess in a loop, ignoring KeyboardInterrupt
just like the pager does, until the pager actually exits.
(Note: this was a regression relative to python2...in python2 the pager
is called via system, and system does not return until the pager exits.)
|
| |
| |
| |
| |
| | |
shows the help on str. help('help') now shows the help on help().
Original patch by Mark Lawrence.
|
|\ \
| |/
| |
| | |
differs from file system encoding (e.g. on Mac OS).
|
| |
| |
| |
| | |
differs from file system encoding (e.g. on Mac OS).
|
|\ \
| |/ |
|