Skip to content

Behavior of current-libp2p-daemon when starting and stopping #20

@AlexKnauth

Description

@AlexKnauth

The parameter current-libp2p-daemon is treated specially in start-libp2p-daemon!, but not within stop-libp2p-daemon!, which can cause problems when a program wants to start a libp2p-daemon, stop it, and start a new one all in the same Scheme process which shares the current-libp2p-daemon state.

Would it make sense for stop-libp2p-daemon! to set current-libp2p-daemon to false only if it's called with no arguments, but not do that if it's called with an argument?

Or would it make more sense for stop-libp2p-daemon! to set current-libp2p-daemon to false any time its argument is equal to (current-libp2p-daemon), whether that argument was implicit/default or explicit?

Or would it make more sense for start-libp2p-daemon! to rely less on current-libp2p-daemon instead?

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