osbuild / otk

A proof of concept for a new `osbuild-mpp`.
https://osbuild.org/
Apache License 2.0
4 stars 9 forks source link

src: include current file in every raise() #243

Closed mvo5 closed 1 month ago

mvo5 commented 1 month ago

This commit adds the current file that was processed in all otk exceptions. This way it's easier for the user to spot where something went wrong.

This will now produce errors like:

...
otk.error.TransformDirectiveTypeError: [/home/mvogt/devel/osbuild/otk/example/centos/common/partition-table/x86_64/default.yaml] cannot join ['x']

[draft as I think this should be two commits and also it lacks dedicated tests, also there should probably a "state.make_error_prefix()" helper or something so that this is all in one place and externals should also be covered but I still wanted to open it so that it's not forgoten]

mvo5 commented 1 month ago

This is no longer needed, it got solved in a cleaner way via https://github.com/osbuild/otk/pull/263 and https://github.com/osbuild/otk/pull/265