Skip to content

Make tests compatible with pyftpdlib 2.0 #595

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

musicinmybrain
Copy link

@musicinmybrain musicinmybrain commented Jun 14, 2025

Type of changes

  • Tests

Checklist

  • I've run the latest black with default args on new code.
  • I've updated CHANGELOG.md and CONTRIBUTORS.md where appropriate. Is this needed?
  • I've added tests for new code. N/A, testing fixes
  • I accept that @PyFilesystem/maintainers may be pedantic in the code review.

Description

Inspired by @mweinelt via #591.

  • Updates the pyftpdlib test dependency from ~=1.5 to ~=2.0
  • Uses pyftpdlib’s test extra (introduced in 2.0) to bring in dependencies for pyftpdlib.test, rather than naming them and maintaining their version bounds manually.
  • Follow the renaming of ThreadedTestFTPd to FtpdThreadWrapper

I tested this locally in a Python 3.13 virtualenv, first applying #570 and #587. I do find that I can sometimes get all the tests to pass, but there are almost always some flaky failures where it seems like the test FTP server is not ready, like:

====================================== short test summary info =======================================
FAILED tests/test_ftpfs.py::TestFTPFS::test_download_4 - fs.errors.RemoteConnectionError: unable to connect to 127.0.0.1
FAILED tests/test_ftpfs.py::TestFTPFSNoMLSD::test_download_0 - fs.errors.RemoteConnectionError: unable to connect to 127.0.0.1
====================== 2 failed, 2652 passed, 26 skipped, 46 warnings in 38.61s ======================

I have not tried to understand or fix that.

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.

1 participant