Skip to content

gh-153531: fix thread safety of setting func.__doc__ and func.__module__ - #154851

Merged
kumaraditya303 merged 1 commit into
python:mainfrom
kumaraditya303:func-ft
Jul 29, 2026
Merged

gh-153531: fix thread safety of setting func.__doc__ and func.__module__#154851
kumaraditya303 merged 1 commit into
python:mainfrom
kumaraditya303:func-ft

Conversation

@kumaraditya303

@kumaraditya303 kumaraditya303 commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Fixes thread safety of setting func.__doc__ and func.__module__ with stop the world pause as there are C-API functions which return borrowed refs to the attributes. Also remove stw from func.__annotate__ which was already safe with critical section and there are no C-API functions to access them.

@kumaraditya303 kumaraditya303 added skip news topic-free-threading needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes labels Jul 29, 2026
@kumaraditya303
kumaraditya303 merged commit 9ccd5bb into python:main Jul 29, 2026
60 checks passed
@kumaraditya303
kumaraditya303 deleted the func-ft branch July 29, 2026 06:35
@miss-islington-app

Copy link
Copy Markdown

Thanks @kumaraditya303 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖

@bedevere-app

bedevere-app Bot commented Jul 29, 2026

Copy link
Copy Markdown

GH-154856 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 pre-release feature fixes, bugs and security fixes label Jul 29, 2026
@bedevere-app

bedevere-app Bot commented Jul 29, 2026

Copy link
Copy Markdown

