Skip to content

bpo-43231: Fix test.test_curses.TestCurses.test_init_pair when running under -R #24539

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 15, 2021

Conversation

pablogsal
Copy link
Member

@pablogsal pablogsal commented Feb 15, 2021

@pablogsal
Copy link
Member Author

Before

❯ ./python -m test -R 3:3 test_curses -uall
0:00:00 load avg: 0.94 Run tests sequentially
0:00:00 load avg: 0.94 [1/1] test_curses
beginning 6 repetitions
123456
test test_curses failed -- Traceback (most recent call last):
  File "/home/pablogsal/github/python/master/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/pablogsal/github/python/master/Lib/test/test_curses.py", line 966, in test_init_pair
    curses.init_pair(maxpair, 0, 0)
ValueError: Color pair is greater than COLOR_PAIRS-1 (65535).

test_curses failed

== Tests result: FAILURE ==

1 test failed:
    test_curses

Total duration: 630 ms
Tests result: FAILURE

After

❯ ./python -m test -R 3:3 test_curses -uall
0:00:00 load avg: 1.04 Run tests sequentially
0:00:00 load avg: 1.04 [1/1] test_curses
beginning 6 repetitions
123456
.

== Tests result: SUCCESS ==

1 test OK.

Total duration: 1.7 sec
Tests result: SUCCESS

@ambv ambv merged commit ab2d481 into python:master Feb 15, 2021
@bedevere-bot
Copy link

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

Hi! The buildbot s390x Debian 3.x has failed when building commit ab2d481.

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/all/#builders/49/builds/790) and take a look at the build logs.
  4. Check if the failure is related to this commit (ab2d481) 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/all/#builders/49/builds/790

Failed tests:

  • test_curses

Failed subtests:

  • test_pair_content - test.test_curses.TestCurses
  • test_init_pair - test.test_curses.TestCurses

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

== Tests result: FAILURE then FAILURE ==

411 tests OK.

10 slowest tests:

  • test_concurrent_futures: 3 min 5 sec
  • test_gdb: 1 min 33 sec
  • test_multiprocessing_spawn: 1 min 31 sec
  • test_unparse: 1 min 14 sec
  • test_multiprocessing_forkserver: 1 min 12 sec
  • test_tokenize: 1 min 9 sec
  • test_peg_generator: 1 min 4 sec
  • test_asyncio: 57.5 sec
  • test_multiprocessing_fork: 57.2 sec
  • test_capi: 56.4 sec

1 test failed:
test_curses

14 tests skipped:
test_dbm_ndbm test_devpoll test_ioctl test_kqueue test_msilib
test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly
test_winconsoleio test_winreg test_winsound test_zipfile64

1 re-run test:
test_curses

Total duration: 5 min 35 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 944, in test_pair_content
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR


Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 964, in test_init_pair
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-debian-z/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR

@bedevere-bot
Copy link

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

Hi! The buildbot s390x RHEL8 LTO + PGO 3.x has failed when building commit ab2d481.

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/all/#builders/442/builds/1103) and take a look at the build logs.
  4. Check if the failure is related to this commit (ab2d481) 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/all/#builders/442/builds/1103

Failed tests:

  • test_curses

Failed subtests:

  • test_pair_content - test.test_curses.TestCurses
  • test_init_pair - test.test_curses.TestCurses

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

== Tests result: FAILURE then FAILURE ==

410 tests OK.

10 slowest tests:

  • test_concurrent_futures: 2 min 48 sec
  • test_multiprocessing_spawn: 1 min 9 sec
  • test_multiprocessing_forkserver: 1 min
  • test_multiprocessing_fork: 52.9 sec
  • test_signal: 47.1 sec
  • test_asyncio: 47.0 sec
  • test_io: 36.3 sec
  • test_imaplib: 32.5 sec
  • test_pydoc: 31.5 sec
  • test_socket: 29.0 sec

1 test failed:
test_curses

15 tests skipped:
test_devpoll test_gdb test_ioctl test_kqueue test_msilib test_nis
test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly
test_winconsoleio test_winreg test_winsound test_zipfile64

1 re-run test:
test_curses

Total duration: 3 min 30 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 944, in test_pair_content
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR


Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 964, in test_init_pair
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto-pgo/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR

@pablogsal
Copy link
Member Author

Ugh, looking into these failures

@pablogsal pablogsal deleted the bpo-43231 branch February 15, 2021 21:53
@bedevere-bot
Copy link

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

Hi! The buildbot s390x RHEL8 3.x has failed when building commit ab2d481.

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/all/#builders/509/builds/747) and take a look at the build logs.
  4. Check if the failure is related to this commit (ab2d481) 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/all/#builders/509/builds/747

Failed tests:

  • test_curses

Failed subtests:

  • test_pair_content - test.test_curses.TestCurses
  • test_init_pair - test.test_curses.TestCurses

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

== Tests result: FAILURE then FAILURE ==

411 tests OK.

10 slowest tests:

  • test_concurrent_futures: 3 min 6 sec
  • test_multiprocessing_spawn: 1 min 34 sec
  • test_capi: 1 min 28 sec
  • test_gdb: 1 min 15 sec
  • test_multiprocessing_forkserver: 1 min 15 sec
  • test_unparse: 1 min 12 sec
  • test_peg_generator: 1 min 10 sec
  • test_asyncio: 1 min 10 sec
  • test_multiprocessing_fork: 1 min
  • test_tokenize: 60.0 sec

1 test failed:
test_curses

14 tests skipped:
test_devpoll test_ioctl test_kqueue test_msilib test_nis
test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly
test_winconsoleio test_winreg test_winsound test_zipfile64

1 re-run test:
test_curses

Total duration: 6 min 36 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 964, in test_init_pair
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR


Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 944, in test_pair_content
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR

@pablogsal
Copy link
Member Author

Opened #24541

@bedevere-bot
Copy link

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

Hi! The buildbot s390x RHEL8 LTO 3.x has failed when building commit ab2d481.

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/all/#builders/567/builds/1382) and take a look at the build logs.
  4. Check if the failure is related to this commit (ab2d481) 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/all/#builders/567/builds/1382

Failed tests:

  • test_curses

Failed subtests:

  • test_pair_content - test.test_curses.TestCurses
  • test_init_pair - test.test_curses.TestCurses

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

== Tests result: FAILURE then FAILURE ==

411 tests OK.

10 slowest tests:

  • test_concurrent_futures: 2 min 44 sec
  • test_peg_generator: 2 min 43 sec
  • test_gdb: 1 min 46 sec
  • test_multiprocessing_spawn: 1 min 19 sec
  • test_multiprocessing_forkserver: 1 min
  • test_multiprocessing_fork: 58.4 sec
  • test_signal: 48.0 sec
  • test_asyncio: 45.6 sec
  • test_io: 36.3 sec
  • test_imaplib: 32.4 sec

1 test failed:
test_curses

14 tests skipped:
test_devpoll test_ioctl test_kqueue test_msilib test_nis
test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly
test_winconsoleio test_winreg test_winsound test_zipfile64

1 re-run test:
test_curses

Total duration: 5 min 24 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 964, in test_init_pair
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR


Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 47, in wrapped
    test(self, *args, **kwargs)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 944, in test_pair_content
    maxpair = self.get_pair_limit() - 1
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_curses.py", line 933, in get_pair_limit
    curses.init_pair(pair_limit, 0, 0)
_curses.error: init_extended_pair() returned ERR

adorilson pushed a commit to adorilson/cpython that referenced this pull request Mar 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants