Skip to content

Subprocess Fails With Concatenated String #671

Closed Answered by vsquared
vsquared asked this question in Q&A
Discussion options

You must be logged in to vote

This works better but the output goes to Thonny console instead of logArea of editor.
runStr = ('%s %s') % (pyStr,fileStr)
Need to use the following to direct output to logArea:
s = subprocess.check_output(runStr, shell=True)
Original post was edited and should work as expected after changes.

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@vsquared
Comment options

@hx2A
Comment options

hx2A Jul 1, 2025
Maintainer

@vsquared
Comment options

@vsquared
Comment options

Answer selected by vsquared
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants