Skip to content

Commit f313e8c

Browse files
authored
Merge branch 'main' into simple_cframe
2 parents 1de88f6 + 4e60566 commit f313e8c

File tree

790 files changed

+10181
-3291
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

790 files changed

+10181
-3291
lines changed

.github/workflows/build.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,9 @@ jobs:
8585
- name: Check limited ABI symbols
8686
run: make check-limited-abi
8787
- name: Check Autoconf version 2.69
88-
run: grep "Generated by GNU Autoconf 2.69" configure
88+
run: |
89+
grep "Generated by GNU Autoconf 2.69" configure
90+
grep "PKG_PROG_PKG_CONFIG" aclocal.m4
8991
9092
build_win32:
9193
name: 'Windows (x86)'
@@ -126,8 +128,12 @@ jobs:
126128
PYTHONSTRICTEXTENSIONBUILD: 1
127129
steps:
128130
- uses: actions/checkout@v2
131+
- name: Prepare homebrew environment variables
132+
run: |
133+
echo "LDFLAGS=-L$(brew --prefix tcl-tk)/lib" >> $GITHUB_ENV
134+
echo "PKG_CONFIG_PATH=$(brew --prefix [email protected])/lib/pkgconfig:$(brew --prefix tcl-tk)/lib/pkgconfig" >> $GITHUB_ENV
129135
- name: Configure CPython
130-
run: ./configure --with-pydebug --with-openssl=/usr/local/opt/openssl --prefix=/opt/python-dev
136+
run: ./configure --with-pydebug --prefix=/opt/python-dev
131137
- name: Build CPython
132138
run: make -j4
133139
- name: Display build info

Doc/c-api/call.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ Object Calling API
185185
Various functions are available for calling a Python object.
186186
Each converts its arguments to a convention supported by the called object –
187187
either *tp_call* or vectorcall.
188-
In order to do as litle conversion as possible, pick one that best fits
188+
In order to do as little conversion as possible, pick one that best fits
189189
the format of data you have available.
190190
191191
The following table summarizes the available functions;

Doc/c-api/init_config.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ There are two kinds of configuration:
2222
* The :ref:`Isolated Configuration <init-isolated-conf>` can be used to embed
2323
Python into an application. It isolates Python from the system. For example,
2424
environments variables are ignored, the LC_CTYPE locale is left unchanged and
25-
no signal handler is registred.
25+
no signal handler is registered.
2626

2727
The :c:func:`Py_RunMain` function can be used to write a customized Python
2828
program.
@@ -706,7 +706,7 @@ PyConfig
706706
* Otherwise, use the :term:`locale encoding`:
707707
``nl_langinfo(CODESET)`` result.
708708
709-
At Python statup, the encoding name is normalized to the Python codec
709+
At Python startup, the encoding name is normalized to the Python codec
710710
name. For example, ``"ANSI_X3.4-1968"`` is replaced with ``"ascii"``.
711711
712712
See also the :c:member:`~PyConfig.filesystem_errors` member.

Doc/distributing/index.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ installing other Python projects, refer to the
3131
Key terms
3232
=========
3333

