espressif / pytest-embedded

A pytest plugin that designed for embedded testing
https://docs.espressif.com/projects/pytest-embedded/en/latest/
MIT License
93 stars 26 forks source link

fix: use socket bind to get allowed port #260

Closed horw closed 10 months ago

horw commented 10 months ago

While running the test, we encountered a conflict with port allocation. The current PR is an attempt to resolve this issue.

horw commented 10 months ago

One of the solutions I think we can use is port 0. There are a few ways to implement this:

So I chose the first solution, as I don't believe there is a very high probability of a port allocation error.

hfudev commented 10 months ago

Thank you. LGTM. Let's fix the ci problems first.

horw commented 10 months ago

Thank you. LGTM. Let's fix the ci problems first.

I have taken a look at this problem:

hfudev commented 10 months ago

Thank you!