-
Notifications
You must be signed in to change notification settings - Fork 289
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
Hide NIP-36 notes as #nsfw #2294
base: master
Are you sure you want to change the base?
Conversation
@@ -25,7 +25,7 @@ enum FilterState : Int { | |||
|
|||
/// Simple filter to determine whether to show posts with #nsfw tags | |||
func nsfw_tag_filter(ev: NostrEvent) -> Bool { | |||
return ev.referenced_hashtags.first(where: { t in t.hashtag == "nsfw" }) == nil | |||
return ev.referenced_hashtags.first(where: { t in t.hashtag == "nsfw" }) == nil && References<ContentWarningTag>(tags: ev.tags).first == nil |
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.
dont we need to check the reason == nsfw in the content warning case?
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.
We should consider any post with the "content-warning" tag as sensitive.
Therefore, there is no need to check the "reason."
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.
This is a post without reason.
https://nostter.app/nevent1qqswynxvz0wth52wjq3xyq7l795q3w0fe83ym0ewetnx8u9gslrhmhswwl5pw
{
"content": "に",
"created_at": 1718237816,
"id": "e24ccc13dcbbd14e90226203dff16808b9e9c9e24dbf2ecae663f0a887c77dde",
"kind": 1,
"pubkey": "1a35b54ef7752af54cacbeedf0f349e320f0a2ee50142883134c3ee31879ce71",
"sig": "3a1dc4873e2a8527ecfce2526af8701702e0d1bb3b4c4ecf45e8026cae27ceb84f40144e8409ca4a325e8e93f39fcba75ddf1c7ad0e57ba53f7e538a4da92b2a",
"tags": [
[
"content-warning"
]
]
}
On Wed, Jun 12, 2024 at 05:22:59PM GMT, kunigaku wrote:
@kunigaku commented on this pull request.
> @@ -25,7 +25,7 @@ enum FilterState : Int {
/// Simple filter to determine whether to show posts with #nsfw tags
func nsfw_tag_filter(ev: NostrEvent) -> Bool {
- return ev.referenced_hashtags.first(where: { t in t.hashtag == "nsfw" }) == nil
+ return ev.referenced_hashtags.first(where: { t in t.hashtag == "nsfw" }) == nil && References<ContentWarningTag>(tags: ev.tags).first == nil
We should consider any post with the "content-warning" tag as sensitive.
Therefore, there is no need to check the "reason."
hmm... the way content-warning was used on the fediverse is that you could
mark a message as "politics", so if you were not interested in politics
you could skip that.
Our filter is for NSFW content, if we were filtering political content
with this it would be incorrect.
|
Non-developers are unlikely to comment on GitHub. But I know many Nostr users who would love to have NIP-36. And they are unfortunately resigned to the fact that Damus does not have it. |
IMO, whatever the reason, I think the note-author's consideration that "maybe some people don't want to see it" should be taken into account. |
When posting images that may be objectionable to a certain number of people, a content-warning may be added as a warning (e.g., because of insects), but a content-warning added by another client's user out of consideration for others is not effective for Damus users, causing them to feel uncomfortable. |
On Sat, Jun 15, 2024 at 12:15:42AM GMT, mono wrote:
When posting images that may be objectionable to a certain number of
people, a content-warning may be added as a warning (e.g., because of
insects), but a content-warning added by another client's user out of
consideration for others is not effective for Damus users, causing them
to feel uncomfortable.
I'm not against adding support for content-warning, I just think we need
a proper control that hides content with a collapsible control on the
note without hiding the entire note. This nsfw filter is not the right
for this.
The nsfw filter will hide the entire note from the timeline. If we did
this for content warnings people would say we are shadow-banning people.
|
On Sat, Jun 15, 2024 at 09:46:13AM GMT, William Casarin wrote:
On Sat, Jun 15, 2024 at 12:15:42AM GMT, mono wrote:
>When posting images that may be objectionable to a certain number of
>people, a content-warning may be added as a warning (e.g., because of
>insects), but a content-warning added by another client's user out of
>consideration for others is not effective for Damus users, causing them
>to feel uncomfortable.
I'm not against adding support for content-warning, I just think we need
a proper control that hides content with a collpasible control on the
note without hiding the entire note. This nsfw filter is not the right
for this.
The nsfw filter will hide the entire note from the timeline. If we did
this for content warnings people would say we are shadow-banning people.
Alternatively we should have another filter setting for filtering all
content warnings instead of re-using the nsfw filter.
|
I think a proper control that hides content with a collapsible control on the note without hiding the entire note would be a good idea. |
Filters posts with the NIP-36 "content-warning" tag in the same way as the #nsfw hashtag.
https://github.com/nostr-protocol/nips/blob/master/36.md
Related issues: #910, #1412
Screenshots:
Show #nsfw and NIP-36
Hide #nsfw and NIP-36
This is a test post.
https://damus.io/note1z0jcu9wgevaajcvk947ea2aj8wv9nxlttj5dvj6wxfyz0v5ehpnq8t9l2p
The post on Rabbit.
https://rabbit.syusui.net/#/npub1l6gzvpjar07swqqq9gg9eshgtvtp2tyynv405jrsgxwrhpcupgcqqvy0hm