GH-154857 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Jul 29, 2026
kumaraditya303 added a commit that referenced this pull request Jul 29, 2026
…__module__ (GH-154851) (#154857)

gh-153531: fix thread safety of setting func.__doc__ and func.__module__ (GH-154851)
(cherry picked from commit 9ccd5bb)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
kumaraditya303 added a commit that referenced this pull request Jul 29, 2026
…__module__ (GH-154851) (#154856)

gh-153531: fix thread safety of setting func.__doc__ and func.__module__ (GH-154851)
(cherry picked from commit 9ccd5bb)

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
@bedevere-bot

Copy link
Copy Markdown

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

Hi! The buildbot AMD64 Android 3.14 (tier-3) has failed when building commit 92d8672.

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/1694/builds/1319) and take a look at the build logs.
  4. Check if the failure is related to this commit (92d8672) 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/1694/builds/1319

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

Click to see traceback logs
remote: Enumerating objects: 15, done.        
remote: Counting objects:   6% (1/15)        
remote: Counting objects:  13% (2/15)        
remote: Counting objects:  20% (3/15)        
remote: Counting objects:  26% (4/15)        
remote: Counting objects:  33% (5/15)        
remote: Counting objects:  40% (6/15)        
remote: Counting objects:  46% (7/15)        
remote: Counting objects:  53% (8/15)        
remote: Counting objects:  60% (9/15)        
remote: Counting objects:  66% (10/15)        
remote: Counting objects:  73% (11/15)        
remote: Counting objects:  80% (12/15)        
remote: Counting objects:  86% (13/15)        
remote: Counting objects:  93% (14/15)        
remote: Counting objects: 100% (15/15)        
remote: Counting objects: 100% (15/15), done.        
remote: Compressing objects:  20% (1/5)        
remote: Compressing objects:  40% (2/5)        
remote: Compressing objects:  60% (3/5)        
remote: Compressing objects:  80% (4/5)        
remote: Compressing objects: 100% (5/5)        
remote: Compressing objects: 100% (5/5), done.        
remote: Total 8 (delta 7), reused 3 (delta 3), pack-reused 0 (from 0)        
From https://github.com/python/cpython
 * branch                    3.14       -> FETCH_HEAD
Note: switching to '92d8672bf5847a70155587f979645e9f0bff5b28'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at 92d8672bf58 [3.14] gh-153531: fix thread safety of setting func.__doc__ and func.__module__ (GH-154851) (#154857)
Switched to and reset branch '3.14'

configure: WARNING: no system libmpdec found; falling back to bundled libmpdec (deprecated and scheduled for removal in Python 3.16)

In file included from ../../Include/internal/pycore_dict.h:11,
                 from ../../Objects/typeobject.c:7:
In function ‘Py_DECREF_MORTAL’,
    inlined from ‘PyStackRef_CLOSE’ at ../../Include/internal/pycore_stackref.h:653:9,
    inlined from ‘_PyThreadState_PopCStackRef’ at ../../Include/internal/pycore_stackref.h:775:5,
    inlined from ‘vectorcall_maybe’ at ../../Objects/typeobject.c:3048:9:
../../Include/internal/pycore_object.h:481:8: warning: array subscript 0 is outside array bounds of ‘PyObject[0]’ {aka ‘struct _object[]’} [-Warray-bounds]
  481 |     if (--op->ob_refcnt == 0) {
      |        ^

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100  201k  100  201k    0     0   425k      0 --:--:-- --:--:-- --:--:--  425k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 43710  100 43710    0     0  86094      0 --:--:-- --:--:-- --:--:--  992k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100 6254k  100 6254k    0     0  13.5M      0 --:--:-- --:--:-- --:--:-- 13.5M
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100 1270k  100 1270k    0     0  2771k      0 --:--:-- --:--:-- --:--:-- 2771k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100  629k  100  629k    0     0  1728k      0 --:--:-- --:--:-- --:--:-- 1728k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100  511k  100  511k    0     0  1286k      0 --:--:-- --:--:-- --:--:-- 1286k
configure: WARNING: no system libmpdec found; falling back to bundled libmpdec (deprecated and scheduled for removal in Python 3.16)

../../Python/fileutils.c:460:1: warning: unused function 'decode_current_locale' [-Wunused-function]
  460 | decode_current_locale(const char* arg, wchar_t **wstr, size_t *wlen,
      | ^~~~~~~~~~~~~~~~~~~~~
../../Python/fileutils.c:679:1: warning: unused function 'encode_current_locale' [-Wunused-function]
  679 | encode_current_locale(const wchar_t *text, char **str,
      | ^~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
../../Modules/_localemodule.c:195:1: warning: unused function 'is_all_ascii' [-Wunused-function]
  195 | is_all_ascii(const char *str)
      | ^~~~~~~~~~~~
1 warning generated.
../../Modules/_hacl/Lib_Memzero0.c:66:6: warning: "Your platform does not support any safe implementation of memzero -- consider a pull request!" [-W#warnings]
   66 |     #warning "Your platform does not support any safe implementation of memzero -- consider a pull request!"
      |      ^
1 warning generated.
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:283:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  283 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:290:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  290 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:436:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  436 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:443:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  443 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:549:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  549 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:558:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  558 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:580:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  580 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:591:9: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  591 |         CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |         ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:688:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  688 |           CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:733:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  733 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:759:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  759 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:770:9: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  770 |         CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |         ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:783:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  783 |           CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:928:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  928 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:941:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  941 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:958:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  958 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:965:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  965 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:1200:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
 1200 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:1220:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
 1220 |           CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
19 warnings generated.

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  8784  100  8784    0     0  30322      0 --:--:-- --:--:-- --:--:-- 30289
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  2894  100  2894    0     0  12315      0 --:--:-- --:--:-- --:--:-- 12474
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 43504  100 43504    0     0   167k      0 --:--:-- --:--:-- --:--:--  167k

@bedevere-bot

Copy link
Copy Markdown

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

Hi! The buildbot AMD64 Android 3.15 (tier-3) has failed when building commit 048b1f6.

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/2074/builds/325) and take a look at the build logs.
  4. Check if the failure is related to this commit (048b1f6) 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/2074/builds/325

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

Click to see traceback logs
remote: Enumerating objects: 8, done.        
remote: Counting objects:  16% (1/6)        
remote: Counting objects:  33% (2/6)        
remote: Counting objects:  50% (3/6)        
remote: Counting objects:  66% (4/6)        
remote: Counting objects:  83% (5/6)        
remote: Counting objects: 100% (6/6)        
remote: Counting objects: 100% (6/6), done.        
remote: Compressing objects:  16% (1/6)        
remote: Compressing objects:  33% (2/6)        
remote: Compressing objects:  50% (3/6)        
remote: Compressing objects:  66% (4/6)        
remote: Compressing objects:  83% (5/6)        
remote: Compressing objects: 100% (6/6)        
remote: Compressing objects: 100% (6/6), done.        
remote: Total 8 (delta 0), reused 0 (delta 0), pack-reused 2 (from 1)        
From https://github.com/python/cpython
 * branch                    3.15       -> FETCH_HEAD
Note: switching to '048b1f6dfdeb859fdb4c36f0d9ca2cd7a8192f57'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at 048b1f6dfde [3.15] gh-153531: fix thread safety of setting func.__doc__ and func.__module__ (GH-154851) (#154856)
Switched to and reset branch '3.15'

configure: WARNING: no system libmpdec found; falling back to pure-Python version for the decimal module

In file included from ../../Include/internal/pycore_dict.h:11,
                 from ../../Objects/typeobject.c:8:
In function ‘Py_DECREF_MORTAL’,
    inlined from ‘PyStackRef_CLOSE’ at ../../Include/internal/pycore_stackref.h:682:9,
    inlined from ‘_PyThreadState_PopCStackRef’ at ../../Include/internal/pycore_stackref.h:790:5,
    inlined from ‘vectorcall_maybe’ at ../../Objects/typeobject.c:3148:9:
../../Include/internal/pycore_object.h:456:8: warning: array subscript 0 is outside array bounds of ‘PyObject[0]’ {aka ‘struct _object[]’} [-Warray-bounds]
  456 |     if (--op->ob_refcnt == 0) {
      |        ^

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100  201k  100  201k    0     0   424k      0 --:--:-- --:--:-- --:--:--  424k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100 43710  100 43710    0     0   114k      0 --:--:-- --:--:-- --:--:--  114k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100 6254k  100 6254k    0     0  12.3M      0 --:--:-- --:--:-- --:--:-- 12.3M
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100 1436k  100 1436k    0     0  3147k      0 --:--:-- --:--:-- --:--:-- 3147k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  629k  100  629k    0     0  1394k      0 --:--:-- --:--:-- --:--:-- 9389k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0

100  511k  100  511k    0     0  1038k      0 --:--:-- --:--:-- --:--:-- 1038k
configure: WARNING: no system libmpdec found; falling back to pure-Python version for the decimal module

../../Python/fileutils.c:458:1: warning: unused function 'decode_current_locale' [-Wunused-function]
  458 | decode_current_locale(const char* arg, wchar_t **wstr, size_t *wlen,
      | ^~~~~~~~~~~~~~~~~~~~~
../../Python/fileutils.c:677:1: warning: unused function 'encode_current_locale' [-Wunused-function]
  677 | encode_current_locale(const wchar_t *text, char **str,
      | ^~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
../../Modules/_localemodule.c:195:1: warning: unused function 'is_all_ascii' [-Wunused-function]
  195 | is_all_ascii(const char *str)
      | ^~~~~~~~~~~~
1 warning generated.
../../Modules/pwdmodule.c:69:16: warning: unused variable 'pwd_db_mutex' [-Wunused-variable]
   69 | static PyMutex pwd_db_mutex = {0};
      |                ^~~~~~~~~~~~
1 warning generated.
../../Modules/_hacl/Lib_Memzero0.c:66:6: warning: "Your platform does not support any safe implementation of memzero -- consider a pull request!" [-W#warnings]
   66 |     #warning "Your platform does not support any safe implementation of memzero -- consider a pull request!"
      |      ^
1 warning generated.
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:283:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  283 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:290:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  290 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:436:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  436 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:443:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  443 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:549:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  549 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:558:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  558 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:580:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  580 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:591:9: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  591 |         CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |         ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:688:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  688 |           CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:733:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  733 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:759:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  759 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:770:9: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  770 |         CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |         ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:783:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  783 |           CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:928:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  928 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:941:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  941 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:958:5: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  958 |     CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
      |     ^
../../Modules/expat/xmltok_impl.c:116:5: note: expanded from macro 'CHECK_NMSTRT_CASES'
  116 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:965:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
  965 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:1200:7: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
 1200 |       CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |       ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
In file included from ../../Modules/expat/xmltok.c:309:
../../Modules/expat/xmltok_impl.c:1220:11: warning: fallthrough annotation in unreachable code [-Wunreachable-code-fallthrough]
 1220 |           CHECK_NAME_CASES(enc, ptr, end, nextTokPtr)
      |           ^
../../Modules/expat/xmltok_impl.c:87:5: note: expanded from macro 'CHECK_NAME_CASES'
   87 |     EXPAT_FALLTHROUGH;                                                         \
      |     ^
../../Modules/expat/fallthrough.h:45:33: note: expanded from macro 'EXPAT_FALLTHROUGH'
   45 | #      define EXPAT_FALLTHROUGH __attribute__((fallthrough))
      |                                 ^
19 warnings generated.

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  8784  100  8784    0     0  41553      0 --:--:-- --:--:-- --:--:-- 41630
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  2894  100  2894    0     0  11402      0 --:--:-- --:--:-- --:--:-- 11438
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 43504  100 43504    0     0   203k      0 --:--:-- --:--:-- --:--:--  203k

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants