[tasks] Fix bug in syncing orgmode tasks without notes
All checks were successful
build / test (push) Successful in 1m50s

This commit is contained in:
2026-06-01 11:02:56 -04:00
parent 039c58cf89
commit daabd2f37f
2 changed files with 16 additions and 3 deletions

View File

@ -93,7 +93,7 @@ fetching and simple saving.
:LOGBOOK: :LOGBOOK:
CLOCK: [2025-07-09 Wed 09:55]--[2025-07-09 Wed 10:15] => 0:20 CLOCK: [2025-07-09 Wed 09:55]--[2025-07-09 Wed 10:15] => 0:20
:END: :END:
* Backlog [1/14] :vrobbler:project:personal: * Backlog [2/15] :vrobbler:project:personal:
** TODO [#C] Add sentiment parsing for Scrobbles with notes :vrobbler:project:scrobbles:sentiment: ** TODO [#C] Add sentiment parsing for Scrobbles with notes :vrobbler:project:scrobbles:sentiment:
:PROPERTIES: :PROPERTIES:
:ID: 37781d6a-f3b0-48b2-bf98-33c2c791cf85 :ID: 37781d6a-f3b0-48b2-bf98-33c2c791cf85
@ -489,6 +489,19 @@ whatever time KoReader reports, we need to know, given the date and the user
profile's historic timezone, how many hours to adjust the KoReader time to get profile's historic timezone, how many hours to adjust the KoReader time to get
to GMT to save it in the database. to GMT to save it in the database.
** DONE [#A] Fix error in org-mode task sync :emacs:orgmode:tasks:bug:
:PROPERTIES:
:ID: 03256d2a-48aa-4be7-aeb3-fa1cfddc86bf
:END:
*** Description
#+begin_src python
File "/usr/local/lib/python3.11/site-packages/vrobbler/apps/tasks/webhooks.py", line 236, in post
emacs_scrobble_update_task(
File "/usr/local/lib/python3.11/site-packages/vrobbler/apps/scrobbles/scrobblers.py", line 844, in emacs_scrobble_update_task
for note in emacs_notes:
TypeError: 'NoneType' object is not iterable
#+end_src
** DONE [#B] Adjust how similar artists are shown :feature:templates:artists:music: ** DONE [#B] Adjust how similar artists are shown :feature:templates:artists:music:
:PROPERTIES: :PROPERTIES:
:ID: 2a081620-a0a2-4851-a7cf-4043f9c2ee31 :ID: 2a081620-a0a2-4851-a7cf-4043f9c2ee31

View File

@ -235,7 +235,7 @@ class EmacsWebhookView(APIView):
if task_in_progress: if task_in_progress:
emacs_scrobble_update_task( emacs_scrobble_update_task(
post_data.get("source_id"), post_data.get("source_id"),
post_data.get("notes", []), post_data.get("notes") or [],
user_id, user_id,
description=post_data.get("body"), description=post_data.get("body"),
) )