Torrent management system based on Django and Transmission
karamanolev / whatmanager2 Goto Github PK
View Code? Open in Web Editor NEWTorrent management system based on Django and Transmission
License: MIT License
Torrent management system based on Django and Transmission
License: MIT License
On Debian 8 I needed to manually install libjpeg8-dev
to get the ./setup.sh to work successfully.
A torrent that I added to be transcoded took a long time to download, very few and slow seeders. In between the time that it was added and completed it was removed on the site. On the transcode page it showed as torrent removed. Items that I added after it completed downloading but never began the transcode/upload process. After troubleshooting why my transcodes weren't going I deleted the removed torrent from the DB and immediately the other queue items began to be transcoded.
When I edit the settings.json in my TRANSMISSION_FILES_ROOT and restart the daemon the settings file just gets overwritten by the default file.
Is there any way I can maybe just edit the default settings.json that gets recopied there?
Hello,
i test to install the WhatManager2.
But when i start : ./manage.py migrate
i have this error :
root@debian:/mnt/tank/lamp/django/WhatManager2# ./manage.py migrate
Traceback (most recent call last):
File "./manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 346, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 394, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 444, in execute
self.check()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 482, in check
include_deployment_checks=include_deployment_checks,
File "/usr/local/lib/python2.7/dist-packages/django/core/checks/registry.py", line 72, in run_checks
new_errors = check(app_configs=app_configs)
File "/usr/local/lib/python2.7/dist-packages/django/core/checks/model_checks.py", line 28, in check_all_models
errors.extend(model.check(**kwargs))
File "/usr/local/lib/python2.7/dist-packages/django/db/models/base.py", line 1205, in check
errors.extend(cls._check_fields(**kwargs))
File "/usr/local/lib/python2.7/dist-packages/django/db/models/base.py", line 1282, in _check_fields
errors.extend(field.check(**kwargs))
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/init.py", line 934, in check
errors = super(AutoField, self).check(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/init.py", line 207, in check
errors.extend(self._check_backend_specific_checks(**kwargs))
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/init.py", line 306, in _check_backend_specific_checks
return connection.validation.check_field(self, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/validation.py", line 18, in check_field
field_type = field.db_type(connection)
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/init.py", line 614, in db_type
return connection.data_types[self.get_internal_type()] % data
File "/usr/local/lib/python2.7/dist-packages/django/db/init.py", line 36, in getattr
return getattr(connections[DEFAULT_DB_ALIAS], item)
File "/usr/local/lib/python2.7/dist-packages/django/utils/functional.py", line 59, in get
res = instance.dict[self.name] = self.func(instance)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 196, in data_types
if self.features.supports_microsecond_precision:
File "/usr/local/lib/python2.7/dist-packages/django/utils/functional.py", line 59, in get
res = instance.dict[self.name] = self.func(instance)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/features.py", line 52, in supports_microsecond_precision
return self.connection.mysql_version >= (5, 6, 4) and Database.version_info >= (1, 2, 5)
File "/usr/local/lib/python2.7/dist-packages/django/utils/functional.py", line 59, in get
res = instance.dict[self.name] = self.func(instance)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 371, in mysql_version
with self.temporary_connection():
File "/usr/lib/python2.7/contextlib.py", line 17, in enter
return self.gen.next()
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 462, in temporary_connection
cursor = self.cursor()
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 162, in cursor
cursor = self.make_debug_cursor(self._cursor())
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 135, in _cursor
self.ensure_connection()
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 130, in ensure_connection
self.connect()
File "/usr/local/lib/python2.7/dist-packages/django/db/utils.py", line 98, in exit
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 130, in ensure_connection
self.connect()
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/base.py", line 119, in connect
self.connection = self.get_new_connection(conn_params)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 276, in get_new_connection
conn = Database.connect(**conn_params)
File "/usr/local/lib/python2.7/dist-packages/MySQLdb/init.py", line 81, in Connect
return Connection(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/MySQLdb/connections.py", line 193, in init
super(Connection, self).init(*args, **kwargs2)
django.db.utils.OperationalError: (1045, "Access denied for user 'root'@'localhost' (using password: NO)")
Can you help me ?
When multiple transcodes start at the same time, the random int method is returning the same value for multiple directories when concurrency is set higher than 1 in the celery script. Currently it fails because it detects the folder already exists from another worker and halts transcoding. Would adding the current milliseconds to the string help? Something like
return TRANSCODER_TEMP_DIR + '_' + str(round(time.time() * 1000)) + '_' + str(random.randint(10000000, 99999999))
folder examples it creates are:
whatup.celery.9758_1.50315276795e+12_88760908
and
whatup.celery.9758_1.50315276602e+12_88760908
Any plan on updating WM for XX and PTH?
It looks like the method that checks to see if the filenames and track number tags sort in the same direction fails if the track numbers in the filename are not 0-padded. According to redacted staff this is not grounds for trumping a torrent though.
Getting the below error when trying to run ./manage.py migrate
ripley@whatmanager:/opt/wm/WhatManager2$ ./manage.py migrate
Traceback (most recent call last):
File "./manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 328, in execute
django.setup()
File "/usr/local/lib/python2.7/dist-packages/django/init.py", line 18, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python2.7/dist-packages/django/apps/registry.py", line 108, in populate
app_config.import_models(all_models)
File "/usr/local/lib/python2.7/dist-packages/django/apps/config.py", line 198, in import_models
self.models_module = import_module(models_module_name)
File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module
import(name)
File "/opt/wm/WhatManager2/qobuz2/models.py", line 15, in
from qobuz2 import settings
ImportError: cannot import name settings
failed - ConnectionError(('Connection aborted.', error(111, 'Connection refused')))
I'm running nginx with a valid ssl certificate and auth_basic off;
I don't even see the add_torrent url being accessed called in the uwsgi logs though I made sure it's correct
Hello,
I am on a managed dedicated server, and just about everything seems to be set up correctly with WM2.
When I try to run celery.sh, I encounter this error:
Cannot connect to amqp://guest:**@localhost:5672//: Error opening socket: a socket error occurred.
This is the broker setting in settings.py:
BROKER_URL = 'amqp://guest:guest@localhost:5672/'
I made changes to this to be python 3 compatible. Rip What.cd, but maybe this can be then extended to work on more sites?
Make_Python_3_compatible.zip
Use the password in settings.py instead of copying the password from an old instance when creating a new one.
The wiki instructions say I don't need to copy anonymouse bibliotik etc settings files unless I am using them, but the manage.py fails unless they are
File "./manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 385, in execute_from_command_line
utility.execute()
File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 354, in execute
django.setup()
File "/usr/lib/python2.7/dist-packages/django/__init__.py", line 21, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/lib/python2.7/dist-packages/django/apps/registry.py", line 108, in populate
app_config.import_models(all_models)
File "/usr/lib/python2.7/dist-packages/django/apps/config.py", line 202, in import_models
self.models_module = import_module(models_module_name)
File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
__import__(name)
File "/home/mlapaglia/WhatManager2/qobuz2/models.py", line 15, in <module>
from qobuz2 import settings```
When trying to import a torrent containing example.epub (without any directory), it checks for
/base-dir/example.epub/example.epub
instead of
/base-dir/example.epub
Creating a directory named "example.epub" and copying example.epub in it solves the problem, but it would be a good thing to correct this if possible.
Trying to download a single file torrent you just get an empty zip folder.
I am going to look through the code myself to see if I can work it out, but from what I understand there's a decent tool in here that almost nobody has used because they don't know how.
@karamanolev you wrote this, I think?
I know you're busy and a detailed wiki might not be possible but I for one would greatly appreciate even just a couple of pointers to get started using this. So far I don't even know whether it's designed to be run on my old WCD instance of WM2 and pointed at the new RED install, or vice versa.
I get the following from time to time on albums, especially if they are international artists with accents on letters.
I've tried messing with the tasks.py script, but don't really have a solid fix on how to fix it.
[2016-02-15 21:01:28,710: WARNING/Worker-1] Will transcode 32743498
[2016-02-15 21:01:29,785: WARNING/Worker-1] Progress: Started transcoding to V2
[2016-02-15 21:01:29,787: WARNING/Worker-1] Progress: Checking tags and filenames
[2016-02-15 21:01:29,789: WARNING/Worker-1] Check tags in
[2016-02-15 21:01:29,789: WARNING/Worker-1] /mnt/nfs/32743498/Artist-Name-CD-FLAC-2015
2016-02-15 21:01:29,927: ERROR/MainProcess] Task what_transcode.tasks.transcode[db831d07-0b94-4c34-a398-9e1c893ebf8c] raised unexpected: UnicodeDecodeError('ascii', '/01 Chez la m\xc3\xa8re.flac', 13, 14, 'ordinal not in range(128)')
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/celery/app/trace.py", line 240, in trace_task
R = retval = fun(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/celery/app/trace.py", line 438, in __protected_call__
return self.run(*args, **kwargs)
File "/home/karson/WhatManager2/what_transcode/tasks.py", line 378, in transcode
File "/home/karson/WhatManager2/what_transcode/tasks.py", line 336, in run
finally:
File "/home/karson/WhatManager2/what_transcode/tasks.py", line 371, in transcode_upload_lossless
print 'Uploaded {0}'.format(bitrate.upper())
File "/home/karson/WhatManager2/what_transcode/tasks.py", line 100, in run
File "/home/karson/WhatManager2/what_transcode/tasks.py", line 255, in transcode_torrent
File "/home/karson/WhatManager2/what_transcode/utils.py", line 150, in check_directory_tags_filenames
child_path = os.path.join(dir_path, child)
File "/usr/lib/python2.7/posixpath.py", line 80, in join
path += '/' + b
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 13: ordinal not in range(128)
Torrents views are now looking for such an instance and can't find it.
Once 24bit transcoding is supported, add functionality for the app to detect mutt rips (16 bit and 24 bit files in the same release) and auto report them on the site, then transcode all of the 24bit files to 16bit but leave the 16bit files alone for a new 16bit release.
It appears I'm unable to launch Transmission instances. Below is the output of running sudo ./manage.py transmission_new passtheheadphones.me
It also appears to be starting peer_port at 21413 instead of 51413 which differs from what the wiki states.
ripley@whatmanager:/opt/wm/WhatManager2$ sudo ./manage.py transmission_new passtheheadphones.me
System check identified some issues:
WARNINGS:
what_meta.WhatMetaFulltext.artist: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
what_meta.WhatMetaFulltext.artist_alias: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
what_meta.WhatMetaFulltext.torrent_group: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
TransInstance passtheheadphones02(replica_set=ReplicaSet(passtheheadphones.me, master), host=127.0.0.1, rpc_port=9091, peer_port=21413, username=transmission, password=***************)
Is this OK?
Enter y to continue: y
Creating init script for passtheheadphones01
Enter y to continue: y
Creating user transmission-passtheheadphones01 for passtheheadphones01
Enter y to continue: y
Creating transmission settings file for passtheheadphones01
Enter y to continue: y
Starting daemon...
Failed to start transmission-daemon-passtheheadphones01.service: Unit transmission-daemon-passtheheadphones01.service not found.
Warning! Service start returned non-zero. args=['service', 'transmission-daemon-passtheheadphones01', 'start']
Instance synced and saved.
They should provide more meaningful feedback.
If you remove a settings file an use the provision command, it will generate new files with an incorrect port number, whitelist enabled, and authentication disabled. These are not the default settings applied when transmission_new is called.
WhatManager doesn't have a build-in rate limiter. This is problematic when you're using other scripts to batch add torrents to the transcode/download queue.
I have an 8 core server, sitting waiting for each file to transcode one at a time takes 8 times longer than it could if all cores were being used.
This should be fixed immediately
When I upgraded to stretch, the transmission instance used by WhatManager keeps using up more RAM until it is all used. The transmission instance I have running that is not associated with WhatManager does not behave like this.
Clean installation using MariaDB.
root@bender /v/d/whatmanager# ./manage.py migrate
System check identified some issues:
WARNINGS:
what_meta.WhatMetaFulltext.artist: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
what_meta.WhatMetaFulltext.artist_alias: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
what_meta.WhatMetaFulltext.torrent_group: (fields.W342) Setting unique=True on a ForeignKey has the same effect as using a OneToOneField.
HINT: ForeignKey(unique=True) is usually better served by a OneToOneField.
Operations to perform:
Synchronize unmigrated apps: staticfiles, qobuz2, messages, bibliotik_json, WhatManager2, download, login, bootstrapform, what_json
Apply all migrations: what_profile, myanonamouse, sessions, admin, what_meta, djcelery, sites, auth, queue, what_transcode, contenttypes, books, bibliotik, home
Synchronizing apps without migrations:
Creating tables...
Creating table qobuz2_qobuzupload
Creating table qobuz2_logindatacache
Running deferred SQL...
Installing custom SQL...
Running migrations:
Rendering model states... DONE
Applying contenttypes.0001_initial... OK
Applying auth.0001_initial... OK
Applying admin.0001_initial... OK
Applying contenttypes.0002_remove_content_type_name... OK
Applying auth.0002_alter_permission_name_max_length... OK
Applying auth.0003_alter_user_email_max_length... OK
Applying auth.0004_alter_user_username_opts... OK
Applying auth.0005_alter_user_last_login_null... OK
Applying auth.0006_require_contenttypes_0002... OK
Applying home.0001_initial... OK
Applying bibliotik.0001_initial... OK
Applying bibliotik.0002_bibliotiktorrentpagecache... OK
Applying books.0001_initial... OK
Applying djcelery.0001_initial...Traceback (most recent call last):
File "./manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 346, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 394, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 445, in execute
output = self.handle(*args, **options)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/commands/migrate.py", line 222, in handle
executor.migrate(targets, plan, fake=fake, fake_initial=fake_initial)
File "/usr/local/lib/python2.7/dist-packages/django/db/migrations/executor.py", line 110, in migrate
self.apply_migration(states[migration], migration, fake=fake, fake_initial=fake_initial)
File "/usr/local/lib/python2.7/dist-packages/django/db/migrations/executor.py", line 148, in apply_migration
state = migration.apply(state, schema_editor)
File "/usr/local/lib/python2.7/dist-packages/django/db/migrations/migration.py", line 115, in apply
operation.database_forwards(self.app_label, schema_editor, old_state, project_state)
File "/usr/local/lib/python2.7/dist-packages/django/db/migrations/operations/models.py", line 59, in database_forwards
schema_editor.create_model(model)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/schema.py", line 286, in create_model
self.execute(sql, params or None)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/base/schema.py", line 111, in execute
cursor.execute(sql, params)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/utils.py", line 79, in execute
return super(CursorDebugWrapper, self).execute(sql, params)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/local/lib/python2.7/dist-packages/django/db/utils.py", line 98, in __exit__
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/utils.py", line 62, in execute
return self.cursor.execute(sql)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 124, in execute
return self.cursor.execute(query, args)
File "/usr/local/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 205, in execute
self.errorhandler(self, exc, value)
File "/usr/local/lib/python2.7/dist-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
django.db.utils.OperationalError: (1071, 'Specified key was too long; max key length is 767 bytes')
Unable to add what.cd toolbox for mac and also other apps.
Failure message:
Tried adding what_id=31024737. Error: 'NoneType' object has no attribute '__getitem__'
Traceback from logs:
Traceback (most recent call last):
File "./what_json/views.py", line 182, in add_torrent
m_torrent = manage_torrent.add_torrent(request, instance, download_location, what_id, True)
File "./WhatManager2/manage_torrent.py", line 12, in add_torrent
w_torrent = WhatTorrent.get_or_create(request, what_id=what_id)
File "./home/models.py", line 364, in get_or_create
w_torrent.save()
File "./home/models.py", line 270, in save
self.info_loads['group']['id'], self.retrieved, self.info_loads['group'])
File "./what_meta/models.py", line 178, in update_if_newer
group.joined_artists = get_artists(data_dict)
File "./WhatManager2/utils.py", line 197, in get_artists
artists_list = get_artists_list(group)
File "./WhatManager2/utils.py", line 146, in get_artists_list
a_main = group['musicInfo']['artists']
TypeError: 'NoneType' object has no attribute '__getitem__'
i want to use the bibliotik functionality. i am already using WM2 for RED without issue.
is there a known issue with the bibliotik.me userscript?
when i click on "get" in firefox, it shows a dialog to confirm download, and then shows and errors message Make sure the extension is installed and working
and nothing more happens
I have setup a download zone in the admin panel called bibliotik.me
and started a transmission instance called bibliotik01
when I look through the userscript, there are urls that do not seem to work on my wm2 server. like /books/bibliotik/json/torrents_info
returns a 500 error and then /books/bibliotik/json/add/
and /download/zip/bibliotik/
return 404
in the red userscript for example it uses /json/add_torrent
and that returns a blank page when visited...
Out of curiosity, I tried the Book Upload
function in the WM2 interface and it takes me to /books/uploads/1/edit
with a 500 error.
Hello,
I'm trying to setup WhatManager in a fresh Ubuntu Server VM.
root@what:~/WhatManager# pwd
/root/WhatManager
I copied settings.example.py
to settings.py
and edited the values. Here's how my directory looks right now
root@what:~/WhatManager# ls WhatManager2
checks.py __init__.pyc manage_torrent.py settings.py tests.py utils.py wsgi.py
context_processors.py locking.py middleware.py settings.pyc trans_sync.py utils.pyc
__init__.py management settings.example.py templatetags urls.py whatimg.py
Now if I want to run the migrate script it's not able to import the setting file.
root@what:~/WhatManager# ./manage.py migrate
Traceback (most recent call last):
File "./manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 385, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 354, in execute
django.setup()
File "/usr/local/lib/python2.7/dist-packages/django/__init__.py", line 21, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python2.7/dist-packages/django/apps/registry.py", line 108, in populate
app_config.import_models(all_models)
File "/usr/local/lib/python2.7/dist-packages/django/apps/config.py", line 197, in import_models
self.models_module = import_module(models_module_name)
File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
__import__(name)
File "/root/WhatManager/bibliotik/models.py", line 10, in <module>
from bibliotik.settings import BIBLIOTIK_GET_TORRENT_URL
ImportError: No module named settings
Any idea what's wrong there?
Hello,
I just added a new Transmission instance (after failing at the first try, transmission-daemon wasn't installed - Already added that to the setup instructions in the wiki) and I'm seeing these messages now.
Any idea what's going on there?
Type User Date Message
error root 2014-10-03 21:36:01 Error syncing master DB: TransmissionError(Request failed. Original exception: HTTPHandlerError, "HTTPHandlerError 401: basic auth failed")
error root 2014-10-03 21:34:02 Error syncing master DB: TransmissionError(Request failed. Original exception: HTTPHandlerError, "HTTPHandlerError 401: basic auth failed")
error root 2014-10-03 21:32:01 Error syncing master DB: TransmissionError(Request failed. Original exception: HTTPHandlerError, "HTTPHandlerError 401: basic auth failed")
error root 2014-10-03 21:30:09 Tried adding what_id=31689188. Error: Request failed. Original exception: HTTPHandlerError, "HTTPHandlerError 401: basic auth failed"
It seems I can't install any of the userscripts apart from Overdrive search, I get a 404 error for http://localhost/userscript/localhost/static/js/jquery.noty.packaged.min.js
I've followed the installation guide up to step 12, and I get the error
Traceback (most recent call last): File "manage.py", line 10, in <module> execute_from_command_line(sys.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 354, in execute_from_command_line utility.execute() File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 346, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 394, in run_from_argv self.execute(*args, **cmd_options) File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 445, in execute output = self.handle(*args, **options) File "/mnt/tank/lamp/django/WhatManager2/WhatManager2/management/commands/transmission_new.py", line 26, in handle replica_set = models.ReplicaSet.objects.get(zone=zone) File "/usr/local/lib/python2.7/dist-packages/django/db/models/manager.py", line 127, in manager_method return getattr(self.get_queryset(), name)(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/django/db/models/query.py", line 334, in get self.model._meta.object_name home.models.DoesNotExist: ReplicaSet matching query does not exist.
I get the same error both with and without adding the DownloadLocation.
Sorry if I'm just missing a step.
Thanks.
Flac downsampling would be extreemly usefull for the transcoder.
Missing settings.py for bibliotik makes the travis CI builds fail.
Currently PTH authentication is done incorrectly meaning that the server will get banned after multiple requests.
Was running the import script with a 3 second delay and over time it encounters this. The only way to fix it, in my experience, has been to restart the transmission workers.
Processing /home/share/Dropbox/incoming/sagan.impi.us/torrents/what.cd/Archive/War - All Day Music - 1992 (CD - MP3 - V0 (VBR)).torrent
Checking for existing files...
Checking /storage/drive4/public/music/what.cd/Archive/All day music/01- All Day Music.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/02- Get Down.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/03- That's What Love Will Do.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/04- There Must Be A Reason.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/05- Nappy Head (Theme from Ghetto Man).mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/06- Slippin' Into Darkness.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/07- Baby Brother.mp3
Checking /storage/drive4/public/music/what.cd/Archive/All day music/War - All day music.log
Creating destination directory...
All torrent data files exist.
Moving files to new directory...
Adding torrent to WM...
No handlers could be found for logger "transmissionrpc"
Traceback (most recent call last):
File "/var/www/wm/manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 385, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 377, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 288, in run_from_argv
self.execute(_args, *_options.dict)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 338, in execute
output = self.handle(_args, *_options)
File "/var/www/wm/WhatManager2/management/commands/import_external_what_torrent.py", line 127, in handle
self.download_location, self.what_torrent.id)
File "/var/www/wm/WhatManager2/manage_torrent.py", line 39, in add_torrent
t_torrent = instance.client.add_torrent(
File "/var/www/wm/home/models.py", line 150, in client
user=self.username, password=self.password)
File "/usr/local/lib/python2.7/dist-packages/transmissionrpc/client.py", line 169, in init
self.get_session()
File "/usr/local/lib/python2.7/dist-packages/transmissionrpc/client.py", line 828, in get_session
self._request('session-get', timeout=timeout)
File "/usr/local/lib/python2.7/dist-packages/transmissionrpc/client.py", line 252, in _request
data = json.loads(http_data)
File "/usr/lib/python2.7/json/init.py", line 326, in loads
return _default_decoder.decode(s)
File "/usr/lib/python2.7/json/decoder.py", line 365, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python2.7/json/decoder.py", line 381, in raw_decode
obj, end = self.scan_once(s, idx)
ValueError: Expecting ',' delimiter: line 1 column 1553 (char 1553)
Hey!
I've notice that the new transmission instance script creates upstart and not systemd scripts. Ubuntu, Debian, CentOS and many other distros have migrated to systemd, so I think it might be worth adding support to systemd.
I have tried the following with my instances (and it works):
For each instance, create a file like /etc/systemd/system/transmission-passtheheadphones01.service with the following content:
[Unit]
Description=PTH Transmission Daemon 1
After=syslog.target network.target
[Service]
Type=simple
User=transmission-passtheheadphones01
StandardError=syslog
ExecStart=/usr/local/bin/transmission-daemon -f -g /opt/wm2/data/transmission/passtheheadphones01
Restart = always
RestartSec = 240
[Install]
WantedBy=multi-user.target
Then:
I hope this is enough info for you guys to update the script if you wish to.
Thanks a lot!
'ascii' codec can't encode character u'\xe9' in position 151: ordinal not in range(128)
The string that could not be encoded/decoded was: Andrés .mp
If a torrent added to the transcode queue is deleted from the site, the transcode fails correctly because the torrent doesn't exist anymore, but the /update method fails to work after until the entry is removed from the table in the database.
Hello,
after resolving #16 the migrate script worked but it never asked me to setup admin credentials like mentioned in the wiki.
root@what:~/WhatManager/bibliotik# cp settings.example.py settings.py
root@what:~/WhatManager/bibliotik# cd ..
root@what:~/WhatManager# ./manage.py migrate
Operations to perform:
Synchronize unmigrated apps: djcelery, what_json, download, login, bootstrapform, bibliotik_json
Apply all migrations: what_profile, sessions, admin, what_meta, sites, auth, queue, what_transcode, contenttypes, books, bibliotik, home
Synchronizing apps without migrations:
Creating tables...
Creating table celery_taskmeta
Creating table celery_tasksetmeta
Creating table djcelery_intervalschedule
Creating table djcelery_crontabschedule
Creating table djcelery_periodictasks
Creating table djcelery_periodictask
Creating table djcelery_workerstate
Creating table djcelery_taskstate
Installing custom SQL...
Installing indexes...
Running migrations:
Applying contenttypes.0001_initial... OK
Applying auth.0001_initial... OK
Applying admin.0001_initial... OK
Applying home.0001_initial... OK
Applying bibliotik.0001_initial... OK
Applying books.0001_initial... OK
Applying what_meta.0001_initial... OK
Applying home.0002_add_torrent_group_fk... OK
Applying home.0003_file_metadata_cache_and_indexes... OK
Applying queue.0001_initial... OK
Applying sessions.0001_initial... OK
Applying sites.0001_initial... OK
Applying what_meta.0002_whatmetafulltext... OK
Applying what_meta.0003_add_artist_aliases... OK
Applying what_profile.0001_initial... OK
Applying what_profile.0002_add_datetime_index... OK
Applying what_transcode.0001_initial... OK
root@what:~/WhatManager#
Any reason why it would skip that step? Now I don't know how to login to /admin.
Thanks!
Whatify doesnt have any nice favicon or even title in the http header :(
Update the wiki with whatify information. Including the management commands one need to run and also the ones one should put in a crontab.
Would it be possible to create a quick IPFS script to add our What.CD content? I'm thinking, if we have the hashes and metadata, we could at least create some sort of index and get some of the network/content back online.
Since IPFS storage is hash based, we should be able to tell one from another. Now we just need to have some sort of index that maps to artist/album/release/etc.
Anyone up for looking into this with me?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.