Commit graph

5899 commits

Author SHA1 Message Date
Mikhail Shilkov 58367044d4
Merge pull request #6915 from gitfool/gh6914
[auto/dotnet] Bump YamlDotNet to 11.1.1
2021-04-30 22:06:44 +02:00
Sean Fausett 92dd696dda Bump YamlDotNet to 11.1.1
https://github.com/aaubry/YamlDotNet/releases/tag/v11.1.1
2021-05-01 08:03:12 +12:00
Justin Van Patten 8574d40dda
[sdk/python] Fix type-related regression on Python 3.6 (#6942)
Pulumi 3.0 uses type annotations for input values to determine whether dict keys should be translated from snake_case to camelCase or not. This additional inspection of types did not work correctly on Python 3.6 due to some missing functionality on that version of Python which we need to provide an implementation for. Specifically, when inspecting `Union` args to determine whether or not a value is intended to be an input class or user-defined dict. To address the issue, this change improves how we get the args for `Union` types when running on Python 3.6 to behave the same way as later versions of Python (for our purposes). Existing tests fail on Python 3.6 before this change, and pass after.
2021-04-30 11:50:42 -07:00
Komal 210c16b67a
Update PULL_REQUEST_TEMPLATE.md (#6940) 2021-04-30 11:12:05 -07:00
Justin Van Patten 69d50ced27
[sdk/python] Address issues when using resource subclasses (#6890)
We were only looking at the current resource class's type/name metadata for camelCase <=> snake_case property name translations which prevented it from working correctly when using a subclass of a resource. This change addresses this by looking at metadata of the current class and any base classes.

Additionally, to help resolve forward references when getting type hints, we'd pass along the current resource class's globals, which doesn't work correctly when using a subclass of a resource. This change also addresses this, by using the globals of the current class and any base classes.
2021-04-30 10:07:23 -07:00
James Nugent 71fcbfce5f
[kind/bug] [automation/go]: Look in workspace options for version optout (#6938)
When calling l.GetEnvVars() to evaluate whether version checking should
be skipped because of variables passed into the workspace, they have not
yet been set. This commit modifies the logic to look at the environment
variables in the options instead of in the workspace.

Since the original functionality  has not yet been released, I do not
believe it warrants a CHANGELOG entry.
2021-04-30 09:41:31 -07:00
Evan Boyle c3dc2d54ab
Add user agent to the CLI, Go and Nodejs Automation API SDKs (#6935) 2021-04-30 07:26:23 -07:00
James Nugent 93d7057f80
[codegen/go] Respect baseImportPath in Go SDKs (#6866)
If `rootPackageName` is set, we can look for the version in the
baseImportPath rather than at a location based on the package name -
which currently fails if every component is not named `pulumi-*`. To err
on the side of caution, this method is only used for packages where
`rootPackageName` is set, meaning existing SDKs retain their current
behavior.

The new behavior is confirmed via the test added in #6862.
2021-04-29 17:09:05 -06:00
Komal b655f0bc23
Proposal: PULL_REQUEST_TEMPLATE.md (#6885) 2021-04-29 13:21:36 -07:00
Anton Tayanovskyy 6f1ea08993
Import subpackages lazily (#6827)
* Import subpackages lazily

* Tighten up lazy_import impl

* Eagerly register resources, but lazily load their impl

* Add CHANGELOG entry

* Satisfy lint

* Restore mypy behavior so the change is not breaking

* Fix golden tests
2021-04-29 16:08:22 -04:00
Komal bdcb5ecb3c
[automation/go] - Improve default formatting of auto.autoError (#6924)
Co-authored-by: James Nugent <jen20@apple.com>
2021-04-29 13:04:51 -07:00
James Nugent f73ec2fc71
[codegen/go] Permit production of flat Go packages (#6862)
When working in a monorepo environment, it can be desirable to generate
Go SDKs into a structure less like the upstream SDKs, and more like
this:

github.com/x/mymonorepo/sdk/go/package-name

Where `package-name` is also the root of a Go module. Since
`package-name` is not a valid package name in Go, it's also desirable to
be able to choose a replacement name and reduce the amount of nesting.

This commit adds a new Go option to the schema, `rootPackageName`, which
can be used to modify the generated root package name (e.g. to
`mypackage` instead of `package-name`, and remove the additional layer
of nesting.

Test coverage is added to ensure that the correct file structure and
package names are generated.
2021-04-29 13:30:01 -06:00
Paul Stack 0739fa396d
[cleanup] Small stylistic changes to NewPassphaseSecretsManagerFromState (#6909)
This incorporates some post merge feedback from https://github.com/pulumi/pulumi/pull/6893

This doesn't change the functionality of any of the tests:

```
go test -v ./secrets/passphrase -count=1
=== RUN   TestPassphraseManagerIncorrectPassphraseReturnsErrorCrypter
--- PASS: TestPassphraseManagerIncorrectPassphraseReturnsErrorCrypter (0.89s)
=== RUN   TestPassphraseManagerIncorrectStateReturnsError
--- PASS: TestPassphraseManagerIncorrectStateReturnsError (0.00s)
=== RUN   TestPassphraseManagerCorrectPassphraseReturnsSecretsManager
--- PASS: TestPassphraseManagerCorrectPassphraseReturnsSecretsManager (1.08s)
=== RUN   TestPassphraseManagerNoEnvironmentVariablesReturnsError
--- PASS: TestPassphraseManagerNoEnvironmentVariablesReturnsError (0.00s)
PASS
ok  	github.com/pulumi/pulumi/pkg/v3/secrets/passphrase	2.270s
```
2021-04-29 11:37:25 +01:00
Mikhail Shilkov 108fc6655d
Merge pull request #6917 from gitfool/gh6916
[sdk/dotnet] Enable deterministic builds
2021-04-29 11:12:40 +02:00
Sean Fausett 276d3570ed Enable deterministic builds 2021-04-29 14:24:43 +12:00
Vivek Lakshmanan c0b5339cf3
Merge pull request #6901 from pulumi/vl/FixStackSettings
[auto/go] Fix stack settings save/load typo and add tests
2021-04-28 11:35:29 -07:00
Mikhail Shilkov 6100691262
Merge pull request #6905 from gitfool/gh6904
[automation/dotnet] Enable SourceLink with embedded PDB
2021-04-28 13:12:11 +02:00
Mikhail Shilkov d6477b1fc2
Merge pull request #6871 from gitfool/gh6870
[sdk/dotnet] Bump Grpc NuGet packages to 2.37.0
2021-04-28 11:49:26 +02:00
Sean Fausett 28a7e61daf Enable SourceLink with embedded PDB 2021-04-28 21:08:54 +12:00
Vivek Lakshmanan 4b3d2a57c7 [auto/go] Fix stack settings save/load typo and add tests 2021-04-27 22:27:59 -07:00
Komal 1ed3445ed4
[automation/*] - Optionally skip Automation API version check (#6882)
Co-authored-by: James Nugent <jen20@apple.com>
2021-04-27 20:54:27 -07:00
Paul Stack 1640b7a5b1
[cli] Ensure the user has set PULUMI_CONFIG_PASSPHRASE or PULUMI_CONFIG_PASSPHRASE_FILE (#6893)
Fixes: #6286

When a user is using the passphrase provider and unsets the environment
variables that let them interact with the secrets provider, then would
get an error as follows:

```
▶ pulumi up -y -f
error: decrypting secret value: failed to decrypt: incorrect passphrase, please set PULUMI_CONFIG_PASSPHRASE to the correct passphrase
```

We are oging to change this error message to make it more obvious
to a user what the error is and how they need to fix it

```
▶ pulumi up -y -f
error: constructing secrets manager of type "passphrase": unable to find either `PULUMI_CONFIG_PASSPHRASE` nor `PULUMI_CONFIG_PASSPHRASE_FILE` when trying to access the Passphrase Secrets Manager. Please ensure one of these values are set to allow the operation to continue
```

Ideally, we would like to prompt the user for the passphrase at this
point rather than error, but the CLI could be in the middle of an
update operation as the same codepath is used for reading stackreference
values
2021-04-28 01:21:16 +01:00
Simen A. W. Olsen eb2dcf2488
docs: Update Github logo (#6865) 2021-04-27 08:34:05 -07:00
James Nugent 3e3e4f2deb
Permit Go program gen to work with modules at v1 (#6855)
This commit adjusts the way that Go module versions are discovered from
packages when generating Go programs, to account for those on module
version 1. Previously, this function would panic when dereferencing a
nil instance of semver.Version.
2021-04-26 19:19:43 -07:00
Jonas-Taha El Sesiy 837f75f28b
[auto/go] - Provide GetPermalink for all results (#6875) 2021-04-26 18:18:45 -07:00
Ville Penttinen daa6045381
[automation/*] Add support for getting stack outputs using Workspace (#6859) 2021-04-26 16:32:30 -07:00
Ville Penttinen 3cbfddf870
[automation/dotnet] Use stackName in ImportStack (#6858)
Co-authored-by: Komal <komal@pulumi.com>
2021-04-26 15:12:27 -07:00
Ville Penttinen 52fb4c2d68
[automation/dotnet] Fix EventLogWatcher failing to read events after an exception was thrown (#6821)
* [automation/dotnet] Fix EventLogWatcher failing to read events after exception

* Update CHANGELOG_PENDING.md

Co-authored-by: Anton Tayanovskyy <anton@pulumi.com>
2021-04-26 16:31:55 -04:00
Komal 33f403e7c5
Fix python mock args (#6863) 2021-04-26 13:22:10 -07:00
Komal 5dba5227cc
[sdk/python] - Fix python lint errors (#6872) 2021-04-26 08:56:15 -07:00
Evan Boyle f8a9698ca9
remove erroneous global promise rejection handler (#6864) 2021-04-26 08:27:41 -07:00
Sean Fausett 44cc1684fc Bump Grpc NuGet packages to 2.37.0
https://github.com/grpc/grpc/releases/tag/v1.37.0
2021-04-25 16:57:17 +12:00
Komal 288d67d78b
[auto/*] - Bump min version (#6852) 2021-04-22 16:17:49 -07:00
stack72 6ce0a01e2a Cleanup post v3.1.0 release 2021-04-22 21:11:04 +01:00
stack72 5279b1dfcf [deps] Ensuring pulumi/pulumi pkg references pulumi sdk v3.1.0 2021-04-22 19:34:31 +01:00
stack72 8dadcf1dd7 Prepare for v3.1.0 release 2021-04-22 19:33:20 +01:00
Komal f523d25868
[automation/python] - Fix deserialization of UpdateSummary (#6838) 2021-04-22 09:00:12 -07:00
Komal 61ce479241
Re-add [BREAKING] - Standardize stack select behavior (#6300) (#6840)
Co-authored-by: Paul Stack <public@paulstack.co.uk>
2021-04-22 14:10:39 +01:00
Komal f8d0ab8803
Re-add - Set pagination defaults for pulumi stack history to 10 entries (#6739) (#6841)
* Set pagination defaults for `pulumi stack history` to 10 entries (#6739)

* Update changelog

Co-authored-by: Evan Boyle <EvanBoyle@users.noreply.github.com>
2021-04-22 13:52:27 +01:00
Paul Stack 1c80cb534c
Merge pull request #6834 from pulumi/change-pulumi-codegen
Changing the logo reference in the DotNet Codegen to be the new Pulumi logo
2021-04-21 22:57:34 +01:00
Anton Tayanovskyy 13f63e9648
Fix bug in semver usage by enabling typechecking (#6833)
* Fix bug in semver usage by enabling typechecking

* Add CHANGELOG note
2021-04-21 15:48:57 -04:00
stack72 23c6e0318e Changing the logo reference in the DotNet Codegen to be the new Pulumi logo 2021-04-21 20:26:00 +01:00
Paul Stack dbc96206be
Merge pull request #6832 from pulumi/fixup-dotnet-logo
Fixing up Pulumi logo in dotnet package
2021-04-21 19:56:29 +01:00
stack72 6279d7b009 Fixing up Pulumi logo in dotnet package 2021-04-21 18:45:21 +01:00
Paul Stack c3fdc2fba7
Merge pull request #6825 from pulumi/adding-yandex-to-docs 2021-04-21 17:34:17 +01:00
Komal 967cff8550
Remove references to automation api being in alpha (#6828) 2021-04-21 08:44:04 -07:00
Christian Nunciato a952140b34
Update the logo and get-started button (#6824)
* Update the logo

* Update the Get Started button
2021-04-20 17:09:17 -07:00
stack72 fecbee5ca5 Ensuring Yandex is part of the docs title generations 2021-04-21 00:41:37 +01:00
Pat Gavlin 6a33b4b7ee
Distinguish between inputty and plain args types. (#6811)
These changes fix a regression introduced by #6686 that caused the SDK
code generators for .NET, Python, and Typescript to omit definitions for
plain object types. This regression occurred because #6686 drew a
clearer line between types used as resource arguments and types used
as function arguments, but conflated "resource arguments" with "inputty
types". This caused the code generators to generate inputty types for
any types used as resource arguments, even those that are used for
plainly-typed properties.

Fixes #6796.
2021-04-19 16:40:39 -07:00
Levi Blackstone a94892aa2b
[sdk/nodejs] Handle providers for RegisterResourceRequest (#6795)
Resolve providers references and include the resulting refs in the
providers field of RegisterResourceRequest that was added in
d297db3.
2021-04-19 16:41:53 -06:00