Skip to content

Conversation

jem-davies
Copy link
Collaborator

No description provided.

…ning to deprecated components & fields

Signed-off-by: Jem Davies <[email protected]>
@jem-davies jem-davies force-pushed the add-lint-warnings-to-streambuilder branch from 4aed88e to ed82191 Compare October 17, 2025 14:03
}

// LintLevel describes the severity level of a linting error.
// NOTE: These should be kept in sync with ./internal/docs/field.go:726.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe make this in in-comment function, since this will be exposed in public otherwise.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It's the same as https://github.com/warpstreamlabs/bento/pull/508/files#diff-cbeda7f53df6b8a29295c69f3ee48389cfcb2fd5f090f03c36c195285f29c82cR12

Maybe it's not that bad that people will see that - they might check that it's true

lintingDisabled bool
envVarLookupFn func(string) (string, bool)

lintWarns []Lint
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does it make sense to store/cache lint warnings? I prefer the approach of linting on build/startup (unsure if this is already happening).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah so it's like this because we lint the configs when we call streambuilder.AddInputYaml / .SetYaml etc.

But at that time we don't necessarily have a logger until we call streambuilder.Build() where if we haven't set a logger via .SetLogger() we will get a default, and then we log the cached lintWarns.

Perhaps there is a better way - this is just the first that came to mind...

Signed-off-by: Jem Davies <[email protected]>
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.

2 participants