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

fix(groups): dsp-tools should not allow group creation if group name already in use (DEV-798) #183

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions knora/dsplib/utils/onto_create_ontology.py
Expand Up @@ -126,10 +126,10 @@ def create_groups(con: Connection, groups: list[dict[str, str]], project: Projec
group_exists: bool = False
if all_groups:
for group_item in all_groups:
if group_item.project == project.id and group_item.name == group_name:
if group_item.name == group_name:
group_exists = True
irinaschubert marked this conversation as resolved.
Show resolved Hide resolved
if group_exists:
print(f"WARN Group '{group_name}' already exists. Skipping...")
print(f"WARN Group name '{group_name}' already in use. Skipping...")
continue

# check if status is defined, set default value if not
Expand Down