From 63b357f0ee0ce43b65b4e518825f81062cf10610 Mon Sep 17 00:00:00 2001 From: Albert Santoni Date: Tue, 11 Nov 2014 11:18:55 -0500 Subject: [PATCH 1/3] Updated requirements for airtime_analyzer to make python-requests support SNI properly --- python_apps/airtime_analyzer/setup.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/python_apps/airtime_analyzer/setup.py b/python_apps/airtime_analyzer/setup.py index c47b05167..3694e6fe5 100644 --- a/python_apps/airtime_analyzer/setup.py +++ b/python_apps/airtime_analyzer/setup.py @@ -29,6 +29,10 @@ setup(name='airtime_analyzer', 'mock', 'python-daemon', 'requests', + # These next 3 are required for requests to support SSL with SNI. This is extremely important. Learned this the hard way... + 'ndg-httpsclient', + 'pyasn1', + 'pyopenssl' ], zip_safe=False, data_files=data_files) From b324031ee683005be0307e3b323c4709ce3a01eb Mon Sep 17 00:00:00 2001 From: Albert Santoni Date: Tue, 11 Nov 2014 18:41:09 -0500 Subject: [PATCH 2/3] Disable those new requirements because pip requires gcc to install them --- python_apps/airtime_analyzer/setup.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/python_apps/airtime_analyzer/setup.py b/python_apps/airtime_analyzer/setup.py index 3694e6fe5..0816f8d14 100644 --- a/python_apps/airtime_analyzer/setup.py +++ b/python_apps/airtime_analyzer/setup.py @@ -29,10 +29,11 @@ setup(name='airtime_analyzer', 'mock', 'python-daemon', 'requests', - # These next 3 are required for requests to support SSL with SNI. This is extremely important. Learned this the hard way... - 'ndg-httpsclient', - 'pyasn1', - 'pyopenssl' + # These next 3 are required for requests to support SSL with SNI. Learned this the hard way... + # What sucks is that GCC is required to pip install these. + #'ndg-httpsclient', + #'pyasn1', + #'pyopenssl' ], zip_safe=False, data_files=data_files) From 95517cac874aa807c836fa7aa53a3776a9b95ed5 Mon Sep 17 00:00:00 2001 From: drigato Date: Wed, 12 Nov 2014 14:45:50 -0500 Subject: [PATCH 3/3] Fix exception thrown when the analyzer doesn't return filesize with the metadata --- .../application/modules/rest/controllers/MediaController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airtime_mvc/application/modules/rest/controllers/MediaController.php b/airtime_mvc/application/modules/rest/controllers/MediaController.php index dbbc346ba..87af946bb 100644 --- a/airtime_mvc/application/modules/rest/controllers/MediaController.php +++ b/airtime_mvc/application/modules/rest/controllers/MediaController.php @@ -226,7 +226,7 @@ class Rest_MediaController extends Zend_Rest_Controller //as a foreign key to cc_music_dirs. if (isset($requestData["full_path"])) { $fileSizeBytes = filesize($requestData["full_path"]); - if ($fileSizeBytes === false) + if (!isset($fileSizeBytes) || $fileSizeBytes === false) { $file->setDbImportStatus(2)->save(); $this->fileNotFoundResponse();