-
Notifications
You must be signed in to change notification settings - Fork 4
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
ValueError: Cyclic dependency while building _presence_handler #12
Comments
I believe this may be due to the import line: from synapse.metrics.background_process_metrics import run_as_background_process
You should be able to simply do: from synapse.module_api import run_in_background and use that method instead (just drop the Interestingly I wasn't able to reproduce this cyclic dependency when attempting to run this on Synapse v1.37.0, which may be a result of the recent module refactoring. |
@anoadragon453 As suggested I replaced Unfortunately this doesn't fix the issue. I assume the reason you can't reproduce is is because of the two conditions:
and
In a non-worker setup those will always be false. |
|
In Synapse v1.35.1 (with the module running on the main process):
raiden-synapse-modules/raiden_synapse_modules/presence_router/pfs.py Lines 241 to 246 in 9186b17
In Synapse v1.50.1 (5666773341): The PFS presence router is now being initialised as Synapse starts up (which in contrast to v1.35.1, means that Synapse has initialised even less stuff now):
The key problem is that we're trying to do things in A workaround for now may be to call these methods once from either Questions:
|
Actually, what we were seeing was the class being loaded, not an instance of it. The modules are actually initialised here, outside of Thus, I would try upgrading Synapse and see if the exception no longer occurs. |
It seems that https://github.com/raiden-network/raiden-synapse-modules/blob/main/raiden_synapse_modules/pfs_presence_router.py#L88-L92 does not work as intended.
The text was updated successfully, but these errors were encountered: