-
Notifications
You must be signed in to change notification settings - Fork 598
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NIP-81 - Event Copy #528
NIP-81 - Event Copy #528
Conversation
I think if you want to save it you should just save it. |
let me try to make things clearer...
|
The Direct Message (kind 4) example:User
So this NIP proposes that
|
- Capital `K` tag with original event's `kind`; | ||
- All original event's single-letter tags. | ||
|
||
`I`, `P` and `K` tags are reserved. They cannot be used by any other event kind. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Example: if I'm copying an event that already has one P tag that also is a pubkey value, although with a custom meaning specific to that event kind, i end up with:
{
// other fields
"kind": 1006,
"tags": [
// other tags,
["P", "pubkeyA"], // copied from original event's "pubkey" field
["P", "pubkeyX"] // copied from original event's one-letter tags
]
}
Now if I were to request one of the copies I made, and wanted a copy that had originally the pubkey
field value "pubkeyX", I do ["REQ", "xyz", "{ \"kind\": 1006, \"#P\": [ \"pubkeyX\"], \"K\": .... }]
. This will wrongly bring me the above event.
That's why ideally we consider I, P and K in events other than copies invalid. Don't copy these invalid events and you will not have to filter things out client-side.
For the same reason I didn't make it a parameterized replaceable event (the original could alread have a "d" tag and its worse cause maybe only the first d tag is indexed on some relay implementations, cause of what is written on NIP-33)
This is similar to the problem NIP-10 introduced. Can't request direct descendants of a specific root event without filtering out a bunch of events I don't want just because although the e
tag means event id, it is used with different contexts ("root", "reply" and the legacy "mention").
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Re-publishing using own quota: Use NIP-42 AUTH
- Group moderation: make a special kind to hide certain messaes
- DM inbox: You can always make a deletion event that deletes others' DM messages from your own pubkey, and your client can then honor that. Or make a special kind to hide DM messages.
There is no use case imo.
@Semisol I will focus on the DM example cause it is a stronger selling point.
What you suggest will only work in one client, you are just cleaning a DM from the local client database. If I were to open my inbox on client no.2, all messages will be there. What I propose is an inbox be made of event copies. An event copy proves that your client didn't create a fake message. It has the same queryiable fields of the original. It represents a read message. Or can later be deleted and then replaced by a version with no .content to represent a deleted message. Also, if the sender deletes the message from the relay after you've "read it" (after your client created a copy on the relay, not on local DB), it won't touch your inbox.
Well this is what I just did. But it needs to have all the other technical features I listed. |
I'm closing it as this event is too generic and the Inbox interop use case got no interest so probably gonna use NIP-78 |
Please check the NIP for some use cases.