7 ms·
If the UI is my shell then it is. If it's part of a larger script being executed by python embedded in a cron job wrapped in a burrito, it may not be
by ketralnis 2y ago
If the UI is my shell then it is. If it's part of a larger script being executed by python embedded in a cron job wrapped in a burrito, it may not be
- shadowgovt 2y agoWrappers are still responsible for proxying or handling errors and wrappers that fail to do so are wrapping poorly.
- timgilbert 2y agoDon't bring monads into this
- Kwpolska 2y agoIf you've got Python, you shouldn't be running grep within it, just open the file with Python and search through it in the usual ways. Far less flaky than a subprocess.
- pavel_lishin 2y agoShouldn't, sure. But people use software in all kinds of sub-optimal ways, and it would behoove an author to make sure that it doesn't fail dramatically when this happens.
- shadowgovt 2y agoI'm not even sure it's suboptimal to shell out to grep instead of writing a bespoke search in Python. It would depend on the amount of data I'm sifting through. Grep is very optimized for what it does.
- WJW 2y agoYou misunderstand entirely how much the author of any software with "achievements" cares about whether it works well in shell scripts and/or from python.