Skip to content
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

Improve tests coverage for "Hide public links" feature #1306

Open
ArthurHoaro opened this issue May 25, 2019 · 4 comments
Open

Improve tests coverage for "Hide public links" feature #1306

ArthurHoaro opened this issue May 25, 2019 · 4 comments
Labels
cleanup code cleanup and refactoring

Comments

@ArthurHoaro
Copy link
Member

IMO this feature does not make sense.

It adds code complexity without really providing any feature, because this can be done by publishing private links. Also there is a setting which set all new bookmarks to private by default.

What's your opinion on this?

Regarding the change, we can make an update function which set all links to private if the setting is enabled.

@nodiscc
Copy link
Member

nodiscc commented May 26, 2019

There is only use case I see for this feature, which is temporarily hiding all links, if you have inadvertently pushed sensitive data in public shaares, giving you time to do some cleanup, set correct visibility, etc.

In that case you might as well backup your shaares using HTML exports or the API; take the server offline/restrict access through firewall/HTTP auth/server allow-deny directives; edit your shaares offline, and import them back.

But I've never used it, fine by me.

@nodiscc
Copy link
Member

nodiscc commented May 26, 2019

For reference, the original issue requesting this was #188, and before that, the orignal todo-list from sebsauvage (#106).

There have been a few bugs in the past around that feature (search hide public links in issues).

Some people seem to have a use for it (#1030) @averymd do you still use Hide public links on your instance? If yes, what's your use case? How could it be replaced if it were removed?

@averymd
Copy link

averymd commented May 26, 2019

I do still use Hide public links - my Shaarli instance is for my personal bookmarks, and the combination of Require login and Hide public links achieves that. This allows me to not be dependent on browser syncing by any particular company, and allows me to not need browser syncing between corporate browsers and my personal browsers in order to store and use professional links that apply to my career.

Once authenticated, I use public vs private to distinguish between links I do or don't mind my colleagues seeing over my shoulder. I still wouldn't want my "public" links to be open to the world. Having the server be "online" (if you mean internet-accessible) allows me to hook into platforms like IFTTT to store links. I use that a lot.

If the feature were removed, I would need to use something like HTTP auth (hopefully Shaarlier can work with that), which is more cumbersome even with a password manager. I could also write a custom utility to sync from a home-hosted Shaarli instance to my various Chrome and Brave profiles. (I'm unfamiliar with browser APIs and their bookmark manipulation abilities, so I'm not sure of the feasibility of that.)

All of this said, I do understand if the community wishes to say that Shaarli isn't the right tool for personal bookmarks and that people should use or build something else for that.

@ArthurHoaro
Copy link
Member Author

All of this said, I do understand if the community wishes to say that Shaarli isn't the right tool for personal bookmarks

It is exactly its exactly its purpose, along with sharing them.

I don't mind keeping this feature if it has an actual use case, which I couldn't really see in my original post. Thank you @nodiscc for tracking down those issues.

From my understanding, this setting is useful for you in combination of filtering out private or public bookmarks. Even though it's slightly twisting the original meaning of public/private bookmarks, it makes sense.

So, if this feature is used and seen as useful, we should keep it.

However, I almost missed it in #1307 because I think that here only a single unit test covering it. We should improve that.

@nodiscc nodiscc added cleanup code cleanup and refactoring and removed discussion labels Jun 26, 2019
@nodiscc nodiscc changed the title Remove "Hide public links" feature Improve tests coverage for "Hide public links" feature Jun 26, 2019
@nodiscc nodiscc added this to the backlog to the future milestone May 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup code cleanup and refactoring
Projects
None yet
Development

No branches or pull requests

3 participants