Pubsub get previous messages

Is it actually possible to get previous messages, which were sent before I subbed?

hi,

in rust or directly in IPFS i don’t know you can see that : https://github.com/ipfs-shipyard/ipfs-pubsub-room

regards

Thank you a lot! Will check it ASAP

looks like there are dependency problems with electron.
trying to make it work, but shitty levelup/leveldown are making it impossible…

try that npm install leveldown : https://www.npmjs.com/package/leveldown

already, it happens because of electron own node version.

maybe you can check : JS-IPFS not works fine directly with electron also : https://github.com/ipfs/js-ipfs/issues/843

I hit this recently as well - you need Node 7+ in order to use async/await, but the latest versions of levelup/down won’t work with Y-leveldb. I fixed it by putting
“levelup”: “^1.0.0-4”,
“leveldown”: “^1.7.0-0”,
In my own package’s JSON dependencies.

I posted this as an issue in their github, and he said he hasnt got time to fix the dependency but will add it to y-level’s dependency so node does the right thing. I’m not sure if that has propogated to NPM yet, but if not you can use the fix above.

This was the only problem i had moving to the newer Node.

… in answer to your question, YES, you can access old messages on pubsub, we do it in our (archive.org)'s IPFS library. There does appear to be some flakiness in terms of persistence, and I haven’t been able to figure out what Y’s intended persistence model is yet. (any pointers appreciated).

2 Likes