Jump to content


Photo

NetworkBrowser py3 crash


  • Please log in to reply
4 replies to this topic

#1 Amai

  • Senior Member
  • 615 posts

+26
Good

Posted 26 November 2022 - 14:24

NetworkBrowser Python 3

https://github.com/O.../networkbrowser

 

crash when username and password entered

  File "/usr/lib/enigma2/python/Plugins/SystemPlugins/NetworkBrowser/UserDialog.py", line 137, in ok
    write_cache(self.cache_file, hostdata)
  File "/usr/lib/enigma2/python/Plugins/SystemPlugins/NetworkBrowser/UserDialog.py", line 26, in write_cache
    pickle.dump(cache_data, fd, -1)
TypeError: write() argument must be str, not bytes
[ePyObject] (CallObject(<bound method NumberActionMap.action of <Components.ActionMap.NumberActionMap object at 0xad941990>>,('SetupActions', 'ok')) failed)

UserDialog.py, is it sufficient to change for this line 'w' to 'wb' or more changes needed?

with open(cache_file, 'w') as fd:


Edited by Amai, 26 November 2022 - 14:31.


Re: NetworkBrowser py3 crash #2 Amai

  • Senior Member
  • 615 posts

+26
Good

Posted 26 November 2022 - 15:46

Info: it happens on mounts
- username and password
- browsing the network, finding NAS and choosing that IP-address
- after pressing OK green screen
ADD Peer et10000=et10000.local:8001
ADD Peer vuduo=vuduo.local:8001
Traceback (most recent call last):
  File "/usr/lib/enigma2/python/Components/ActionMap.py", line 77, in action
    return ActionMap.action(self, contexts, action)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/enigma2/python/Components/ActionMap.py", line 57, in action
    res = self.actions[action]()
          ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/enigma2/python/Plugins/SystemPlugins/NetworkBrowser/UserDialog.py", line 137, in ok
    write_cache(self.cache_file, hostdata)
  File "/usr/lib/enigma2/python/Plugins/SystemPlugins/NetworkBrowser/UserDialog.py", line 26, in write_cache
    pickle.dump(cache_data, fd, -1)
TypeError: write() argument must be str, not bytes
[ePyObject] (CallObject(<bound method NumberActionMap.action of <Components.ActionMap.NumberActionMap object at 0xad265cf0>>,('SetupActions', 'ok')) failed)

Thanks


Edited by Amai, 26 November 2022 - 15:52.


Re: NetworkBrowser py3 crash #3 WanWizard

  • PLi® Core member
  • 68,544 posts

+1,737
Excellent

Posted 26 November 2022 - 16:36

I can reproduce it.


Currently in use: VU+ Duo 4K (2xFBC S2), VU+ Solo 4K (1xFBC S2), uClan Usytm 4K Pro (S2+T2), Octagon SF8008 (S2+T2), Zgemma H9.2H (S2+T2)

Due to my bad health, I will not be very active at times and may be slow to respond. I will not read the forum or PM on a regular basis.

Many answers to your question can be found in our new and improved wiki.


Re: NetworkBrowser py3 crash #4 WanWizard

  • PLi® Core member
  • 68,544 posts

+1,737
Excellent

Posted 26 November 2022 - 16:57

Fix: https://github.com/O...147dc7660c433eb


Currently in use: VU+ Duo 4K (2xFBC S2), VU+ Solo 4K (1xFBC S2), uClan Usytm 4K Pro (S2+T2), Octagon SF8008 (S2+T2), Zgemma H9.2H (S2+T2)

Due to my bad health, I will not be very active at times and may be slow to respond. I will not read the forum or PM on a regular basis.

Many answers to your question can be found in our new and improved wiki.


Re: NetworkBrowser py3 crash #5 Amai

  • Senior Member
  • 615 posts

+26
Good

Posted 26 November 2022 - 17:11

Thank You




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users