Skip to content
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

Add support for fields that match go reserved names #74

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

mariusvniekerk
Copy link

This builds and extend on pull request #12

Fixes #2 and likely fixes #46

I've added a test case to show the example case

@idodod
Copy link
Owner

idodod commented Apr 25, 2024

Hey @mariusvniekerk,
thanks for the PR!
I'll take a look in the next couple of days (sorry I missed it until now).

Copy link
Owner

@idodod idodod left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again for the contribution.
PR looks good, just a couple of minor issues.

Earthfile Outdated
Comment on lines 3 to 5
ARG --global ALPINE_VERSION=3.19
ARG --global GO_VERSION=1.22
ARG --global LINTER_VERSION=v1.57.2
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is necessary, is it?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might not be necessary, i vaguely recall running into issues with eathly 0.8+ without it i think

Comment on lines -54 to -56
if len(message.Fields) == 0 {
return nil
}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this necessary?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, without this messages with zero fields have issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

unparsable Go source: expected '}', found 'type' There is no check for reserved words in Golang
4 participants