Open m4tiz5zktonj opened 2 months ago
I understand this issue is kind of "very low priority", but when barrel is compiled, and file begins to exist, this error about missing barrel does not disapper until VS Code is reloaded or project's barrels.jungle
file contents is changed.
PMC could, probably, create watchers for every referenced ".barrel" like this: https://github.com/markw65/prettier-extension-monkeyc/blob/8850e8c00b14619454de48448d67b96e7b93b62a/src/project-manager.ts#L133-L135 to restart project analysis automatically when barrel is built.
I think it's even easier. They should be included in the buildDependencies
, and will automatically be watched by addExtraFileWatchers
.
Sometimes it can be not easy to guess which project in the workspace misses compiled barrel file, as plugin reports error for not existing file:
There are no
monkey.jungle
file in the workspace root, as all projects are in their subdirectories. It would be nice, if error was pointing to specific project'sbarrels.jungle
, where the missing barrel is referenced.It can be reproduced in your Barrels repo by removing
CompiledBarrel/bin/CompiledBarrel-0.0.0.barrel
file.