Same trace with CRLF, CR or LF end of lines (at least using Notepad++):
ERROR: Error loading penguins.yaml:
Invalid syntax in 'penguins.yaml' on line 1:
Traceback (most recent call last):
File "C:\Users\rrr\miniconda3\lib\site-packages\bokeh\application\handlers\code_runner.py", line 106, in __init__
nodes = ast.parse(source, os.fspath(path))
File "C:\Users\rrr\miniconda3\lib\ast.py", line 50, in parse
return compile(source, filename, mode, flags,
File "penguins.yaml", line 1
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UXXXXXXXX escapeThis text will be hidden
Yes, I did check that the character is actually changing to LF, even it could be seen in plain Notepad.
I have tried debugging and have been able to fix it. It seems that YamlHanlder generates a path in Windows mode using backslashes. Forcing the path to be posix in this line of this file works: filename = Path(os.path.abspath(kwargs['filename'])).as_posix()
Thanks again and I hope it can be helpful to anyone who has the same problem.