Skip to content

Commit

Permalink
add conditional import to support conda package manager
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhananjhay committed Nov 22, 2024
1 parent 0f07ece commit 64fc92e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion snakebids/io/yaml.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
from pathlib import Path, PosixPath, WindowsPath
from typing import Any, OrderedDict

from ruamel.yaml import YAML, Dumper
try:
from ruamel.yaml import YAML, Dumper
except ImportError:
from ruamel_yaml import YAML, Dumper


def get_yaml_io():
Expand Down

0 comments on commit 64fc92e

Please sign in to comment.