mirror of
https://github.com/krateng/maloja.git
synced 2023-08-10 21:12:55 +03:00
Listenbrainz protocol should now properly work with batch scrobbles from Pano
This commit is contained in:
parent
bdfb2a4a0b
commit
cb7a6d2241
@ -5,7 +5,7 @@ author = {
|
||||
"email":"maloja@krateng.dev",
|
||||
"github": "krateng"
|
||||
}
|
||||
version = 2,6,8
|
||||
version = 2,6,9
|
||||
versionstr = ".".join(str(n) for n in version)
|
||||
links = {
|
||||
"pypi":"malojaserver",
|
||||
|
@ -191,7 +191,7 @@ class LBrnz1(APIHandler):
|
||||
raise InvalidAuthException()
|
||||
|
||||
try:
|
||||
log("scrobbling to listenbrainz, keys "+str(keys),module="debug")
|
||||
#log("scrobbling to listenbrainz, keys "+str(keys),module="debug")
|
||||
if keys["listen_type"] in ["single","import"]:
|
||||
payload = keys["payload"]
|
||||
for listen in payload:
|
||||
@ -204,9 +204,9 @@ class LBrnz1(APIHandler):
|
||||
timestamp = int(datetime.datetime.now(tz=datetime.timezone.utc).timestamp())
|
||||
#database.createScrobble(artists,title,timestamp)
|
||||
scrobbletrack(artiststr,titlestr,timestamp)
|
||||
return 200,{"code":200,"status":"ok"}
|
||||
return 200,{"status":"ok"}
|
||||
else:
|
||||
return 200,{"code":200,"status":"ok"}
|
||||
return 200,{"status":"ok"}
|
||||
except:
|
||||
raise MalformedJSONException()
|
||||
|
||||
|
@ -47,7 +47,7 @@ import urllib
|
||||
#settings.update("settings/default.ini","settings/settings.ini")
|
||||
MAIN_PORT = settings.get_settings("WEB_PORT")
|
||||
HOST = settings.get_settings("HOST")
|
||||
THREADS = 12
|
||||
THREADS = 24
|
||||
BaseRequest.MEMFILE_MAX = 15 * 1024 * 1024
|
||||
|
||||
WEBFOLDER = pkg_resources.resource_filename(__name__,"web")
|
||||
|
Loading…
Reference in New Issue
Block a user