Skip to content

Conversation

@olehermanse
Copy link
Member

@olehermanse olehermanse commented Jul 15, 2025

This will probably warrant a major version bump since it seems relatively breaking, but I think we should do this, since it reduces the chances of someone editing a project into a state which their hub won't build correctly.

@olehermanse
Copy link
Member Author

Builds on #256

@olehermanse olehermanse changed the title Made validation more strict in cfbs add/remove/update/status/info/input Made validation more strict in cfbs add/remove/update/status/input Jul 16, 2025
We want cfbs build to be backwards compatible (also cfbs download).
In these other commands it makes more sense to be more strict to
try to catch mistakes and prevent bad situations.

If cfbs versions differ, we assume the user is running a newer version and
the hub is running an older version of cfbs when it's running cfbs build.
In all cases, we want users to be able to upgrade cfbs and still have
cfbs build work.

If the user attempts to edit the project, and validation fails, it
could mean:

- The project was made / edited on a newer version of cfbs
- The project has mistakes, for example after editing the JSON manually

Both of which we want to catch and fix, by making the user upgrade cfbs
and/or fix errors in the cfbs.json.

Signed-off-by: Ole Herman Schumacher Elgesem <ole.elgesem@northern.tech>
@olehermanse olehermanse force-pushed the strict branch 3 times, most recently from 2906017 to b4d8e1c Compare July 16, 2025 11:03
Signed-off-by: Ole Herman Schumacher Elgesem <ole.elgesem@northern.tech>
@olehermanse olehermanse marked this pull request as ready for review July 16, 2025 11:11
@olehermanse olehermanse merged commit 0ef0c01 into cfengine:master Jul 16, 2025
11 checks passed
@olehermanse olehermanse deleted the strict branch July 16, 2025 11:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants