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

Improvement: add the ability to limit certain tags for users #17831

Open
lamoboos223 opened this issue Oct 15, 2024 · 4 comments
Open

Improvement: add the ability to limit certain tags for users #17831

lamoboos223 opened this issue Oct 15, 2024 · 4 comments

Comments

@lamoboos223
Copy link
Contributor

In current matrix synapse you can set as many tags as you want, but I’m proposing to add an attribute in homeserver.yaml to restrict applying some tags to specific max amount. For example: a user can add the tag u.pin to 3 rooms only if these directive exist in homeserver.yaml

tags:
- name: u.pin
max: 3

@sandhose
Copy link
Member

The API for setting new tags only specifies a 200 OK status: https://spec.matrix.org/v1.12/client-server-api/#put_matrixclientv3useruseridroomsroomidtagstag

I feel like this would require a spec change to add possible error messages to tell the client that they can't set more tags, or even an API for the client to discover the limit

@lamoboos223
Copy link
Contributor Author

I can do the logic and the error as PR, but I have no clue how to add discovery to let clients know about tags restrictions. Can you elaborate?

@sandhose

@sandhose
Copy link
Member

What I mean is that to do this change properly, so that clients can properly react to this change, you'd need to propose a spec change through the Matrix Spec Change process outlined here: https://github.com/matrix-org/matrix-spec-proposals?tab=readme-ov-file#summary-of-the-process

@lamoboos223
Copy link
Contributor Author

lamoboos223 commented Oct 27, 2024

Hi @sandhose
They said they think this change should be "implementation detail" not coupled to the specs
matrix-org/matrix-spec-proposals#4216

do we need to make it a specs to add such change to synapse server?

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

No branches or pull requests

2 participants