feat!: log package for consistent output#2979
feat!: log package for consistent output#2979mdelapenya merged 21 commits intotestcontainers:mainfrom
Conversation
✅ Deploy Preview for testcontainers-go ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
ea96e68 to
7a7f9b0
Compare
7a7f9b0 to
cdb9520
Compare
stevenh
left a comment
There was a problem hiding this comment.
Looking good, just a few little bits.
Co-authored-by: Steven Hartland <[email protected]>
stevenh
left a comment
There was a problem hiding this comment.
Changes LGTM.
As this is a breaking change lets add the ! to title and footer as per https://www.conventionalcommits.org/en/v1.0.0/
As it is a fix, I would suggestion we capture the what in the title and then in expand with how / why in the description.
stevenh
left a comment
There was a problem hiding this comment.
Just a little fix for log capture in the wait tests.
mdelapenya
left a comment
There was a problem hiding this comment.
Added a few comments, no blockers
Co-authored-by: Manuel de la Peña <[email protected]>
stevenh
left a comment
There was a problem hiding this comment.
just a typo and the request from @mdelapenya about the default logger.
mdelapenya
left a comment
There was a problem hiding this comment.
LGTM, thank you so much for your work here. 🙇
@KenxinKun @stevenh I added df2324e to avoid having you working more in this. It's basically adding the new log package to one missing markdown file.
We are merging this PR when the CI passes 🚀
Cheers!
|
BTW @KenxinKun @stevenh wdyt if we change the title of this PR to communicate better we are refactoring the log infra? Something like |
As this is a new package, I'd go with: And then expand on the body. The reason to not include log in the scope is it doesn't exist yet (updates would), and for description if it wraps in github its too long, so trying to be concise 😄 |
|
@mdelapenya @stevenh I synced the fork and update this branch you may need to kick CI again, happy with suggestions above |
* main: (54 commits) deps: update go version from 1.22.0 to 1.23.0 (testcontainers#2985) feat(redpanda): add bootstrap user account option (testcontainers#2975) chore(ollama): bump default version to 0.5.7 (testcontainers#2966) feat!: log package for consistent output (testcontainers#2979) docs: remove duplicated options in the customisers lists (testcontainers#2989) chore: exclude "modules/k6" from the build (testcontainers#2987) chore: enable var-naming from revive (private vars only) (testcontainers#2978) chore(deps): bump actions/checkout from 4.1.7 to 4.2.2 (testcontainers#2971) chore(deps): bump release-drafter/release-drafter from 6.0.0 to 6.1.0 (testcontainers#2970) chore!: remove variadic arguments from nats ConnectionString (testcontainers#2967) fix(ci): use same condition for sonar steps (testcontainers#2974) fix: return unique modified modules (testcontainers#2973) chore(deps): bump golangci/golangci-lint-action from 6.2.0 to 6.3.0 (testcontainers#2969) chore(ci): run lint in a separate build before running the tests (testcontainers#2876) fix(deps): update to github.com/shirou/gopsutil/v4 (testcontainers#2964) fix(valkey): fix port race (testcontainers#2962) chore(deps): bump golang.org/x/net in /modules/pinecone (testcontainers#2963) chore(deps): bump golang.org/x/net from 0.26.0 to 0.33.0 (testcontainers#2961) deps(fix): include modulegen templates dir in dependabot updates (testcontainers#2956) chore(deps): bump docker/setup-docker-action from 4.0.0 to 4.1.0 (testcontainers#2959) ...
* main: (34 commits) deps: update go version from 1.22.0 to 1.23.0 (testcontainers#2985) feat(redpanda): add bootstrap user account option (testcontainers#2975) chore(ollama): bump default version to 0.5.7 (testcontainers#2966) feat!: log package for consistent output (testcontainers#2979) docs: remove duplicated options in the customisers lists (testcontainers#2989) chore: exclude "modules/k6" from the build (testcontainers#2987) chore: enable var-naming from revive (private vars only) (testcontainers#2978) chore(deps): bump actions/checkout from 4.1.7 to 4.2.2 (testcontainers#2971) chore(deps): bump release-drafter/release-drafter from 6.0.0 to 6.1.0 (testcontainers#2970) chore!: remove variadic arguments from nats ConnectionString (testcontainers#2967) fix(ci): use same condition for sonar steps (testcontainers#2974) fix: return unique modified modules (testcontainers#2973) chore(deps): bump golangci/golangci-lint-action from 6.2.0 to 6.3.0 (testcontainers#2969) chore(ci): run lint in a separate build before running the tests (testcontainers#2876) fix(deps): update to github.com/shirou/gopsutil/v4 (testcontainers#2964) fix(valkey): fix port race (testcontainers#2962) chore(deps): bump golang.org/x/net in /modules/pinecone (testcontainers#2963) chore(deps): bump golang.org/x/net from 0.26.0 to 0.33.0 (testcontainers#2961) deps(fix): include modulegen templates dir in dependabot updates (testcontainers#2956) chore(deps): bump docker/setup-docker-action from 4.0.0 to 4.1.0 (testcontainers#2959) ...
What does this PR do?
Implements solution for #2977
Why is it important?
Prepares the codebase for moving the logger to a new client, moving the interface and implementations behind
testcontainers/log. It also silences some of the identified leaking logs in thewaitpackage.How does it fix the issue?
Loggerinterface and implementations to its own packagetestcontainers/loglog.Default()) or set (log.SetDefault(logger)) the default loggerwaitpackage which was using the standardlogpackage previously and leaking logs to STDOUT