Skip to content

Commit

Permalink
Change over from deprecated yaml roundtripdump. (#360)
Browse files Browse the repository at this point in the history
  • Loading branch information
JSKenyon authored Feb 20, 2025
1 parent 7aabafc commit fe216e7
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions quartical/config/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import sys
import os
from loguru import logger
from ruamel.yaml import round_trip_dump
from ruamel.yaml import YAML
from omegaconf import OmegaConf as oc
from quartical.config.external import finalize_structure
from quartical.config.internal import additional_validation
Expand All @@ -26,13 +26,9 @@ def create_user_config():
config = oc.merge(config, *additional_config)

with open(config_file_path, 'w') as outfile:
round_trip_dump(
oc.to_container(config),
outfile,
default_flow_style=False,
width=60,
indent=2
)
yaml = YAML()

yaml.dump(oc.to_container(config), outfile)

logger.success(
f"{config_file_path} successfully generated. Go forth and calibrate!"
Expand Down

0 comments on commit fe216e7

Please sign in to comment.