Skip to content

Conversation

@ThierryMT
Copy link
Contributor

@ThierryMT ThierryMT commented Oct 27, 2025

Fixes #140381

Problem

Tests asserting "slow_fibonacci" in test_profiling were flaky on slower architectures (i686/s390x) because the function wasn't called frequently enough for the profiler to reliably capture it.

Solution

Changed slow_fibonacci to run every 2nd iteration instead of every 5th iteration, increasing its call frequency from 20% to 50% of iterations.

Testing

This should resolve the flaky test failures on i686/s390x builds.

@bedevere-app bedevere-app bot added the tests Tests in the Lib/test dir label Oct 27, 2025
@bedevere-app
Copy link

bedevere-app bot commented Oct 27, 2025

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@pablogsal pablogsal enabled auto-merge (squash) November 18, 2025 23:41
@pablogsal pablogsal merged commit 652c764 into python:main Nov 19, 2025
46 checks passed
@ThierryMT ThierryMT deleted the fix-issue-140381 branch November 19, 2025 00:02
StanFromIreland pushed a commit to StanFromIreland/cpython that referenced this pull request Dec 6, 2025
ashm-dev pushed a commit to ashm-dev/cpython that referenced this pull request Dec 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tests asserting "slow_fibonacci" in test_profiling flaky fail on i686/s390x builds in Fedora Linux

2 participants