Projects
Multimedia
pulseaudio-dlna
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 7
View file
pulseaudio-dlna.changes
Changed
@@ -1,4 +1,13 @@ ------------------------------------------------------------------- +Sat Aug 8 19:26:41 UTC 2015 - antoine.belvire@laposte.net + +- Update to 0.4.4: + * Add --disable-ssdp-listener option + * Fix a bug with applications which remove and re-add streams all + the time + * Add a missing dependency: python-psutil + +------------------------------------------------------------------- Tue Aug 4 16:30:20 UTC 2015 - antoine.belvire@laposte.net - Update to 0.4.3:
View file
pulseaudio-dlna.spec
Changed
@@ -17,7 +17,7 @@ Name: pulseaudio-dlna -Version: 0.4.3 +Version: 0.4.4 Release: 0 Summary: A DLNA server which brings DLNA/UPnP support to PulseAudio License: GPL-3.0 @@ -37,6 +37,7 @@ Requires: python-gobject >= 3.12.0 Requires: python-notify2 >= 0.3 Requires: python-protobuf >= 2.5.0 +Requires: python-psutil >= 1.2.1 Requires: python-requests >= 2.2.1 Requires: python-setproctitle >= 1.0.1 Requires: sox >= 14.4.1
View file
pulseaudio-dlna-0.4.3.tar.gz/README.md -> pulseaudio-dlna-0.4.4.tar.gz/README.md
Changed
@@ -36,6 +36,11 @@ ## Changelog ## + * __0.4.4__ - (_2015-08-07_) + - Added `--disable-ssdp-listener` option + - Fixed a bug with applications which remove and re-add streams all the time + - Added a missing dependency `python-psutil` + * __0.4.3__ - (_2015-08-02_) - Fixed a bug when trying to terminate an encoder process - Catch exceptions when trying to update pulseaudio sinks @@ -43,7 +48,7 @@ * __0.4.2__ - (_2015-08-02_) - The mp3 encoder is now prioritize over wav - - Added '--disable-switchback' option + - Added `--disable-switchback` option - Wav encoders do not longer share their encoder process * __0.4.1__ - (_2015-07-27_) @@ -165,6 +170,7 @@ - python-gobject - python-protobuf - python-notify2 +- python-psutil - vorbis-tools - sox - lame @@ -174,7 +180,7 @@ You can install all the dependencies in Ubuntu via: - sudo apt-get install python2.7 python-pip python-setuptools python-dbus python-beautifulsoup python-docopt python-requests python-setproctitle python-gobject python-protobuf python-notify2 vorbis-tools sox lame flac faac opus-tools + sudo apt-get install python2.7 python-pip python-setuptools python-dbus python-beautifulsoup python-docopt python-requests python-setproctitle python-gobject python-protobuf python-notify2 python-psutil vorbis-tools sox lame flac faac opus-tools ### PulseAudio DBus module ### @@ -265,7 +271,7 @@ ### CLI ### Usage: - pulseaudio-dlna [--host <host>] [--port <port>] [--encoder <encoder>] [--bit-rate=<rate>] [--filter-device=<filter-device>] [--renderer-urls <urls>] [--debug] [--fake-http10-content-length] [--disable-switchback] + pulseaudio-dlna [--host <host>] [--port <port>] [--encoder <encoder>] [--bit-rate=<rate>] [--filter-device=<filter-device>] [--renderer-urls <urls>] [--debug] [--fake-http10-content-length] [--disable-switchback] [--disable-ssdp-listener] pulseaudio-dlna [-h | --help | --version] Options: @@ -286,6 +292,7 @@ --debug enables detailed debug messages. --fake-http10-content-length If set, the content-length of HTTP 1.0 requests will be set to 100 GB. --disable-switchback If set, streams won't switched back to the default sink if a device disconnects. + --disable-ssdp-listener If set, the application won't bind to the port 1900 and therefore the automatic discovery of new devices won't work. -v --version Show the version. -h --help Show the help.
View file
pulseaudio-dlna-0.4.3.tar.gz/debian/changelog -> pulseaudio-dlna-0.4.4.tar.gz/debian/changelog
Changed
@@ -1,3 +1,12 @@ +pulseaudio-dlna (0.4.4) trusty; urgency=low + + * Added '--disable-ssdp-listener' option + * Fixed a bug with applications which remove and re-add streams all the time + * Added a missing dependency python-psutil + + -- Massimo Mund <mo@lancode.de> Fri, 07 Aug 2015 20:31:16 +0100 + + pulseaudio-dlna (0.4.3) trusty; urgency=low * Fixed a bug when trying to terminate an encoder process
View file
pulseaudio-dlna-0.4.3.tar.gz/debian/control -> pulseaudio-dlna-0.4.4.tar.gz/debian/control
Changed
@@ -26,6 +26,7 @@ python-gobject (>=3.12.0), python-protobuf (>=2.5.0), python-notify2 (>=0.3), + python-psutil (>=1.2.1), vorbis-tools (>=1.4.0), sox (>=14.4.1), lame (>=3.99.0),
View file
pulseaudio-dlna-0.4.3.tar.gz/debian/pulseaudio-dlna.1 -> pulseaudio-dlna-0.4.4.tar.gz/debian/pulseaudio-dlna.1
Changed
@@ -1,11 +1,11 @@ .\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.44.1. -.TH PULSEAUDIO-DLNA "1" "August 2015" "pulseaudio-dlna 0.4.3" "User Commands" +.TH PULSEAUDIO-DLNA "1" "August 2015" "pulseaudio-dlna 0.4.4" "User Commands" .SH NAME -pulseaudio-dlna \- manual page for pulseaudio-dlna 0.4.3 +pulseaudio-dlna \- manual page for pulseaudio-dlna 0.4.4 .SH DESCRIPTION .SS "Usage:" .IP -pulseaudio\-dlna [\-\-host <host>] [\-\-port <port>] [\-\-encoder <encoder>] [\-\-bit\-rate=<rate>] [\-\-filter\-device=<filter\-device>] [\-\-renderer\-urls <urls>] [\-\-debug] [\-\-fake\-http10\-content\-length] [\-\-disable\-switchback] +pulseaudio\-dlna [\-\-host <host>] [\-\-port <port>] [\-\-encoder <encoder>] [\-\-bit\-rate=<rate>] [\-\-filter\-device=<filter\-device>] [\-\-renderer\-urls <urls>] [\-\-debug] [\-\-fake\-http10\-content\-length] [\-\-disable\-switchback] [\-\-disable\-ssdp\-listener] pulseaudio\-dlna [\-h | \fB\-\-help\fR | \fB\-\-version]\fR .IP Note that _pulseaudio\-dlna_ has to run all the time while you are listening to your music. If you stop _pulseaudio\-dlna_ it will cleanly remove the created UPNP devices from PulseAudio and your UPNP devices will stop playing. @@ -61,6 +61,9 @@ \fB\-\-disable\-switchback\fR If set, streams won't switched back to the default sink if a device disconnects. .TP +\fB\-\-disable\-ssdp\-listener\fR +If set, the application won't bind to the port 1900 and therefore the automatic discovery of new devices won't work. +.TP \fB\-v\fR \fB\-\-version\fR Show the version. .TP
View file
pulseaudio-dlna-0.4.3.tar.gz/pulseaudio_dlna/__main__.py -> pulseaudio-dlna-0.4.4.tar.gz/pulseaudio_dlna/__main__.py
Changed
@@ -17,7 +17,7 @@ ''' Usage: - pulseaudio-dlna [--host <host>] [--port <port>] [--encoder <encoder>] [--bit-rate=<rate>] [--filter-device=<filter-device>] [--renderer-urls <urls>] [--debug] [--fake-http10-content-length] [--disable-switchback] + pulseaudio-dlna [--host <host>] [--port <port>] [--encoder <encoder>] [--bit-rate=<rate>] [--filter-device=<filter-device>] [--renderer-urls <urls>] [--debug] [--fake-http10-content-length] [--disable-switchback] [--disable-ssdp-listener] pulseaudio-dlna [-h | --help | --version] Note that _pulseaudio-dlna_ has to run all the time while you are listening to your music. If you stop _pulseaudio-dlna_ it will cleanly remove the created UPNP devices from PulseAudio and your UPNP devices will stop playing. @@ -43,6 +43,7 @@ --debug enables detailed debug messages. --fake-http10-content-length If set, the content-length of HTTP 1.0 requests will be set to 100 GB. --disable-switchback If set, streams won't switched back to the default sink if a device disconnects. + --disable-ssdp-listener If set, the application won't bind to the port 1900 and therefore the automatic discovery of new devices won't work. -v --version Show the version. -h --help Show the help.
View file
pulseaudio-dlna-0.4.3.tar.gz/pulseaudio_dlna/application.py -> pulseaudio-dlna-0.4.4.tar.gz/pulseaudio_dlna/application.py
Changed
@@ -123,6 +123,10 @@ if options['--disable-switchback']: disable_switchback = True + disable_ssdp_listener = False + if options['--disable-ssdp-listener']: + disable_ssdp_listener = True + try: stream_server = pulseaudio_dlna.streamserver.ThreadedStreamServer( host, port, bridges, message_queue, @@ -151,11 +155,13 @@ stream_server_address = stream_server.ip, stream_server.port ssdp_listener = pulseaudio_dlna.listener.ThreadedSSDPListener( stream_server_address, message_queue, plugins, - device_filter, locations) + device_filter, locations, disable_ssdp_listener) except socket.error: logger.error( 'The SSDP listener could not bind to the port 1900/UDP. ' - 'Perhaps this is already in use? Application terminates.') + 'Perhaps this is already in use? Application terminates. ' + 'You can disable this feature with the ' + '"--disable-ssdp-listener" flag.') sys.exit(1) self.run_process(target=stream_server.run)
View file
pulseaudio-dlna-0.4.3.tar.gz/pulseaudio_dlna/listener.py -> pulseaudio-dlna-0.4.4.tar.gz/pulseaudio_dlna/listener.py
Changed
@@ -46,15 +46,19 @@ class SSDPListener(SocketServer.UDPServer): def __init__( self, stream_server_address, message_queue, plugins, - device_filter=None, renderer_urls=None): - SocketServer.UDPServer.__init__(self, ('', 1900), SSDPRequestHandler) - multicast = struct.pack( - "=4sl", socket.inet_aton("239.255.255.250"), socket.INADDR_ANY) - self.socket.setsockopt( - socket.IPPROTO_IP, socket.IP_ADD_MEMBERSHIP, multicast) + device_filter=None, renderer_urls=None, + disable_ssdp_listener=False): + self.disable_ssdp_listener = disable_ssdp_listener + self.renderer_urls = renderer_urls self.renderers_holder = RendererHolder( stream_server_address, message_queue, plugins, device_filter) - self.renderer_urls = renderer_urls + if not self.disable_ssdp_listener: + SocketServer.UDPServer.__init__( + self, ('', 1900), SSDPRequestHandler) + multicast = struct.pack( + "=4sl", socket.inet_aton("239.255.255.250"), socket.INADDR_ANY) + self.socket.setsockopt( + socket.IPPROTO_IP, socket.IP_ADD_MEMBERSHIP, multicast) if self.renderer_urls is not None: self.renderers_holder.add_renderers_by_url(self.renderer_urls) else: @@ -63,8 +67,9 @@ logger.info('Discovery complete.') def run(self): - setproctitle.setproctitle('ssdp_listener') - SocketServer.UDPServer.serve_forever(self) + if not self.disable_ssdp_listener: + setproctitle.setproctitle('ssdp_listener') + SocketServer.UDPServer.serve_forever(self) class ThreadedSSDPListener(SocketServer.ThreadingMixIn, SSDPListener):
View file
pulseaudio-dlna-0.4.3.tar.gz/pulseaudio_dlna/pulseaudio.py -> pulseaudio-dlna-0.4.4.tar.gz/pulseaudio_dlna/pulseaudio.py
Changed
@@ -383,6 +383,7 @@ self.message_queue = message_queue self.blocked_devices = [] + self.signal_timers = {} signals = ( ('NewPlaybackStream', 'org.PulseAudio.Core1.{}', @@ -508,7 +509,7 @@ logger.info('on_device_updated "{path}"'.format( path=sink_path)) self.update() - self._handle_sink_update(sink_path) + self._delayed_handle_sink_update(sink_path) def on_fallback_sink_updated(self, sink_path): self.default_sink = PulseSinkFactory.new(self.bus, sink_path) @@ -521,7 +522,7 @@ for sink in self.sinks: for stream in sink.streams: if stream.object_path == stream_path: - self._handle_sink_update(sink.object_path) + self._delayed_handle_sink_update(sink.object_path) return def on_playback_stream_removed(self, stream_path): @@ -531,10 +532,19 @@ for stream in sink.streams: if stream.object_path == stream_path: self.update() - self._handle_sink_update(sink.object_path) + self._delayed_handle_sink_update(sink.object_path) return + def _delayed_handle_sink_update(self, sink_path): + if self.signal_timers.get(sink_path, None): + gobject.source_remove(self.signal_timers[sink_path]) + self.signal_timers[sink_path] = gobject.timeout_add( + 500, self._handle_sink_update, sink_path) + def _handle_sink_update(self, sink_path): + logger.info('_handle_sink_update {}'.format(sink_path)) + if sink_path in self.signal_timers: + del self.signal_timers[sink_path] if sink_path in self.blocked_devices: logger.info('{sink_path} was blocked!'.format(sink_path=sink_path)) @@ -543,6 +553,9 @@ for bridge in self.bridges: if bridge.device.state == bridge.device.PLAYING: if len(bridge.sink.streams) == 0: + logger.info( + 'Instructing the device "{}" to stop ...'.format( + bridge.device.label)) if bridge.device.stop() == 200: logger.info('The device "{}" was stopped.'.format( bridge.device.label)) @@ -553,6 +566,9 @@ if bridge.sink.object_path == sink_path: if bridge.device.state == bridge.device.IDLE or \ bridge.device.state == bridge.device.PAUSE: + logger.info( + 'Instructing the device "{}" to play ...'.format( + bridge.device.label)) if bridge.device.play() == 200: logger.info('The device "{}" is playing.'.format( bridge.device.label)) @@ -561,6 +577,7 @@ bridge.device.label)) self.switch_back( bridge, 'The device failed to started.') + return False def add_device(self, device): self.devices.append(device)
View file
pulseaudio-dlna-0.4.3.tar.gz/pulseaudio_dlna/streamserver.py -> pulseaudio-dlna-0.4.4.tar.gz/pulseaudio_dlna/streamserver.py
Changed
@@ -225,15 +225,6 @@ except socket.error: self.unregister(sock, lock_override=True, method=2) - for sock in r: - if sock in self.sockets: - try: - data = sock.recv(1024) - if len(data) == 0: - self.unregister(sock, lock_override=True, method=3) - except socket.error: - self.unregister(sock, lock_override=True, method=4) - finally: self.lock.release()
View file
pulseaudio-dlna-0.4.3.tar.gz/setup.py -> pulseaudio-dlna-0.4.4.tar.gz/setup.py
Changed
@@ -56,6 +56,7 @@ "setproctitle >= 1.0.1", "protobuf >= 2.5.0", "notify2 >= 0.3", + "psutil >= 1.2.1", ], entry_points={ "console_scripts": [
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.