iccmr-quantum / OSC-Qasm

A simple OSC Python interface for executing Qasm code.
MIT License
11 stars 1 forks source link

Stdout stderr pipe to OSC #28

Closed Itaborala closed 2 years ago

Itaborala commented 2 years ago

This branch solves #6 and #15 . New Max console features. Ready for version 1.2.0

omarcostahamido commented 2 years ago

☝️ @Itaborala feel free to commit suggestion and merge :)

Itaborala commented 2 years ago

@omarcostahamido This is an alternate solution. it triggers FileLikeErrorOSC() and doesn't duplicate messages. As an advantage, it prints the 'error in osc_qasm.py (...) [...] switch to python console to learn more.

Still, I think the results will be almost identical

Itaborala commented 2 years ago

What do you think?

omarcostahamido commented 2 years ago

let me try

omarcostahamido commented 2 years ago

ok I agree that would be the simplest solution to this problem but, for these errors in particular, that have already been digested into simple messages, it is not very useful to redirect the user back to the python terminal. They will only look at a confusing traceback of our own code and not learn anything more useful than what we have already told them.

Itaborala commented 2 years ago

Fair Point! I will revert back to commit b795bc9 and merge. Agreed?

omarcostahamido commented 2 years ago

Agreed!

omarcostahamido commented 2 years ago

Well done @Itaborala 🎉 Protip: when you merge you can also add the message this fixes #6 to automatically close #6 when merging is complete.