FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-80480: remove deprecated 'u' type code (array) by skirpichev · Pull Request #149535 · python/cpython · GitHub

/ cpython Public

gh-80480: remove deprecated 'u' type code (array) - #149535

Merged
vstinner merged 7 commits into
python:mainfrom
skirpichev:remove-array-u
Jun 1, 2026
Merged

gh-80480: remove deprecated 'u' type code (array)#149535
vstinner merged 7 commits into
python:mainfrom
skirpichev:remove-array-u

Conversation

skirpichev commented May 8, 2026
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

read-the-docs-community Bot commented May 8, 2026
edited
Loading

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #32933925 | 📁 Comparing 37738f4 against main (4ae1a26)

  🔍 Preview build  

77 files changed · + 1 added · ± 76 modified

+ Added

± Modified

sobolevn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Please, don't forget to fix docs in Doc/library/array.rst

skirpichev marked this pull request as ready for review May 8, 2026 07:28
skirpichev requested a review from AA-Turner as a code owner May 8, 2026 07:28
skirpichev requested a review from sobolevn May 8, 2026 08:04

sobolevn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM, but I am not a module expert, so let's wait for one to merge this :)

Copy link
Copy Markdown
Member Author

CC @vstinner

vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

I cannot find remaining references to the u format in (updated) array, memoryview and struct: good!

Note: ctypes.c_wchar uses _type_ = "u" but this type code is unrelated to struct type codes. This ctypes is not deprecated.

Comment thread Doc/whatsnew/3.16.rst
Comment thread Lib/test/test_array.py Outdated
Comment thread Lib/test/test_re.py Outdated
Comment thread Modules/arraymodule.c
skirpichev requested a review from vstinner June 1, 2026 11:03

vstinner commented Jun 1, 2026

Copy link
Copy Markdown
Member

Tests / Ubuntu (free-threading) / build and test (ubuntu-24.04-arm) (pull_request)Failing after 1m
Tests / Ubuntu / build and test (ubuntu-24.04-arm) (pull_request)Failing after 1m
Tests / WASI / build and test (pull_request)Failing after 1m

Strange, the 3 jobs failed with Error: The operation was canceled. Canceled by what? I will re-run these jobs once other jobs completed.

vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM. Thanks for the update.

Reuse array.typecodes makes the code easier to maintain.

vstinner enabled auto-merge (squash) June 1, 2026 11:10
vstinner merged commit 46b5e3e into python:main Jun 1, 2026
102 of 106 checks passed
skirpichev deleted the remove-array-u branch June 1, 2026 11:58

vstinner commented Jun 1, 2026

Copy link
Copy Markdown
Member

Merged. Thanks for the change.

Copy link
Copy Markdown

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot AMD64 Debian root 3.x (tier-1) has failed when building commit 46b5e3e.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/345/builds/14390) and take a look at the build logs.
  4. Check if the failure is related to this commit (46b5e3e) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/345/builds/14390

Failed tests:

  • test_embed

Failed subtests:

  • test_thread_state_ensure - test.test_embed.AuditingTests.test_thread_state_ensure

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):
  File "/root/buildarea/3.x.angelico-debian-amd64/build/Lib/test/test_embed.py", line 2036, in test_thread_state_ensure
    self.run_embedded_interpreter("test_thread_state_ensure")
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/buildarea/3.x.angelico-debian-amd64/build/Lib/test/test_embed.py", line 161, in run_embedded_interpreter
    self.assertEqual(p.returncode, returncode,
    ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
                     "bad returncode %d, stderr is %r" %
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                     (p.returncode, err))
                     ^^^^^^^^^^^^^^^^^^^^
AssertionError: -6 != 0 : bad returncode -6, stderr is "_testembed: ./Programs/_testembed.c:2741: test_thread_state_ensure: Assertion `_Py_atomic_load_int(&data.done) == 1' failed.\n"


Traceback (most recent call last):
  File "/root/buildarea/3.x.angelico-debian-amd64/build/Lib/test/support/__init__.py", line 948, in gc_collect
    gc.collect()
    ~~~~~~~~~~^^
ResourceWarning: unclosed file <_io.FileIO name=13 mode='wb' closefd=True>


Traceback (most recent call last):
  File "/root/buildarea/3.x.angelico-debian-amd64/build/Lib/test/support/__init__.py", line 948, in gc_collect
    gc.collect()
    ~~~~~~~~~~^^
ResourceWarning: unclosed file <_io.FileIO name=11 mode='wb' closefd=True>

vstinner commented Jun 1, 2026

Copy link
Copy Markdown
Member

Hi! The buildbot AMD64 Debian root 3.x (tier-1) has failed when building commit 46b5e3e.
test_thread_state_ensure - test.test_embed.AuditingTests.test_thread_state_ensure

That's the unrelated issue gh-150391.

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

4 participants


Back | FazBrowse Home | New Git URL