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

Provide an error message when no outputs installed #233

Open
polyzen opened this issue Jan 1, 2019 · 0 comments

Comments

Projects
None yet
1 participant
@polyzen
Copy link
Contributor

commented Jan 1, 2019

Now that both pychromecast and socos are optional (as only one or the other are needed), it would probably be good to error out when neither are found.

~ > mkchromecast                                                                       
Mkchromecast v0.3.8.1                                                                  
Creating Pulseaudio Sink...                                                            
Open Pavucontrol and Select the Mkchromecast Sink.                                     
Starting Local Streaming Server                                                        
[Done]                                                                                 
Selected backend: parec                                                                
Selected audio codec: mp3
Default bitrate used: 192k
Default sample rate used: 44100Hz.
No devices found!
PID of main process: 7743
PID of streaming process: 7750
 * Serving Flask app "mkchromecast.audio" (lazy loading)
 * Environment: production
   WARNING: Do not use the development server in a production environment.
   Use a production WSGI server instead.
 * Debug mode: off
Cleaning up /tmp/...
[Done]
Process Process-1:
Traceback (most recent call last):
  File "/usr/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap
    self.run()
  File "/usr/lib/python3.7/multiprocessing/process.py", line 99, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/share/mkchromecast/mkchromecast/audio.py", line 789, in start_app
    app.run(host='0.0.0.0', port=port, passthrough_errors=False)
  File "/usr/lib/python3.7/site-packages/flask/app.py", line 943, in run
    run_simple(host, port, self, **options)
  File "/usr/lib/python3.7/site-packages/werkzeug/serving.py", line 814, in run_simple
    inner()
  File "/usr/lib/python3.7/site-packages/werkzeug/serving.py", line 774, in inner
    fd=fd)
  File "/usr/lib/python3.7/site-packages/werkzeug/serving.py", line 660, in make_server
    passthrough_errors, ssl_context, fd=fd)
  File "/usr/lib/python3.7/site-packages/werkzeug/serving.py", line 577, in __init__
    self.address_family), handler)
  File "/usr/lib/python3.7/socketserver.py", line 452, in __init__
    self.server_bind()
  File "/usr/lib/python3.7/http/server.py", line 137, in server_bind
    socketserver.TCPServer.server_bind(self)
  File "/usr/lib/python3.7/socketserver.py", line 466, in server_bind
    self.socket.bind(self.server_address)
OSError: [Errno 98] Address already in use

mkchromecast -t launches normally, but of course will not be able to find any streaming devices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.