Skip to content
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

[DNM] setup.cfs: use no-patch-threads branch of teuthology #72

Closed
wants to merge 1 commit into from

Conversation

VallariAg
Copy link
Member

@VallariAg VallariAg commented Nov 20, 2024

Testing unit test fix by using teuthology with a new commit: VallariAg/teuthology@b7e20cb.

To understand the cause of problem...
I created a new file test_new:

from fastapi import FastAPI
from fastapi.testclient import TestClient

app = FastAPI()


@app.get("/")
async def read_main():
    return {"msg": "Hello World"}


client = TestClient(app)


def test_read_main():
    response = client.get("/")
    assert response.status_code == 200
    assert response.json() == {"msg": "Hello World"}

and ran pytest tests/test_new.py::test_read_main --full-trace
Then added import teuthology to the file and it starts hanging!

With --full-trace, I get a gevent traceback. Which means teuthology and TestClient are clashing somehow.
I've seen these gevent problems before with teuthology import. Not patching threads in teuthology fixed it.

So testing it again here.

Contribution Guidelines

To sign and test your commits, please refer to Contibution guidelines.

Checklist

@VallariAg VallariAg closed this Nov 29, 2024
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