mirror of
https://github.com/kakwa/ldapcherry
synced 2024-11-25 18:54:29 +01:00
19 lines
568 B
Python
19 lines
568 B
Python
from ldapcherry.attributes import Attributes
|
|
from ldapcherry.exceptions import DumplicateRoleKey, MissingKey, DumplicateRoleContent, MissingRolesFile
|
|
from ldapcherry.pyyamlwrapper import DumplicatedKey, RelationError
|
|
from yaml import load, dump
|
|
import yaml
|
|
|
|
try:
|
|
from yaml import CLoader as Loader, CDumper as Dumper
|
|
except ImportError:
|
|
from yaml import Loader, Dumper
|
|
|
|
class CustomDumper(yaml.SafeDumper):
|
|
"A custom YAML dumper that never emits aliases"
|
|
|
|
def ignore_aliases(self, _data):
|
|
return True
|
|
|
|
inv = Attributes('./conf/attributes.yml')
|