-
Notifications
You must be signed in to change notification settings - Fork 498
Closed
adamlaska/ipfs-js-ipfs
#3Labels
P2Medium: Good to have, but can wait until someone steps upMedium: Good to have, but can wait until someone steps upexp/noviceSomeone with a little familiarity can pick upSomeone with a little familiarity can pick upkind/bugA bug in existing code (including security flaws)A bug in existing code (including security flaws)status/readyReady to be workedReady to be worked
Description
First and foremost: Thanks for this great package and the hard work! 👍
- Version: 0.26.0
- Platform: Linux Kubuntu-18 4.18.0-25-generic
- Subsystem:
Type: Feature
Severity: Low
Description:
Currently is the option emitSelf for pubsub
packages (libp2p/js-libp2p-floodsub and ChainSafe/gossipsub-js) hardcoded in the code.
Line 10 in fd738f9
const pubsub = new Pubsub(node, { emitSelf: true }) |
Both pubsub
packages support the emitSelf option. It would be nice to add the option to specify if self-published messages should be received.
Example:
export class Bundle extends libp2p {
constructor(_options) {
const defaults = {
modules: {
transport: [TCP],
streamMuxer: [Mplex],
connEncryption: [SECIO],
peerDiscovery: [Bootstrap],
dht: DHT,
pubsub: GossipSub,
},
config: {
pubsub: {
enabled: true,
+ emitSelf: false,
},
},
};
super(defaultsDeep(_options, defaults));
}
Steps to reproduce the error:
Metadata
Metadata
Assignees
Labels
P2Medium: Good to have, but can wait until someone steps upMedium: Good to have, but can wait until someone steps upexp/noviceSomeone with a little familiarity can pick upSomeone with a little familiarity can pick upkind/bugA bug in existing code (including security flaws)A bug in existing code (including security flaws)status/readyReady to be workedReady to be worked