Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
David Dahl
@daviddahl
w00t
Mark Nadal
@amark
maybe people forget who I was while I was gone (family emergency, legal deadlines). I'm one of the authors.
David Dahl
@daviddahl
i'm still obsessed with gun, fwiw
Mark Nadal
@amark
<3 <3 <3
let's do a call?
David Dahl
@daviddahl
sure
lemme know what works, I am in EDT
Mark Nadal
@amark
today? tomorrow? good times?
David Dahl
@daviddahl
I can do today or tomorrow or Friday
Mark Nadal
@amark
DM me on twitter and I'll send you a link?
David Dahl
@daviddahl
I nuked my twitter years ago :)
Mark Nadal
@amark
I'm also known as "that guy who tries to read & follow up with all questions with help if they're missing" however since I was gone for 2 week I will <<<<NOT>>>> be trying to catch up on things.
Tho, does anyone have off the top of their head a bunch of new people they can tag for me so I can say hi hi hi hi??? :) :) :)
David Dahl
@daviddahl
I am on session and moving off of signal
Mark Nadal
@amark
let me try to DM you here
David Dahl
@daviddahl
ok
Lorenzo Mangani @qxip
@lmangani:matrix.org
[m]
welcome back @amark 🥳
rococtz
@rococtz:matrix.org
[m]
@ruslanjan: nothing stops users from wiping out pubic nodes. That's why you have to use the user space (SEA)
rococtz
@rococtz:matrix.org
[m]
@huberttl: it's probably referring to node.js peers (if you run gun in node as opposed to browser)
azdez
@azdez:matrix.org
[m]
i am using gun/lib/unset .unset() but i keep getting error

const rel = Gun.val.link.; // '#'

TypeError: Cannot read property 'link' of undefined

tedd pasta
@azdez:matrix.org
[m]
is gun/lib/unset not supported anymore?
rococtz
@rococtz:matrix.org
[m]
tedd pasta: I am not aware of any news about not being supported anymore, but it's just a small wrapper for .put(null). It's probably safer to just go with that
Mark Nadal
@amark
:D :) <3
@rococtz:matrix.org I tried to just DM you (let me know if matrix picks it up)
rococtz
@rococtz:matrix.org
[m]
@amark: I got it and replied as DM
libensveto
@libensveto_twitter
Dont know if you remember our convo on discord about erapay (im @blevvys) but had clarity and am rebuilding it to be 100% OSS and would like, if you would be happy about it, for it to be called erapay. Its come a long way and ill drop a demo in a day or two
@amark
βτεsηΘω
@bresnow
I deployed two gundb containers and tried to play in the browser console. The metadata shows up but the websocket connection fails immediately after i call Gun(<url>)... I get the Gun object back though
is this normal
Mark Nadal
@amark
@rococtz:matrix.org yay!
@libensveto_twitter :fire: :fire: :fire: :fire: :fire: OPEN SOURCE FOR THE WIN!!!! oooo so excited for the demo :D
@bresnow yo! Thanks for jumping in (you should show off some of your design skills!). It is possible that either:
(A) forgot the /gun, (B) the load balancer / etc. does not support sticky sockets or needs extra configuration (C) https vs http issues
@bresnow just noticed that @finwo also knows traeffik, so maybe you can collaborate on this wiki: https://github.com/amark/gun/wiki/Traefik see if his is working, see if his is missing stuff in yours, and then update it with the best of both???
libensveto
@libensveto_twitter
done is better than perfect so heres a quick preview of a gun version of stripe
libensveto
@libensveto_twitter
the app takes an input of a product name and price and gives you a checkout connected to your dashboard based off iris, so no sign-ups. The checkout is pre-stylised with tailwind. More data needs to be funnelled and categorised on the dash to make it more biz friendly. If anyone wants to help drop a dm
mimiza
@mimiza
@amark welcome back!!
awaisnazir21
@awaisnazir21
@amark gun is a wonderful project. its power lies in its simplicity. i really liked the .map() function. I now try to think in map terms than sql query terms.
@amark can you write an exact code to change the user login credentials. I know we can change password by setting parameter in user.auth, but I am lost how to change the username/email. I have searched documentation, google, github, this chat forum, but can't figure out. Maybe update the documentation also regarding username change.
@amark I have found a problem with .map(). It works ok alone, but when coupled with promises, it doesn't work anymore. Also .then() don't work with .map() in my experience, even vanilla javascript promises also don't work with .map() in my experience. I know .map() is still experimental, but you said to report any bugs, so thats it.
awaisnazir21
@awaisnazir21
@amark I also want to contribute to the gun codebase and its documentation, how should I even start?
rococtz
@rococtz:matrix.org
[m]
@awaisnazir21: Have you included the then module?
https://gun.eco/docs/API#-a-name-then-a-gun-then-cb-not-official-yet-
You can start by reading & understanding the docs. Whenever you find something that is not documented enough, you can update the wiki with more and better examples. Next level is to actually create a real app using gun, a proper app with features, users, etc. This way we can see gun in real use cases and discover bugs.
huberttl
@huberttl

Hi There. I am actually creating a gun app for PoC for next week using Svelte as framework. So far it works fine. I only have few questions
Deleting Object.
It seems that when deleting an object it returned error.

const db = GUN()
db.get('object1').put({price: 200})
db.get('object1').put(null) // returns run time error

db.get('object1').put({price: null}) it works

The ERROR as follow:
gun.js:1008 Uncaught TypeError: Cannot read properties of undefined (reading 'push')
at walk (gun.js:1008)
at Gun.chain.put (gun.js:1045)
at App.svelte:12
at run (index.mjs:18)
at Array.map (<anonymous>)
at index.mjs:1731
at flush (index.mjs:1039)
at init (index.mjs:1823)
at new App (App.svelte:12)
at main.ts:5

I also would like to clean my local network (localhost:5000),

  • localStorage.clear()
    kill server but I can't find the data.json file to delete

Can someone please give me few hints (Thanks :))

mundane_pftts
@mundane_pftts:matrix.org
[m]

The docs say relay peers are greedy, but is there a way to restrict it's data persistence ?

If I have multiple root nodes , is it possible for that peer to only persist one particular node ?
( You can assume I will have multiple peers- some relay, some not)

If not , what are alternate approaches ?

Thank you in advance 😁
Jabis Sevon
@jabis
@mundane_pftts:matrix.org you'd need to stab the gun.js with super:1 to stop the greedy behaviour basically
@huberttl Cannot read properties of undefined (reading 'push') is a svelte error - have a looksie on the wiki for svelte integrations
probably something to do with the data-store there - can't reconsile previous object to null or something to that extent
Ruslan Jankurazov
@ruslanjan
Is it good idea to store arrays as json strings? I don't need to query it only to get it as part of post?
Jabis Sevon
@jabis

then for clearing gun - stop all your gun instances, node or whatever, throw in (function(){ localStorage.clear()})() for browsers in your scripts - clear the gun's radata folder from existence and keep it so for a good period of time - one peer coming back to life with the full graph is all that's needed to fill an emptied one :)
1 reply
Jabis Sevon
@jabis
@mundane_pftts:matrix.org for your question about separated gun instances - you might have a few answers from our meething multisocket guns - where one path is one room and none is persisted https://github.com/meething/gundb-multisocket
βτεsηΘω
@bresnow
@amark thanks I'll look into it. And I'm working on something to show you soon