mirror of
https://github.com/kakwa/ldapcherry
synced 2025-07-03 20:07:42 +02:00
begin attributes handling manipulation
This commit is contained in:
parent
1211ab431b
commit
dbc88163dd
6 changed files with 141 additions and 28 deletions
18
misc/debug_attributes.py
Normal file
18
misc/debug_attributes.py
Normal file
|
@ -0,0 +1,18 @@
|
|||
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')
|
Loading…
Add table
Add a link
Reference in a new issue