michael-lazar / rtv

Browse Reddit from your terminal
MIT License
4.64k stars 274 forks source link

Update to python 3.7 breaks rtv TypeError: register() takes from 2 to 3 positional arguments but 4 were given #588

Closed sevaho closed 6 years ago

sevaho commented 6 years ago

I upgrade to python 3.7 on Arch and now rtv is broken.

Traceback (most recent call last):
  File "/usr/sbin/rtv", line 7, in <module>
    from rtv.__main__ import main
  File "/usr/lib/python3.7/site-packages/rtv/__main__.py", line 254, in <module>
    sys.exit(main())
  File "/usr/lib/python3.7/site-packages/rtv/__main__.py", line 168, in main
    patch_webbrowser()
  File "/usr/lib/python3.7/site-packages/rtv/objects.py", line 37, in patch_webbrowser
    webbrowser.register('surf', None, webbrowser.BackgroundBrowser('surf'))
  File "/usr/lib/python3.7/webbrowser.py", line 26, in register
    register_standard_browsers()
  File "/usr/lib/python3.7/webbrowser.py", line 567, in register_standard_browsers
    cmd = _synthesize(cmdline, -1)
  File "/usr/lib/python3.7/webbrowser.py", line 116, in _synthesize
    register(browser, None, controller, update_tryorder)
TypeError: register() takes from 2 to 3 positional arguments but 4 were given
Trebled commented 6 years ago

Not ideal but try running w/ sudo. ^_^

michael-lazar commented 6 years ago

Thanks for reporting the issue, this is a duplicate of https://github.com/michael-lazar/rtv/issues/584. I'll look into it ASAP because this is probably going to effect a large number of users.

michael-lazar commented 6 years ago

An issue was filed in python's bug tracker here: 31014. A pull request has been merged upstream, but I will see if I can apply a patch for RTV in the meantime.

https://github.com/python/cpython/pull/7267

michael-lazar commented 6 years ago

Patch has been applied, I'll publish a new release tomorrow which should be picked up on AUR fairly quickly.