Skip to content

Conversation

@cheops
Copy link
Contributor

@cheops cheops commented Apr 9, 2024

by line 282 o_char and e_char are always empty
since while o_char != b'': and while e_char != b'': will have done their job

when this break is executed, it might be that p.poll() has not yet filled in the returncode
This might result in all kind of strange behavior if the result of spawn is checked and found to be None in stead of 0

Same concern for the break for prompt.
Maybe after o_buf = read() a call should be added p.wait() to ensure the child process has terminated?

cheops added 2 commits April 9, 2024 18:11
by line 282 o_char and e_char are always empty since `while o_char != b'':` and `while e_char != b'':` will have done their job
o_char and e_char are always empty, then returncode is None
@kdschlosser
Copy link
Collaborator

I am actually going to be redoing how the subprocesses are handled. It's turned into a monster is what it has done and I need to clean it up. Parsing subprocess output can be a royal pain to do especially when the process needs to run for a long time which is the case here.

@kdschlosser
Copy link
Collaborator

I fixed the build. I wrote the spawn function over again. It has a smaller code footprint now and it should have less of an issue working.

@cheops
Copy link
Contributor Author

cheops commented Apr 10, 2024

build for esp32 (on WSL-ubuntu) works again
you may close and disregard this pull request :-)

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

Labels

None yet

2 participants