Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
funkwhale
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Arthur Brugière
funkwhale
Commits
572efc79
Commit
572efc79
authored
3 years ago
by
Philipp Wolfer
Committed by
Georg Krause
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix the scrobbler plugin submitting literal "None" as MusicBrainz ID
Fixes #1498
parent
0ad17b4b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
api/funkwhale_api/contrib/scrobbler/scrobbler.py
+2
-2
2 additions, 2 deletions
api/funkwhale_api/contrib/scrobbler/scrobbler.py
changes/changelog.d/1498.bug
+1
-0
1 addition, 0 deletions
changes/changelog.d/1498.bug
with
3 additions
and
2 deletions
api/funkwhale_api/contrib/scrobbler/scrobbler.py
+
2
−
2
View file @
572efc79
...
...
@@ -90,7 +90,7 @@ def get_scrobble_payload(track, date, suffix="[0]"):
"
l{}
"
.
format
(
suffix
):
upload
.
duration
if
upload
else
0
,
"
b{}
"
.
format
(
suffix
):
(
track
.
album
.
title
if
track
.
album
else
""
)
or
""
,
"
n{}
"
.
format
(
suffix
):
track
.
position
or
""
,
"
m{}
"
.
format
(
suffix
):
str
(
track
.
mbid
)
or
""
,
"
m{}
"
.
format
(
suffix
):
str
(
track
.
mbid
or
""
)
,
"
o{}
"
.
format
(
suffix
):
"
P
"
,
# Source: P = chosen by user
}
if
date
:
...
...
@@ -115,7 +115,7 @@ def get_scrobble2_payload(track, date, suffix="[0]"):
if
track
.
position
:
data
[
"
trackNumber
"
]
=
track
.
position
if
track
.
mbid
:
data
[
"
mbid
"
]
=
str
(
track
.
mbid
)
data
[
"
mbid
"
]
=
str
(
track
.
mbid
or
""
)
if
date
:
offset
=
upload
.
duration
/
2
if
upload
.
duration
else
0
data
[
"
timestamp
"
]
=
int
(
int
(
date
.
timestamp
())
-
offset
)
...
...
This diff is collapsed.
Click to expand it.
changes/changelog.d/1498.bug
0 → 100644
+
1
−
0
View file @
572efc79
Fix the scrobbler plugin submitting literal "None" as MusicBrainz ID (#1498)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment