Skip to content

pwdsphinx 2.0.3 fails on Python 3.14 with "RuntimeError: There is no current event loop in thread 'MainThread'" #36

Description

@link2xt

I have set up sphinx on Arch Linux after packaging it at https://aur.archlinux.org/packages/pwdsphinx

I created the following config at ~/.config/sphinx/config:

[client]
verbose = false
datadir="~/.config/sphinx"
rwd_keys=false
validate_password=true
userlist=true
delete_upgraded=false
threshold = 2

[servers]
[servers.ctrlc1]
host="pwd.ctrlc.hu"
port=443
ltsigkey="QjMKdyG6XCdgonn0xrvzKEXLOej/sVAtgfDayZBYVP0="

[servers.ctrlc2]
host="pwd2.ctrlc.hu"
port=443
ltsigkey="sJs724fgJ8ax98gTI3IihtFmzkz8lls41+GcDMHCQpk="

[servers.dyne]
host="sphinx.dyne.org"
port=4443
ltsigkey="TnQHEiiJtFXqhUskqAxtIhG/xlk9t79BXyLcofai32g="

Servers are from https://sphinx.pm/servers.html

Then I tried to run it and it failed:

$ sphinx init
/usr/lib/python3.14/site-packages/pwdsphinx/websphinx.py
you want to make a backup of the following masterkey, keep it safe and secure b'K2ckhSA7my61fjJSib+bFqHt9oEwtToyyPFf9KSacgk=\n'
this key is also stored - and must be available - at: /home/user/.config/sphinx/masterkey
Traceback (most recent call last):
  File "/usr/bin/sphinx", line 8, in <module>
    sys.exit(main())
             ~~~~^^
  File "/usr/lib/python3.14/site-packages/pwdsphinx/sphinx.py", line 1107, in main
    sys.exit(init())
             ~~~~^^
  File "/usr/lib/python3.14/site-packages/pwdsphinx/sphinx.py", line 539, in init
    create(m, b"all ok?", "healthcheck", "sphinx servers", target="everything works fine")
    ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.14/site-packages/pwdsphinx/sphinx.py", line 547, in create
    beta = dkg(m, CREATE_DKG, threshold, ids, alpha)
  File "/usr/lib/python3.14/site-packages/pwdsphinx/sphinx.py", line 475, in dkg
    peer_msgs = m.gather(sizes[0],n) #,debug=True)
  File "/usr/lib/python3.14/site-packages/pyoprf/multiplexer.py", line 439, in gather
    return asyncio.get_event_loop().run_until_complete(self.gather_async(*args, **kwargs))
           ~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/asyncio/events.py", line 715, in get_event_loop
    raise RuntimeError('There is no current event loop in thread %r.'
                       % threading.current_thread().name)
RuntimeError: There is no current event loop in thread 'MainThread'.

(I know that it printed masterkey, I am only testing it and will change it once it works)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions