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

[auto/python] - Fix a bug in printing stack. #8032

Merged
merged 2 commits into from
Sep 22, 2021
Merged

Conversation

komalali
Copy link
Member

@komalali komalali commented Sep 22, 2021

Description

This repro'd with print(stack) in a local program so I added that to the test.

Checklist

  • I have added tests that prove my fix is effective or that my feature works
  • Yes, there are changes in this PR that warrants bumping the Pulumi Service API version

@komalali komalali requested review from justinvp, t0yv0 and a team and removed request for justinvp September 22, 2021 22:42
@pgavlin
Copy link
Member

pgavlin commented Sep 22, 2021

This repro'd with print(stack) in a local program so I added that to the test.

What exactly was the issue? Did print(stack) throw?

@komalali
Copy link
Member Author

@pgavlin Yes, print(stack) threw for local programs because the __repr__ function was looking for the program's name without checking if there was a program at all: https://github.com/pulumi/pulumi/pull/8032/files#diff-333d7645bb6845c14765cb4e3f3fac2b0fbe65587203a09cf07d5170e17ac2dfL104

Copy link
Member

@pgavlin pgavlin left a comment

Choose a reason for hiding this comment

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

LGTM

sdk/python/lib/test/automation/test_local_workspace.py Outdated Show resolved Hide resolved
@komalali komalali changed the title [auto/python] - Fix a bug in printing stack when no program is provided. [auto/python] - Fix a bug in printing stack. Sep 22, 2021
@komalali komalali merged commit 212ac89 into master Sep 22, 2021
@komalali komalali deleted the komalali/fix-auto-bug branch September 22, 2021 23:49
@emiliza emiliza added kind/bug Some behavior is incorrect or out of spec size/S Estimated effort to complete (1-2 days). labels Sep 23, 2021
@emiliza emiliza added this to the 0.62 milestone Sep 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec size/S Estimated effort to complete (1-2 days).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants