From a8792a7b97cbdb1301a629cd27da18ae6288eac4 Mon Sep 17 00:00:00 2001 From: James Date: Fri, 29 Jun 2012 10:55:19 -0400 Subject: [PATCH 1/2] CC-4042: Media Library -> Non-admin user cannot see "File import in progress" - fixed. See the comment for more detail. --- airtime_mvc/application/configs/ACL.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/airtime_mvc/application/configs/ACL.php b/airtime_mvc/application/configs/ACL.php index a8e6b2adc..b60f06a4d 100644 --- a/airtime_mvc/application/configs/ACL.php +++ b/airtime_mvc/application/configs/ACL.php @@ -35,6 +35,7 @@ $ccAcl->allow('G', 'index') ->allow('G', 'schedule') ->allow('G', 'dashboard') ->allow('G', 'audiopreview') + ->allow('H', 'preference', 'is-import-in-progress') ->allow('H', 'usersettings') ->allow('H', 'plupload') ->allow('H', 'library') @@ -42,7 +43,7 @@ $ccAcl->allow('G', 'index') ->allow('A', 'playouthistory') ->allow('A', 'user') ->allow('A', 'systemstatus') - ->allow('A', 'preference'); + ->allow('A', 'preference', 'admin'); $aclPlugin = new Zend_Controller_Plugin_Acl($ccAcl); From e5e0c925e673ef4c4717a3ae00d3dea7a913f962 Mon Sep 17 00:00:00 2001 From: James Date: Fri, 29 Jun 2012 12:11:38 -0400 Subject: [PATCH 2/2] CC-4043: Pypo: add same song twice and cancel the first song, the following song wont play any more - fixed --- python_apps/pypo/pypofile.py | 4 ++++ python_apps/pypo/pypopush.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/python_apps/pypo/pypofile.py b/python_apps/pypo/pypofile.py index 6f9a213e6..cf8e199e9 100644 --- a/python_apps/pypo/pypofile.py +++ b/python_apps/pypo/pypofile.py @@ -60,10 +60,14 @@ class PypoFile(Thread): except Exception, e: dst_exists = False + media_item['already_exist'] = False do_copy = False if dst_exists: if src_size != dst_size: do_copy = True + else: + self.logger.debug("file %s already exists in local cache as %s, skipping cpoying..." % (src, dst)) + media_item['already_exist'] = True else: do_copy = True diff --git a/python_apps/pypo/pypopush.py b/python_apps/pypo/pypopush.py index 347b856fa..cb71937a3 100644 --- a/python_apps/pypo/pypopush.py +++ b/python_apps/pypo/pypopush.py @@ -344,7 +344,7 @@ class PypoPush(Thread): time.sleep(0.1) iter_num += 1 - if media_item['started_copying']: + if media_item['started_copying'] or media_item['already_exist']: self.telnet_to_liquidsoap(media_item) else: self.logger.warn("File %s did not become ready in less than 5 seconds. Skipping...", media_item['dst'])