eiffel-community / eiffel

The Eiffel framework vocabulary, descriptions, guides and schemas along with links to relevant implementation repositories.
Apache License 2.0
122 stars 59 forks source link

Missing Eventname and Version in the YAML files #341

Closed m-linner-ericsson closed 9 months ago

m-linner-ericsson commented 1 year ago

Description

When programmatically reading the YAML files in the https://github.com/eiffel-community/eiffel/tree/master/definitions the only way to figure out the name and version is to look at the filename and path.

Motivation

Reading the file name and directory structure to figure out the event name is error pone and not straight forward.

Exemplification

In e.g https://github.com/eiffel-community/eiffel/blob/master/definitions/EiffelActivityTriggeredEvent/4.2.0.yml you can't explicitly find the event name and version.

Benefits

Being able to programmatically read out the event name and version without having to look at the directory structure and filenames.

Possible Drawbacks

None that I can see

magnusbaeck commented 1 year ago

One drawback of including this information in the file itself is that there could be inconsistencies between the path and the file contents. To mitigate this we could introduce a test that checks for such inconsistencies. This assumes that we want to keep the current filename convention, but I don't think there are any good reasons for changing it.