Lucas Bickel
e21abf1bf1
refactor(airtime_analyzer): rename to libretime-analyzer and make entrypoint pythonic
2021-01-04 10:30:27 +00:00
rjhelms
2160daea00
Fix replaygain_analyzer in Python 3.5
...
'text' argument was added in Python 3.7 as an alias of 'universal_newlines'. Using 'universal_newlines' works on Python 3.5/3.6 and should be forward-compatible.
2020-11-19 14:52:52 -05:00
Kyle Robbertze
e0e4d4c87f
Ensure all json loads calls use strings
2020-05-04 13:25:36 +02:00
Keoni Mahelona
a643883d06
Set pika version to ~1.1.0 to prevent api updates from breaking code.
...
Updated message_listener for new version.
2020-04-29 19:06:52 +02:00
Kyle Robbertze
82042e8c69
fix test failures
2020-04-29 19:06:52 +02:00
Kyle Robbertze
8346e89e99
install successfully using py3
2020-04-29 19:05:35 +02:00
Kyle Robbertze
632ba9acfe
convert print statements to py3
2020-04-29 19:05:35 +02:00
Lucas Bickel
201d3741d8
🔥 (analyzer) cleanup analyzer.py
2018-12-22 22:19:38 +01:00
Lucas Bickel
f7ceeedb04
➖ (Amazon S3) drop broken S3 support
2018-10-06 12:45:22 +02:00
Lucas Bickel
da64166fa5
Fix call with deprecated arg
2018-07-06 12:12:39 +02:00
Lucas Bickel
586314052f
Better error message when parsing WAVE file
2017-09-20 19:13:15 +02:00
Robb
bd845a016d
Merge pull request #253 from radiorabe/feature/refactor-config-structure
...
Simplify configuration file structure
2017-08-05 20:47:28 -04:00
Robb Ebright
314654dfe4
Enable logging for analyzer and pypo
2017-08-05 17:56:23 -04:00
Lucas Bickel
fa2018a2c5
Simplify configuration file structure
...
This removes most of the legacy upstream config madness by not using
weird config files spread all over the place.
This isn't the solution to other config reading fragility issues, but
it does move the whole config back to the central airtime.conf file.
2017-07-21 13:15:28 +02:00
Lucas Bickel
9ce611130c
Use file-magic instead of python-magic
...
This gets the mime type using file-magic in a most minimal way. Since the python bindings have been available as a distro package for quite a while it is written in a way so it should also run on pre pypi installs of file-magic. This means not being able to use nice things like magic.detect_from_filename due to the fact that they where added rather recently (with recently being 2 years ago).
As the mime type is only used to check for wav files that mutagen can't handle it only reads the mime type and ignores the charset and other attributes that magic can find.
Due to the fact that file-magic is not properly unicode safe I'm checking the file based on it's first 2048 bytes as per <http://stackoverflow.com/questions/34836792/python-magic-cant-identify-unicode-filename#comment57418632_34838355 >. This is not an issue since wav files need to start with a wav header by definition anyway.
I tested this sucessfully on both CentOS and Debian with files containing Unicode in their names.
2017-04-18 09:49:09 +02:00
Lucas Bickel
e28ad471f9
Rewrite config from /etc/airtime-saas to plain /etc/airtime
...
This is the results of sed -i -e 's|/etc/airtime-saas/|/etc/airtime/|' `grep -irl 'airtime-saas' airtime_mvc/ python_apps/` :P
It might need more testing, the airtime-saas part never really made sense, zf1 has environments for that, ie you would create a saas env based on production for instance.
I beleive legacy upstream was using this to share configuration between customers (ie. analyser runs only once and writes to a shared S3 bucket). I assume they mount the airtime-saas folder onto individual customers instances with a global config. Like I said, I don't feel that this makes sense since all it does is make hacking at the configs in airtime-saas a bit easier. A serious SaaS operation should be using something like puppet or ansible to achieve this.
2017-03-03 15:57:41 +01:00
Albert Santoni
965a78c54a
Merge branch 'saas-dev' into saas-dev-publishing
...
Conflicts:
airtime_mvc/application/controllers/ApiController.php
2015-11-18 12:38:18 -05:00
Albert Santoni
c85944785b
Comments
2015-10-30 18:09:56 -04:00
Albert Santoni
b49bb2e262
Loosen up Mutagen vs. Silan cue out length threshold a bit
2015-10-30 17:54:24 -04:00
Albert Santoni
7be548f30e
Fixed the airtime_analyzer unit tests
2015-10-30 17:15:33 -04:00
Albert Santoni
76f202106b
Defensive coding against Silan bugs and bump to Mutagen 1.31
2015-10-30 17:12:13 -04:00
Duncan Sommerville
a78a0d0cc8
* Fix track number bug in analyzer
...
* Move library search bar out of header
2015-09-16 17:50:21 -04:00
Albert Santoni
67c5b73db4
airtime_analyzer unit test backwards compatibility with older versions of requests
2015-07-08 10:32:35 -04:00
Albert Santoni
e1c50ecc7b
Squash urllib3 warnings to see if it helps with SAAS-714
2015-05-19 13:09:43 -04:00
Albert Santoni
add211d13c
Cleanup to help with SAAS-714
2015-05-19 12:02:19 -04:00
Albert Santoni
b3a19ae49e
Bugfix for embedded player sending too many requests on load, quieter logging for boto
2015-04-29 11:46:44 -04:00
Albert Santoni
e3390b99ef
Disable analyzer log file rotation (already handed by Upstart), clean up
2015-04-10 15:03:58 -04:00
Albert Santoni
d5012c25cb
Another small bugfix for error handling in the analyzer
2015-04-06 17:33:08 -04:00
Albert Santoni
492a7f329a
Minor airtime_analyzer error handling improvements and documentation
2015-04-06 17:22:13 -04:00
Albert Santoni
7fd58ac51b
Merge branch 'saas-s3proxy' into saas
2015-04-01 13:49:47 -04:00
Albert Santoni
ae02fe7816
Log traceback in analyzer status_reporter.py exception handler
2015-03-30 13:21:26 -04:00
Albert Santoni
271dc266fa
S3 proxy cache support + 1 minor analyzer bugfix
2015-03-26 12:08:52 -04:00
Albert Santoni
e182e73626
SAAS-602: airtime_analyzer deadlocks in S3 hostname lookup
...
* Stopped using multiprocess.subprocess because it's dangerous and
unreliable due to Python bug 6721: http://bugs.python.org/issue6721
2015-03-11 18:33:08 -04:00
Albert Santoni
ab6d83f49d
Merge branch 'saas' into saas-media-refactor
...
Conflicts:
airtime_mvc/application/Bootstrap.php
airtime_mvc/application/modules/rest/controllers/MediaController.php
2015-02-26 13:10:13 -05:00
Albert Santoni
d82f461f35
Fix missing filesize and md5 for WAVE imports
2015-02-26 13:06:29 -05:00
Albert Santoni
edd07c18ae
Fixed invalid detection of S3 backend in analyzer
2015-02-26 12:02:02 -05:00
Albert Santoni
3a1141d4c8
Merge branch 'saas' into saas-media-refactor
...
Conflicts:
airtime_mvc/application/cloud_storage/ProxyStorageBackend.php
airtime_mvc/application/controllers/ApiController.php
2015-02-25 13:02:11 -05:00
Albert Santoni
702de0f5f5
SAAS-602: Fix getaddrinfo deadlock (again)
...
Conflicts:
python_apps/airtime_analyzer/airtime_analyzer/cloud_storage_uploader.py
2015-02-24 13:14:21 -05:00
Albert Santoni
8aaf300491
Attempt a workaround for unicode hostname resolution deadlock in the
...
analyzer
2015-02-23 18:22:16 -05:00
Albert Santoni
51aa846a4c
Merge branch 'cc-5709-airtime-analyzer-refactor' into saas-media-refactor
...
Conflicts:
airtime_mvc/application/models/RabbitMq.php
python_apps/airtime_analyzer/airtime_analyzer/analyzer_pipeline.py
python_apps/airtime_analyzer/airtime_analyzer/message_listener.py
2015-02-20 18:25:38 -05:00
Albert Santoni
c868136d26
Make airtime_analyzer respect the storage_backend setting passed to it
...
by Airtime
2015-02-20 18:21:49 -05:00
drigato
58f9ffd0eb
Merge branch 'cc-5709-airtime-analyzer-store-file-size-and-hash-in-db' into saas-store-file-size-and-hash-in-db
2015-02-19 15:40:27 -05:00
drigato
b6acfb2dce
SAAS-596: Store file size and hash in database
...
Renamed metadata md5 value to match cc_files column
2015-02-19 15:39:55 -05:00
drigato
0f921cb481
Merge branch 'cc-5709-airtime-analyzer-store-file-size-and-hash-in-db' into saas-store-file-size-and-hash-in-db
2015-02-19 10:51:53 -05:00
drigato
cc9e6efbca
SAAS-596: Store file size and hash in database
...
Removed try/except while getting file size and hash
2015-02-19 10:38:30 -05:00
Albert Santoni
d0bd4bfe81
Merge branch 'saas' into saas-store-file-size-and-hash-in-db
...
Conflicts:
airtime_mvc/application/modules/rest/controllers/MediaController.php
2015-02-18 19:29:45 -05:00
drigato
5bd3371ec2
SAAS-596: Store file size and hash in database
...
Removed getFileSize from CloudFile.php since it can call the parent
function.
Moved setting filesize metadata from cloud_storage_uploader.
2015-02-17 16:51:25 -05:00
drigato
c1086842d3
Merge branch 'cc-5709-airtime-analyzer-store-file-size-and-hash-in-db' into saas-store-file-size-and-hash-in-db
...
Conflicts:
airtime_mvc/application/Bootstrap.php
airtime_mvc/application/modules/rest/controllers/MediaController.php
2015-02-17 16:19:58 -05:00
drigato
66a6a8f985
SAAS-596: Store file size and hash in database
...
Added file size and hash to the metadata dict in the analyzer
2015-02-17 16:02:49 -05:00
Albert Santoni
d8f5e41fca
Set a connection timeout for Boto to prevent cloud storage deadlock
2015-02-17 14:58:19 -05:00