[CT-999] [Bug] In 1.2.0 implictly imported exit
being used instead of sys.exit
#5621
Closed
2 tasks done
Milestone
Is this a new bug in dbt-core?
Current Behavior
In d257d0b, this new bit of code was added,
The
exit(1)
in its current form seems like the wrong thing to do, as per the Python docs,Since
exit
is provided by the implicitly importedsite
, and docs suggest,Expected Behavior
The better thing to do is,
import sys
andsys.exit(1)
Steps To Reproduce
The easiest way to see this fail is with
python -S
and then>>> exit(1)
, this will fail with,Relevant log output
No response
Environment
Which database adapter are you using with dbt?
No response
Additional Context
I'm a bit unsure about how the branching and release process work for dbt-core.
The change is only in the
1.2.latest
branch, not inmain
.Will this change get cherry picked onto
main
? Right now 1.2.0 suffers from this issue onlyThe text was updated successfully, but these errors were encountered: