-
Notifications
You must be signed in to change notification settings - Fork 520
[chore]: migrate from sigs.k8s.io/yaml to goccy/go-yaml #3997
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[chore]: migrate from sigs.k8s.io/yaml to goccy/go-yaml #3997
Conversation
I'll check these in a moment |
ba7a1cb
to
2e2b226
Compare
@LucaLanziani can you take a look to the CI? |
@iblancasa sure, I'll fix the remaining test this evening, I assumed that |
@iblancasa I don't know if you have seen my comment on the issue I believe we should target these as part of this PR
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we need to adapt all the e2e tests in that case 🙈
@@ -7,7 +7,7 @@ import ( | |||
"errors" | |||
"fmt" | |||
|
|||
"gopkg.in/yaml.v3" | |||
go_yaml "github.com/goccy/go-yaml" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(nit)
go_yaml "github.com/goccy/go-yaml" | |
yaml "github.com/goccy/go-yaml" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's better for this to consistently be go_yaml
everywhere. When I see yaml
, I assume it's gopkg.in/yaml
, so a different alias seems useful to indicate that it's not.
After looking at the indentation here once more https://github.com/open-telemetry/opentelemetry-operator/actions/runs/15075431358/job/42467505446?pr=3997#step:8:430 I realized that the If we use two spaces for the following:
looks like:
so indenting by four can only be:
but in the test you see we have a mix of the two. You can see the difference between the two libraries here: https://go.dev/play/p/fo6MEYZyIuy So ideally we should fix the indentation in the tests but I believe @swiatekm you said that doing that will cause an unnecessary reconciliation for users. |
It's even more visible here: And yet |
5917083
to
0f6848b
Compare
If the current output is incorrect and difficult to reproduce, then we should bite the bullet and change it. |
0f6848b
to
2111a8a
Compare
I'll create a second issue to replace all other yaml libraries. |
I might be doing something wrong but I'm not able to reproduce this error on my machine. |
It's flaky, I restarted it. |
New issue created github.com//issues/4028 |
Description:
Replace unmaintenance yaml library sigs.k8s.io/yaml with https://github.com/goccy/go-yaml
Link to tracking Issue(s):
gopkg.in/yaml.v3
#3988Testing: