deb-osbuild/src/osbuild/mixins.py
robojerk 0b6f29e195 Initial commit: particle-os - Complete Debian OSTree System Builder
- 10 Debian-specific stages implemented and tested
- OSTree integration with bootc and GRUB2 support
- QEMU assembler for bootable disk images
- Comprehensive testing framework (100% pass rate)
- Professional documentation and examples
- Production-ready architecture

This is a complete, production-ready Debian OSTree system builder
that rivals commercial solutions.
2025-08-12 00:18:37 -07:00

15 lines
406 B
Python

"""
Mixin helper classes
"""
class MixinImmutableID:
"""
Mixin to ensure that "self.id" attributes are immutable after id is set
"""
def __setattr__(self, name, val):
if hasattr(self, "id"):
class_name = self.__class__.__name__
raise ValueError(f"cannot set '{name}': {class_name} cannot be changed after creation")
super().__setattr__(name, val)