GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test_ftplib: test_storlines() fails randomly · Issue #109845 · python/cpython

test_ftplib: test_storlines() fails randomly #109845

New issue
Copy link
New issue
Copy link
Closed
Closed
test_ftplib: test_storlines() fails randomly#109845
Copy link
Assignees
serhiy-storchaka
Labels
testsTests in the Lib/test dirTests in the Lib/test dir

Description

@vstinner
vstinner
opened on Sep 25, 2023
Issue body actions

s390x RHEL7 Refleaks 3.x:

0:00:19 load avg: 3.25 [ 17/463/1] test_ftplib failed (1 failure)
beginning 6 repetitions
123456
..test test_ftplib failed -- Traceback (most recent call last):
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel-z.refleak/build/Lib/test/test_ftplib.py", line 634, in test_storlines
    self.check_data(self.server.handler_instance.last_received_data, RETR_DATA)
  File "/home/dje/cpython-buildarea/3.x.edelsohn-rhel-z.refleak/build/Lib/test/test_ftplib.py", line 505, in check_data
    self.assertEqual(len(received), len(expected))
AssertionError: 12019 != 12018

build: https://buildbot.python.org/all/#/builders/129/builds/890

I can reproduce the failure locally on Linux with command:

vstinner@mona$ ./python -m test test_ftplib -m test_storlines -u all -j10 --forever -R 3:3 
(...)
0:00:10 load avg: 24.24 [ 11/1] test_ftplib failed (1 failure)
beginning 6 repetitions
123456
..test test_ftplib failed -- Traceback (most recent call last):
  File "/home/vstinner/python/main/Lib/test/test_ftplib.py", line 634, in test_storlines
    self.check_data(self.server.handler_instance.last_received_data, RETR_DATA)
  File "/home/vstinner/python/main/Lib/test/test_ftplib.py", line 505, in check_data
    self.assertEqual(len(received), len(expected))
AssertionError: 12019 != 12018

Linked PRs

  • gh-109845: Make test_ftplib more stable under load #109912
  • [3.12] gh-109845: Make test_ftplib more stable under load (GH-109912) #109919
  • [3.11] gh-109845: Make test_ftplib more stable under load (GH-109912) #109920

Activity

  1. vstinner
    added
    testsTests in the Lib/test dirTests in the Lib/test dir
    on Sep 25, 2023
  2. serhiy-storchaka
    self-assigned this
    on Sep 26, 2023
  3. serhiy-storchaka commented on Sep 26, 2023

    @serhiy-storchaka
    serhiy-storchaka
    on Sep 26, 2023
    Member
    More actions

    I found the cause and am writing a fix.

  4. vstinner commented on Sep 26, 2023

    @vstinner
    vstinner
    on Sep 26, 2023
    MemberAuthor
    More actions

    I looked at the issue but I didn't see anything obvious 🤷🏻‍♂️ Also, I got scared when I saw that the server is implemented with asyncore, the zombie module 😱

  5. serhiy-storchaka
    added 2 commits that reference this issue on Sep 26, 2023

    pythongh-109845: Make test_ftplib more reliable under load

    7c676ce

    pythongh-109845: Make test_ftplib more stable under load

    60f0d84
  6. serhiy-storchaka commented on Sep 26, 2023

    @serhiy-storchaka
    serhiy-storchaka
    on Sep 26, 2023
    Member
    More actions

    Other unstable tests are test_storbinary and test_encoding_param.

    I changed also test_retrbinary, test_retrbinary_rest and test_transfer which potentially can fail for same reason, although I cannot reproduce this.

  7. serhiy-storchaka
    added a commit that references this issue on Sep 26, 2023

    gh-109845: Make test_ftplib more stable under load (GH-109912)

    2ef2fff
  8. miss-islington
    added 2 commits that reference this issue on Sep 26, 2023

    pythongh-109845: Make test_ftplib more stable under load (pythonGH-10…

    a3de33d

    pythongh-109845: Make test_ftplib more stable under load (pythonGH-10…

    c328541
  9. serhiy-storchaka
    added a commit that references this issue on Sep 26, 2023

    [3.11] gh-109845: Make test_ftplib more stable under load (GH-109912) (…

    4e66eca
  10. csm10495
    added a commit that references this issue on Sep 28, 2023

    pythongh-109845: Make test_ftplib more stable under load (pythonGH-10…

    925b25e
  11. vstinner commented on Sep 29, 2023

    @vstinner
    vstinner
    on Sep 29, 2023
    MemberAuthor
    More actions

    Thanks for the fix @serhiy-storchaka.

  12. vstinner
    closed this as completedon Sep 29, 2023
  13. Yhg1s
    added a commit that references this issue on Oct 2, 2023

    [3.12] gh-109845: Make test_ftplib more stable under load (GH-109912) (…

    1f62200
  14. Glyphack
    added a commit that references this issue on Sep 2, 2024

    pythongh-109845: Make test_ftplib more stable under load (pythonGH-10…

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

Metadata

Metadata

Assignees

  • @serhiy-storchaka
    serhiy-storchaka

Labels

testsTests in the Lib/test dirTests in the Lib/test dir

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.