missing yaml file in the middle of the loaded file list throws an error
adragomir opened this issue · 2 comments
I looked into the issue I had a bit more.
What (seems to) happen is:
0. Try to load a list of files, the middle one is missing (settings - interpolate false, failonmissingfiles = false)
- First file is loaded - f variable (Line 170) is a file, and is also read - at end
- Second file is missing, but in the
except IOError as e
, the f variable is not set, and it remains at the previous file value - yaml.safe_load / odyldo.safe_load just reads the file, which is at end, so the result is None
- self._data is not None, so the code continues, but merging throws an error
Hello
Thanks for pointing me at this
The issue was introduced w/ commit 662bb99 (see my comment 3 at #3 ) . That was just a q&d step to reflect the missing files problem you reported in the _files var.
The problem should not occur in the latest release and has been fixed w/ commit/5b973744b09e1d0362d408061c98aec6df6061e7
So please try the latest release or the newest git checkout.
If you still have problems, please extract a case from your yaml files.
Helo.
Did you made any progress on this?
If you can extract a test case, I will try to find out what is going wrong.