stopping the sound server in PySol code -- how?

Peter Hansen peter at engcorp.com
Sat Nov 20 11:09:55 EST 2004


Lynn wrote:
> Lynn wrote:
>   File "/data/apps/pysol-4.82/src/pysolaudio.py", line 44, in ?
>     import pysolsoundserver
> ImportError: No module named pysolsoundserver
> 
> If I strip out every instance of importing that module, it eventually dies
> with a tk box alerting me thatg the global pysolsoundserver is not defined.

This is Python: just make your own pysolsoundserver module
with dummy do-nothing functions.  It's possible that the
use of pysolsoundserver is too complex for this to be easy,
but often all you need to do is run the program repeatedly,
watching for each exception and then implementing dummy
functions/objects that basically trick the calling routines
into thinking everything is working fine.  No need to edit
the original source at all!

Consider it your first foray into test-driven development,
since in effect that's what you would be doing. ;-)

-Peter



More information about the Python-list mailing list