Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Argument 1 does not allow None as a value error when right clicking on a podcast. #1394

Closed
colinsauze opened this issue Sep 9, 2022 · 8 comments
Labels

Comments

@colinsauze
Copy link

Today gpodder suddenly stopped letting me right click on a podcast to delete, sync etc. I'm sometimes getting a popup error saying "Argument 1 does not allow None as a value" and when I launch it from the command line I see the following:

1662743231.133927 [gpodder.gtkui.main] ERROR: Exception happened while updating download list.
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/gpodder/gtkui/main.py", line 1303, in update_downloads_list
self.play_or_download()
File "/usr/lib/python3/dist-packages/gpodder/gtkui/main.py", line 2298, in play_or_download
selection.count_selected_rows() > 0)
File "/usr/lib/python3/dist-packages/gpodder/gtkui/main.py", line 2115, in set_episode_actions
self.toolPause.set_sensitive(can_pause)
TypeError: Argument 1 does not allow None as a value

After getting the error once, the UI seems to lock up a bit and I can't see any further progress of a download that was happening and can't use the right click menu anymore.

I've tried running it under a newly created user and with a podcast I don't normally subscribe to and it is still happening. I'm running Ubuntu Linux 18.04 and gpodder 3.11.0 from the PPA.

One thing I'm finding really strange is that gpodder doesn't appear to have updated recently, so I don't see why this has just started happening now.

@auouymous
Copy link
Member

3.11.0 was released one month ago, did you update back then? Has your python been updated recently?

I'm not sure why it doesn't happen for me but I've found the problem.

def can_pause(self):
    return self.download_task and self.download_task.can_pause()

This always returns None when there is no task, and the callsite then checks False or None which always returns None.

I will get this and the other methods fixed later this weekend.

@auouymous auouymous added the bug label Sep 9, 2022
@colinsauze
Copy link
Author

colinsauze commented Sep 12, 2022

I've looked back through my apt logs and 3.11.0 only got installed last week. It is possible I hadn't restarted gpodder at the time and kept using 3.10 for a while and only saw issues when it restarted. My version of Python hasn't changed.

I've tested this on another computer running Ubuntu 18.04, it was initially running 3.10 from the main ubuntu package feed and that worked fine. I switched to 3.11.0 from the PPA and it broke in the same way.

@auouymous
Copy link
Member

Do you know what version of python you have?

@colinsauze
Copy link
Author

3.6.9

@auouymous
Copy link
Member

Okay, so it is a problem with older versions of python. Thank you for reporting this.

@elelay Do you know how to get 3.11.0 pulled from PPA or get this patch applied or require a newer version of python?

@elelay
Copy link
Member

elelay commented Sep 12, 2022

We could always tag a new release.
Else a patch can be added to https://github.com/gpodder/ppa-scripts/tree/master/debian_gpodder_stable and we release a 3.11.0-1 ppa still from gpodder 3.11.0.
Let me know what you prefer.
Best,

@auouymous
Copy link
Member

I need to figure out what is preventing dialogs from closing (mentioned in #1311 and has happened to me once) before pushing a new release and forcing users to kill gpodder when it happens. So patching would be best.

Regarding https://github.com/gpodder/ppa-scripts/blob/master/debian_gpodder_stable/patches/disable_update_check_on_startup_default.patch, could it install an empty /usr/share/gpodder/no-update-check file? That is new in 3.11.0 and will also disable the menu item.

elelay added a commit to gpodder/ppa-scripts that referenced this issue Sep 15, 2022
@elelay
Copy link
Member

elelay commented Sep 15, 2022

I've released gpodder 3.11.0+1 in the stable ppa.

The unstable ppa can only release from master so I can't do that because of the bug preventing dialogs from closing, can I?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants