Skip to content

One nickname which is null blocks access to all other identities in WebOfTrust #26

@Spider-Admin

Description

@Spider-Admin

Hi,

as reported in FMS, I had to recover my identities from WebOfTrust. One identity was recovered, while another one was stuck in recovery state. Both identities have Sone.

I was unable to use Sone with my recovered identity because there was this exception in the logs:

<timestamp> (net.pterodactylus.sone.freenet.wot.IdentityManagerImpl, Sone Identity Manager, ERROR): Uncaught exception in IdentityManager thread!
java.lang.IllegalStateException: get("Nickname$index") must not be null
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt.parseOwnIdentity(PluginWebOfTrustConnector.kt:103)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt.access$parseOwnIdentity(PluginWebOfTrustConnector.kt:1)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnector$loadAllOwnIdentities$1.invoke(PluginWebOfTrustConnector.kt:43)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnector$loadAllOwnIdentities$1.invoke(PluginWebOfTrustConnector.kt:35)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt$parseIdentities$2.invoke(PluginWebOfTrustConnector.kt:99)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt$parseIdentities$2.invoke(PluginWebOfTrustConnector.kt)
at kotlin.sequences.TransformingSequence$iterator$1.next(Sequences.kt:172)
at kotlin.sequences.SequencesKt___SequencesKt.toCollection(_Sequences.kt:716)
at kotlin.sequences.SequencesKt___SequencesKt.toSet(_Sequences.kt:757)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt.parseIdentities(PluginWebOfTrustConnector.kt:100)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnectorKt.access$parseIdentities(PluginWebOfTrustConnector.kt:1)
at net.pterodactylus.sone.freenet.wot.PluginWebOfTrustConnector.loadAllOwnIdentities(PluginWebOfTrustConnector.kt:43)
at net.pterodactylus.sone.freenet.wot.IdentityLoader$loadAllIdentities$2.invoke(IdentityLoader.kt:41)
at net.pterodactylus.sone.freenet.wot.IdentityLoader$loadAllIdentities$2.invoke(IdentityLoader.kt:29)
at net.pterodactylus.sone.freenet.wot.IdentityLoader.time(IdentityLoader.kt:82)
at net.pterodactylus.sone.freenet.wot.IdentityLoader.loadAllIdentities(IdentityLoader.kt:40)
at net.pterodactylus.sone.freenet.wot.IdentityManagerImpl.serviceRun(IdentityManagerImpl.kt:66)
at net.pterodactylus.util.service.AbstractService.run(AbstractService.java:441)
at java.base/java.lang.Thread.run(Thread.java:832)
at net.pterodactylus.util.thread.DumpingThread.run(DumpingThread.java:104)

My suggestion: Just skip identities, which are null, when iterating existing identities.

Metadata

Metadata

Assignees

No one assigned

    Labels

    not a bugissue is not a bug but intended behaviour

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions