Skip to content

Conversation

@deevroman
Copy link
Contributor

Description

I am justifying this PR based on renewed interest in forum posts on this topic starting in the fall of this year https://community.openstreetmap.org/t/we-dont-need-anonymous-notes/105335/128 as well as from personal experience of resolving notes

  1. After 10 notes, the create notes form hides and the warning is repainted red
  1. The previous warning is displayed after 5 anonymous notes

  2. I reduced the lifetime of cookies that count anonymous notes to two weeks to compensate for the limit a little

How has this been tested?

Manual testing, as well as adding a new autotest

Explanation

Yes, the API is still not protected. Yes, you can open a private window.

But at least it will stop stupid robots, and it will also stop some users who use notes for other purposes faster. It is also a small stick in the wheels of lazy vandals.

@tomhughes
Copy link
Member

I thought we had already done this? How does it differ to what we have now?

@deevroman
Copy link
Contributor Author

deevroman commented Dec 6, 2025

Currently, a suggestion to log in is shown after 10 notes:

You can still ignore it and continue creating notes

I propose to show this warning after 5 notes.

@qugebert
Copy link

qugebert commented Dec 6, 2025

I doubt that this is the right approach. Anonymous notes can also be useful to us, they just take more time to process.
I admit that I myself am sometimes annoyed by too many notes where it is not possible to ask the person who submitted them for more information, but I still think that we should keep the barriers to reporting map errors as low as possible.

@deevroman
Copy link
Contributor Author

It's not (yet) about complete banning anonymous notes. If someone has created more than 10 anonymous notes through a website, then in practice this person is doing something wrong. Either these notes will contain little useful information, or it is from a dubious source, or he adds personal notes to his journey, or it will be easier and faster for the user to register and add objects own.

The reverse side of this restriction is the registration of a new mapper. This is potentially more useful.

@pablobm
Copy link
Contributor

pablobm commented Dec 8, 2025

For completeness, this PR would close #5934 (if I'm reading correctly).

@deevroman
Copy link
Contributor Author

deevroman commented Dec 8, 2025

For completeness, this PR would close #5934 (if I'm reading correctly).

No. This is client-side protection. It can be bypassed, for example, using third-party apps. However, third-party app users are far fewer, and most apps add the "user agent" to the note text. Thanks to the user agent, at least some grouping of notes will appear, which will simplify the elimination of vandalism.


However, perhaps this will help for most cases of vandalism and problem #5934 will be solved. After all, the restrictions on the size of changesets are also imperfect and easy to bypass, but they helped.

@pablobm
Copy link
Contributor

pablobm commented Dec 8, 2025

No. This is client-side protection. It can be bypassed

Right, I understand the initial description of #5934 sounds like it expects something more reliable, but ultimately a later comment (#5934 (comment)) refines it to pretty much what this PR offers. Which is understandable, because any other option sounds too heavy-handed.

Copy link
Contributor

@pablobm pablobm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm pessimistic about this solution... but I don't have the experience of dealing with anonymous notes every day, so I cannot tell for sure. I think it's worth trying, if only because it's very low hanging fruit. The DWG can then report back to let us know what they observed.

I don't know that the expiry needs to be reduced to 14 days, but also open on that one.

@deevroman deevroman force-pushed the more-limits-for-notes-form branch from 606bd65 to 0c6de8c Compare December 8, 2025 15:06
@deevroman deevroman force-pushed the more-limits-for-notes-form branch from 5e1d155 to 15928f8 Compare December 9, 2025 13:29
@deevroman deevroman force-pushed the more-limits-for-notes-form branch from 15928f8 to a71a909 Compare December 9, 2025 13:37
Copy link
Contributor

@pablobm pablobm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I say let's try this 🤞 Thank you @deevroman!


def hard_anonymous_notes_limit_reached?(anonymous_notes_count)
!current_user && anonymous_notes_count >= 10
end
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you are correct here, making these into pure functions instead of expecting @anonymous_notes_count to exist 👍 (which was what I initially suggested).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants