pulumi/pkg
bors[bot] 91a1a2d586
Merge #13126
13126: Make convert errors more clear to users r=Zaid-Ajaj a=Frassle

<!--- 
Thanks so much for your contribution! If this is your first time contributing, please ensure that you have read the [CONTRIBUTING](https://github.com/pulumi/pulumi/blob/master/CONTRIBUTING.md) documentation.
-->

# Description

<!--- Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. -->

Fixes https://github.com/pulumi/pulumi/issues/13093

This makes two changes to how we print diagnostics in convert. Firstly if program generation returns any warning diagnostics we only print those if either PULUMI_DEV is true, or if we're output pcl (which is always dev-focused).
Secondly if we have any error diagnostics we print an error similar to the panic handler making trying to make it very clear to the user that the error is a bug. We disable this message if using --strict as in that case while there may still be codegen errors that really are bugs there will also be many PCL errors that should be errors when converting with --strict set.

## Checklist

- [x] I have run `make tidy` to update any new dependencies
- [x] I have run `make lint` to verify my code passes the lint check
  - [ ] I have formatted my code using `gofumpt`

<!--- Please provide details if the checkbox below is to be left unchecked. -->
- [ ] I have added tests that prove my fix is effective or that my feature works
<!--- 
User-facing changes require a CHANGELOG entry.
-->
- [ ] I have run `make changelog` and committed the `changelog/pending/<file>` documenting my change
<!--
If the change(s) in this PR is a modification of an existing call to the Pulumi Cloud,
then the service should honor older versions of the CLI where this change would not exist.
You must then bump the API version in /pkg/backend/httpstate/client/api.go, as well as add
it to the service.
-->
- [ ] Yes, there are changes in this PR that warrants bumping the Pulumi Cloud API version
  <!-- `@Pulumi` employees: If yes, you must submit corresponding changes in the service repo. -->


Co-authored-by: Fraser Waters <fraser@pulumi.com>
Co-authored-by: Zaid Ajaj <zaid.naom@gmail.com>
2023-06-12 11:48:40 +00:00
..
authhelpers make linter happy 2023-02-08 10:30:10 -08:00
backend Merge #12856 2023-06-01 17:10:29 +00:00
cmd/pulumi Merge #13126 2023-06-12 11:48:40 +00:00
codegen [programgen/dotnet,go] Implement singleOrNone intrinsic 2023-06-11 16:23:33 -07:00
engine Consolidated Target parameters 2023-06-08 08:42:03 -07:00
graph all: Assert => Assertf 2023-03-03 14:37:43 -08:00
importer all: Reformat with gofumpt 2023-03-03 09:00:24 -08:00
operations all: Reformat with gofumpt 2023-03-03 09:00:24 -08:00
resource Consolidated Target parameters 2023-06-08 08:42:03 -07:00
secrets Change secret.Manager State to json.RawMessage 2023-05-22 11:21:15 +01:00
testing/integration Fix failure to load Pulumi.yaml when RelativeWorkDir provided. 2023-04-26 16:14:46 -04:00
util Hardcode some known provider plugin locations 2023-05-24 17:41:12 +01:00
version duplicate version to ensure linking is properly handled 2020-03-19 12:49:34 -07:00
workspace Allow mapping requests to install plugins 2023-05-29 14:53:04 +01:00
README.md export codegen tests for internal use (#8928) 2022-02-07 12:10:04 +01:00
go.mod chore: post-release go.mod updates 2023-06-08 20:42:55 +00:00
go.sum Upgraded pulumi-java go dependency to v0.9.4 2023-06-07 14:53:14 -07:00

README.md

pulumi/pkg

While pulumi/sdk maintains strict backwards compatibility guarantees, code under pkg/ is handled more informally: while breaking changes are still discouraged they may happen when they make sense.