Skip to content

Prevents removal of machines with active user services#175

Merged
dkmstr merged 1 commit into
v4.0from
dev/v4.0-openuds-remove-fixed-machines
May 22, 2026
Merged

Prevents removal of machines with active user services#175
dkmstr merged 1 commit into
v4.0from
dev/v4.0-openuds-remove-fixed-machines

Conversation

@aschumann-virtualcable

Copy link
Copy Markdown
Contributor

This pull request introduces a stricter validation when updating the list of assigned machines in the FixedService class. Now, it prevents removing any machines that still have assigned user services, which avoids lingering UserService records that would incorrectly count against the userservices_limit.

Validation improvements:

  • Updated the machine removal logic in service.py to raise a validation error if an attempt is made to remove machines that still have assigned user services, ensuring data consistency and preventing orphaned UserService rows.

Ensures machines cannot be removed if they have assigned user services,
avoiding orphaned resources and enforcing service limits integrity.
Raises a validation error listing machines that cannot be removed.
@dkmstr dkmstr merged commit 3335692 into v4.0 May 22, 2026
2 checks passed
@aschumann-virtualcable aschumann-virtualcable deleted the dev/v4.0-openuds-remove-fixed-machines branch May 26, 2026 08:31
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.

2 participants