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

Spaces in CWD cause pipes to fail #181

Open
masaccio opened this issue Aug 5, 2021 · 0 comments
Open

Spaces in CWD cause pipes to fail #181

masaccio opened this issue Aug 5, 2021 · 0 comments
Labels

Comments

@masaccio
Copy link

masaccio commented Aug 5, 2021

If the current working directory has spaces in it, the pstats to pipe will fail as the variables are not quoted. The pipes library correctly quotes the assignment of IN and OUT but the command needs to quote them:

t.append("{} -f pstats \"$IN\"".format(self.gprof2dot), "f-")
t.append("dot -Tsvg -o \"$OUT\"", "-f")

Of course that will fail if there is a double quote in the current path, so an alternative would be temporary files or doing the interprocess plumbing but the quoting above does at least solve the situation where somebody is working in a directory with a space somewhere on the path.

Working in a symlink path doesn't help (which is what I do) as os.path resolves the path to its actual path in the filesystem.

@eeaston eeaston added the bug label Nov 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants