[SCM] zynjacku/master: Fix a startup bug when lash daemon is not installed.

alessio at users.alioth.debian.org alessio at users.alioth.debian.org
Wed Apr 27 16:17:39 UTC 2011


The following commit has been merged in the master branch:
commit 5838916fb61721e0dfc34b17e376cfbd9dc19b29
Author: Alessio Treglia <alessio at debian.org>
Date:   Wed Apr 27 18:17:08 2011 +0200

    Fix a startup bug when lash daemon is not installed.

diff --git a/debian/patches/1004-lashd_not_found.patch b/debian/patches/1004-lashd_not_found.patch
new file mode 100644
index 0000000..064bce7
--- /dev/null
+++ b/debian/patches/1004-lashd_not_found.patch
@@ -0,0 +1,71 @@
+Description: When pylash is available and lashd isn't, the program fails to
+ run and returns a message similar to the following one:
+ .
+ zynalessio at alessio-laptop:~$ zynjacku 
+ Attempting to auto-start LASH server
+ lash_dbus_service_connect_handler: Failed to connect to LASH server: The \
+ name org.nongnu.LASH was not provided by any .service files
+ Traceback (most recent call last):
+   File "/usr/bin/zynjacku", line 371, in <module>
+     main()
+   File "/usr/bin/zynjacku", line 357, in main
+     print "Successfully connected to LASH server at " +  \
+     lash.lash_get_server_name(lash_client)
+ TypeError: cannot concatenate 'str' and 'NoneType' objects
+Author: Alessio Treglia <alessio at debian.org>
+Forwarded: no
+---
+ lv2rack  |   13 +++++--------
+ zynjacku |   13 +++++--------
+ 2 files changed, 10 insertions(+), 16 deletions(-)
+
+--- zynjacku.orig/zynjacku
++++ zynjacku/zynjacku
+@@ -344,17 +344,14 @@ def main():
+ 
+     if lash:                        # If LASH python bindings are available
+         # sys.argv is modified by this call
+-        lash_client = lash.init(sys.argv, "zynjacku", lash.LASH_Config_File)
++        try:
++            lash_client = lash.init(sys.argv, "zynjacku", lash.LASH_Config_File)
++            print "Successfully connected to LASH server at " +  lash.lash_get_server_name(lash_client)
++        except:
++            lash_client = None
+     else:
+         lash_client = None
+ 
+-    # TODO: generic argument processing goes here
+-
+-    # Yeah , this sounds stupid, we connected earlier, but we dont want to show this if we got --help option
+-    # This issue should be fixed in pylash, there is a reason for having two functions for initialization after all
+-    if lash_client:
+-        print "Successfully connected to LASH server at " +  lash.lash_get_server_name(lash_client)
+-
+     if len(sys.argv) == 2 and sys.argv[1][-9:] != ".zynjacku":
+         host = ZynjackuHostOne(program_data, client_name, sys.argv[1])
+     else:
+--- zynjacku.orig/lv2rack
++++ zynjacku/lv2rack
+@@ -309,17 +309,14 @@ def main():
+ 
+     if lash:                        # If LASH python bindings are available
+         # sys.argv is modified by this call
+-        lash_client = lash.init(sys.argv, "lv2rack", lash.LASH_Config_File)
++        try:
++            lash_client = lash.init(sys.argv, "lv2rack", lash.LASH_Config_File)
++            print "Successfully connected to LASH server at " +  lash.lash_get_server_name(lash_client)
++        except:
++            lash_client = None
+     else:
+         lash_client = None
+ 
+-    # TODO: generic argument processing goes here
+-
+-    # Yeah , this sounds stupid, we connected earlier, but we dont want to show this if we got --help option
+-    # This issue should be fixed in pylash, there is a reason for having two functions for initialization after all
+-    if lash_client:
+-        print "Successfully connected to LASH server at " +  lash.lash_get_server_name(lash_client)
+-
+     if len(sys.argv) == 2 and sys.argv[1][-8:] != ".lv2rack":
+         host = lv2rack_single(program_data, client_name, sys.argv[1])
+     else:
diff --git a/debian/patches/series b/debian/patches/series
index db988c8..b65c513 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
 1001-shebangs.patch
 1002-buildsystem.patch
 1003-libglade_to_gtkbuilder.patch
+1004-lashd_not_found.patch

-- 
zynjacku packaging



More information about the pkg-multimedia-commits mailing list