docker / docker/docker-py

Flaky test: AttachContainerTest.test_attach_no_stream

Open
#2,513 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
7.2k
Forks
1.7k
Avg merge
13d 8h
Merged PRs (30d)
2

Description

We've seen this test fail in moby CI (disabled it at some point https://github.com/moby/moby/pull/39848, but it looks to be still flaky after re-enabling it recently when we updated to the latest docker-py version https://github.com/moby/moby/pull/40467)

[2020-02-10T23:40:44.429Z] =================================== FAILURES ===================================
[2020-02-10T23:40:44.429Z] __________________ AttachContainerTest.test_attach_no_stream ___________________
[2020-02-10T23:40:44.429Z] tests/integration/api_container_test.py:1250: in test_attach_no_stream
[2020-02-10T23:40:44.429Z]     assert output == 'hello\n'.encode(encoding='ascii')
[2020-02-10T23:40:44.429Z] E   AssertionError: assert b'' == b'hello\n'
[2020-02-10T23:40:44.429Z] E     Right contains more items, first extra item: 104
[2020-02-10T23:40:44.429Z] E     Use -v to get the full diff
[2020-02-10T23:40:44.429Z] ------- generated xml file: /src/bundles/test-docker-py/junit-report.xml -------

Perhaps this needs a change similar to https://github.com/docker/docker-py/commit/ef043559c4bbd3d1fbc06277160c253fab6df879 (https://github.com/docker/docker-py/pull/2307)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tests/integration/api_container_test.py at AttachContainerTest.test_attach_no_stream and reproduce the CI failure where output is empty instead of b'hello\n'. Review the referenced docker-py commit and pull request for a comparable change. Done means the test reliably receives the expected output without remaining flaky.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, python
Domain
api, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.