34-
* the `Python Packaging Index <https://pypi.org>`__ is a public
34+
* the `Python Package Index <https://pypi.org>`__ is a public
3535
repository of open source licensed packages made available for use by
3636
other Python users
3737
* the `Python Packaging Authority
@@ -127,14 +127,14 @@ involved in creating and publishing a project:
127127

128128
* `Project structure`_
129129
* `Building and packaging the project`_
130-
* `Uploading the project to the Python Packaging Index`_
130+
* `Uploading the project to the Python Package Index`_
131131
* `The .pypirc file`_
132132

133133
.. _Project structure: \
134134
https://packaging.python.org/tutorials/packaging-projects/#packaging-python-projects
135135
.. _Building and packaging the project: \
136136
https://packaging.python.org/tutorials/packaging-projects/#creating-the-package-files
137-
.. _Uploading the project to the Python Packaging Index: \
137+
.. _Uploading the project to the Python Package Index: \
138138
https://packaging.python.org/tutorials/packaging-projects/#uploading-the-distribution-archives
139139
.. _The .pypirc file: \
140140
https://packaging.python.org/specifications/pypirc/
@@ -150,7 +150,7 @@ These are quick answers or links for some common tasks.
150150

151151
This isn't an easy topic, but here are a few tips:
152152

153-
* check the Python Packaging Index to see if the name is already in use
153+
* check the Python Package Index to see if the name is already in use
154154
* check popular hosting sites like GitHub, Bitbucket, etc to see if there
155155
is already a project with that name
156156
* check what comes up in a web search for the name you're considering

Doc/faq/design.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,7 @@ Why don't generators support the with statement?
714714
For technical reasons, a generator used directly as a context manager
715715
would not work correctly. When, as is most common, a generator is used as
716716
an iterator run to completion, no closing is needed. When it is, wrap
717-
it as "contextlib.closing(generator)" in the 'with' statment.
717+
it as "contextlib.closing(generator)" in the 'with' statement.
718718

719719

720720
Why are colons required for the if/while/def/class statements?

Doc/howto/functional.rst

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,10 @@ output must only depend on its input.
6565

6666
Some languages are very strict about purity and don't even have assignment
6767
statements such as ``a=3`` or ``c = a + b``, but it's difficult to avoid all
68-
side effects. Printing to the screen or writing to a disk file are side
69-
effects, for example. For example, in Python a call to the :func:`print` or
70-
:func:`time.sleep` function both return no useful value; they're only called for
71-
their side effects of sending some text to the screen or pausing execution for a
72-
second.
68+
side effects, such as printing to the screen or writing to a disk file. Another
69+
example is a call to the :func:`print` or :func:`time.sleep` function, neither
70+
of which returns a useful value. Both are called only for their side effects
71+
of sending some text to the screen or pausing execution for a second.
7372

7473
Python programs written in functional style usually won't go to the extreme of
7574
avoiding all I/O or all assignments; instead, they'll provide a

Doc/includes/sqlite3/text_factory.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
con = sqlite3.connect(":memory:")
44
cur = con.cursor()
55

6-
AUSTRIA = "\xd6sterreich"
6+
AUSTRIA = "Österreich"
77

8-
# by default, rows are returned as Unicode
8+
# by default, rows are returned as str
99
cur.execute("select ?", (AUSTRIA,))
1010
row = cur.fetchone()
1111
assert row[0] == AUSTRIA

Doc/installing/index.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Key terms
4444
``venv``. It allows virtual environments to be used on versions of
4545
Python prior to 3.4, which either don't provide ``venv`` at all, or
4646
aren't able to automatically install ``pip`` into created environments.
47-
* The `Python Packaging Index <https://pypi.org>`__ is a public
47+
* The `Python Package Index <https://pypi.org>`__ is a public
4848
repository of open source licensed packages made available for use by
4949
other Python users.
5050
* the `Python Packaging Authority
@@ -78,7 +78,7 @@ The standard packaging tools are all designed to be used from the command
7878
line.
7979

8080
The following command will install the latest version of a module and its
81-
dependencies from the Python Packaging Index::
81+
dependencies from the Python Package Index::
8282

8383
python -m pip install SomePackage
8484

@@ -226,7 +226,7 @@ the installation process.
226226

227227
With the introduction of support for the binary ``wheel`` format, and the
228228
ability to publish wheels for at least Windows and macOS through the
229-
Python Packaging Index, this problem is expected to diminish over time,
229+
Python Package Index, this problem is expected to diminish over time,
230230
as users are more regularly able to install pre-built extensions rather
231231
than needing to build them themselves.
232232

Doc/library/argparse.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1109,7 +1109,7 @@ Anything with more interesting error-handling or resource management should be
11091109
done downstream after the arguments are parsed.
11101110

11111111
For example, JSON or YAML conversions have complex error cases that require
1112-
better reporting than can be given by the ``type`` keyword. An
1112+
better reporting than can be given by the ``type`` keyword. A
11131113
:exc:`~json.JSONDecodeError` would not be well formatted and a
11141114
:exc:`FileNotFound` exception would not be handled at all.
11151115

Doc/library/ast.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1266,7 +1266,7 @@ Pattern matching
12661266
the pattern matches the subject.
12671267

12681268
``body`` contains a list of nodes to execute if the pattern matches and
1269-
the result of evaluating the guard expression is truthy.
1269+
the result of evaluating the guard expression is true.
12701270

12711271
.. doctest::
12721272

@@ -1920,7 +1920,7 @@ and classes for traversing abstract syntax trees:
19201920
If source contains a null character ('\0'), :exc:`ValueError` is raised.
19211921

19221922
.. warning::
1923-
Note that succesfully parsing souce code into an AST object doesn't
1923+
Note that successfully parsing source code into an AST object doesn't
19241924
guarantee that the source code provided is valid Python code that can
19251925
be executed as the compilation step can raise further :exc:`SyntaxError`
19261926
exceptions. For instance, the source ``return 42`` generates a valid

0 commit comments

Comments
 (0)