Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
louisroyer committed Oct 24, 2024
1 parent c833a9c commit d1dadbd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion default-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ config:
nb_edges: 2
nb_ue: 1
dataplane: # ( nextmn-srv6 | free5gc | nextmn-upf)
- "nextmn-srv6"
- "nextmn-srv6"
log_level: "info"
full_debug: false

Expand Down
7 changes: 6 additions & 1 deletion scripts/config_edit.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@
class ConfigException(Exception):
'''Configuration issue'''

class Dumper(yaml.Dumper): #pylint: disable=too-many-ancestors
'''yaml dumper'''
def increase_indent(self, flow=False, indentless=False):
return super().increase_indent(flow, False)

if __name__ == '__main__':
parser = argparse.ArgumentParser(
prog='config-edit',
Expand Down Expand Up @@ -58,4 +63,4 @@ class ConfigException(Exception):
if args.full_debug is not None:
c['config']['topology']['full_debug'] = args.full_debug.lower() == 'true'
with open(args.buildconfig, 'w', encoding='utf-8') as f2:
yaml.dump(c, f2)
yaml.dump(c, f2, Dumper, default_flow_style=False)

0 comments on commit d1dadbd

Please sign in to comment.