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

Disable docker node warnings to prevent futzing of docker output #1459

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Ekrekr
Copy link
Contributor

@Ekrekr Ekrekr commented Feb 15, 2023

This was putting

(node:25544) NOTE: The AWS SDK for JavaScript (v2) will be put into maintenance mode in 2023.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check the migration guide at https://a.co/7PzMCcy
(Use `node --trace-warnings ...` to show where the warning was created)

in the output - fine for most things, but could break workflows using things like --json

Fixes #1458

@Ekrekr Ekrekr requested a review from BenBirt February 15, 2023 11:03
@BenBirt
Copy link
Collaborator

BenBirt commented Feb 15, 2023

So obviously this works for users who use the Docker image, but what about the CLI more generally? Can we explore capturing the warning more generically, for example with https://nodejs.org/api/process.html#event-warning?

@Ekrekr
Copy link
Contributor Author

Ekrekr commented Feb 15, 2023

I can't get this to work atm, require seems to operate in a different scope to what's currently running

const snowflake = require("snowflake-sdk/lib/core")({

Can see what would otherwise work in the bundle
image

@BenBirt
Copy link
Collaborator

BenBirt commented Feb 15, 2023

I don't really follow, what does the snowflake SDK have to do with it? why can't we add the warning handler before any import happens?

@Ekrekr
Copy link
Contributor Author

Ekrekr commented Feb 15, 2023

process.env.NODE_NO_WARNINGS = "1"; doesn't work either sadly

Will try to bumping our node version

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.

Dataform CLI outputs an AWS SDK message
2 participants