-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Tenant is not unique by associated groups #10373
Comments
This is the intended behavior; there is nothing in the documentation to suggest that tenant names are unique per group (unless I've missed something). You're welcome to submit a feature request proposing this change, however there are implications of relaxing the uniqueness constraint that need to be discussed. For instance, it would no longer be sufficient to reference a tenant by name only e.g. during CSV import of objects; the user would be required to specify both the name and group in order to adequately identify the a tenant. |
@jeremystretch The exact same functionality works for Contacts. I can have two users with the same name in different groups.
It's not relaxing the uniqueness, it's about adding it which is missing. The reason for opening this as a bug was I felt it was an oversight and probably got missed. Otherwise, how would you add two people with the same names to the system even though they belong to different companies? It's not possible with the current code but the same works when creating a contact. |
Yes, and that's how contacts are intended to work. Tenants are not.
Your proposal is to relax the uniqueness constraint on Tenant's |
100% for keeping tenant object being unique globally. if this is adjusted to unique per group i hope there is a config option to keep the current default |
NetBox version
v3.3.2
Python version
3.10
Steps to Reproduce
Expected Behavior
If a tenant belongs to a different group, then the uniqueness validation should be applied within the scope of the group. It is very well possible to have two or more people with the exact same name
Observed Behavior
Tenant name and slug are validated globally for uniqueness
The text was updated successfully, but these errors were encountered: