Commit graph

4881 commits

Author SHA1 Message Date
Evan Boyle 4261b27a5e
fix propagation of secrets for resource inputs/outputs in go sdk (#4387) 2020-04-13 22:48:36 -07:00
Pat Gavlin 51588ede49
Fix various printing issues. (#4378)
- Parentheses were not handled properly
- Literals inside of template control sequences were not handled
  properly

These changes also improve test coverage for the printers.
2020-04-13 19:11:56 -07:00
Praneet Loke 931da8f109
[codegen/docs] Fix Kubernetes resource links for NodeJS and C# constructor params (#4384)
* Fix k8s input type links for constructor args.

* Skip using property case maps for k8s Python.

* Fix the namespace of C# constructor args type and resource type.
2020-04-13 17:27:38 -07:00
Erin Krengel 562d1298f2
fix link to be lowercase (#4382) 2020-04-13 15:48:36 -07:00
stack72 b5b0fa0136 Prepare for v1.14.1 release 2020-04-13 22:51:31 +01:00
Evan Boyle 9d2f40b686
fix unknown status for secrets wrapping unknowns (#4377)
* fix unknown status for secrets wrapping unknowns

* changelog

* add test for secret computed values
2020-04-13 22:47:08 +01:00
Evan Boyle 4bbddafe6c
update remote path for policy pack template tests (#4381) 2020-04-13 14:02:17 -07:00
Paul Stack f09a14cfa8
Merge pull request #4372 from pulumi/adding-dotnet-system-namspace
Adding system namespace for Dotnet code gen
2020-04-12 22:18:47 +01:00
stack72 69c804a4e7 Adding system namespace for Dotnet code gen
This is required for using Obsolute attributes for deprecations

```
Iam/InstanceProfile.cs(142,10): error CS0246: The type or namespace name 'ObsoleteAttribute' could not be found (are you missing a using directive or an assembly reference?) [/Users/stack72/code/go/src/github.com/pulumi/pulumi-aws/sdk/dotnet/Pulumi.Aws.csproj]
Iam/InstanceProfile.cs(142,10): error CS0246: The type or namespace name 'Obsolete' could not be found (are you missing a using directive or an assembly reference?) [/Users/stack72/code/go/src/github.com/pulumi/pulumi-aws/sdk/dotnet/Pulumi.Aws.csproj]
```
2020-04-12 21:37:52 +01:00
Mikhail Shilkov d3e7041c0d
Support the binary option for .NET (#4355)
Support the binary option for .NET
2020-04-12 21:34:50 +02:00
Evan Boyle fe7877177c
fix stack reference helpers to handle nil values (#4370) 2020-04-12 08:44:08 -07:00
Evan Boyle 779c4144f9
Properly propagate unknowns in go SDK marshaling operations (#4369) 2020-04-11 22:20:03 -07:00
Praneet Loke 563233d16c
[codegen/docs] Use the correct module names for languages. (#4367)
* Use the correct module names for languages.

* Add Kubernetes to the title lookup map.

* Add output properties to the map only if filtered output properties is non-zero length.
2020-04-10 18:28:14 -07:00
Sean Holung f28bf6acf5
Remove input props from output properties list (#4360)
* Remove input properties from displaying in output props list
2020-04-10 16:12:05 -07:00
Praneet Loke 729ae08c9d
Handle k8s cases in the resource doc generator (#4337)
* Add a check for the Python code gen to prevent infinte recursion. Remove the custom logic for k8s for generating Python property case maps.

* Fix bug with C# links for k8s constructor resources.

* Apply a style on the deprecation message.

* Use the display name when rendering a property type that does not have a link.

* Fix the python type string generator for docs to inspect union types.

* Update cleanTypeString to account for nodejs package names.

* Add missing lookup names for packages.
2020-04-10 14:07:52 -07:00
Justin Van Patten 938e25164c
Update @pulumi/policy dependency (#4362) 2020-04-10 11:25:58 -07:00
Harrison Heck 01d22680d9 fix: error when setting config without value in non-interactive mode 2020-04-10 19:23:32 +01:00
Harrison Heck 5dd669168b fix: remove --show-* as persistent flags 2020-04-10 17:01:12 +01:00
Harrison Heck 7f3ea52202 fix: logging out with filestate when url is deleted 2020-04-10 15:02:24 +01:00
Harrison Heck 43d310ee6d fix: up with refresh with targets not limiting refresh 2020-04-10 15:00:54 +01:00
Pat Gavlin 71aa0f020f
Fix treatment of trivia in template expressions. (#4352)
And improve test coverage for the same.
2020-04-09 16:37:52 -07:00
Evan Boyle c3b2439094
Automate execution of go mod download for pulumi new Go templates (#4353) 2020-04-09 16:16:10 -07:00
Sean Holung 9cd7d7c5c0
Group required resource properties at top of list (#4351) 2020-04-09 15:57:17 -07:00
Justin Van Patten 8c065b34ff
Remove unnecessary import (#4350) 2020-04-09 14:13:16 -07:00
Evan Boyle cfea357cda
Add runtime.options.binary to Pulumi.yaml to make prebuilt go binaries opt-in (#4338) 2020-04-09 12:21:26 -07:00
Paul Stack ec9eba63ba
Merge pull request #4345 from nesl247/patch-2
feat: use node 12 in docker image
2020-04-09 20:16:06 +01:00
Sean Holung 7a2f020d2e
Map display names for API Reference TOC menu (#4339) 2020-04-09 09:43:38 -07:00
Evan Boyle 7382de6b5f
Add Go SDK stack output helpers for String and ID (#4341) 2020-04-09 07:52:34 -07:00
Harrison Heck 5c912e4427
feat: use node 12 in docker image
Fixes #4344
2020-04-09 10:48:50 -04:00
Mikhail Shilkov 46dababc28
Add additional RunAsync overloads (#4286) 2020-04-09 16:43:43 +02:00
Levi Blackstone ca6e47277f
Handle const values in Go codegen (#4311) 2020-04-08 10:33:01 -06:00
Pat Gavlin e9d8ccd0cc
Move pulumi cmd sources into cmd/pulumi. (#4324)
Just what it says on the tin.
2020-04-07 15:53:20 -07:00
Evan Boyle f50fd69c10
Define merge behavior for go resource options (#4316) 2020-04-07 14:19:33 -07:00
Praneet Loke efaa026196
Make sure there is a new-line between the package description and the first header on the index page. (#4312) 2020-04-07 12:27:35 -07:00
Paul Stack e7448050c6
Merge pull request #4323 from pulumi/fix-go111module-on-windows
Fixup GO111MODULE on Windows
2020-04-07 20:22:12 +01:00
Mikhail Shilkov 1d171dbb74
Add Output.All overloads (#4321)
Add Output.All overloads
2020-04-07 20:51:05 +02:00
stack72 9348728648 Fixup GO111MODULE on Windows 2020-04-07 19:37:28 +01:00
Pat Gavlin 00f1433706
HCL2/NodeJS: fix proxy apply lowering for promises (#4317)
Applies cannot be proxied when the applied value is a promise.

Fixes #4315.
2020-04-07 09:25:50 -07:00
Pat Gavlin 2f22c1c59c
HCL2 updates (#4309)
Pulumi HCL2 IR:
- Add support for invokes
- Add support for resource options, incl. ranged resources
- Allow the apply rewriter to ignore promise-typed values
- Add tests for the binder
- Add support functions for TF: entries and range

NodeJS codegen:
- Simplify for expression codegen
- Add support for invoke codegen
- Add support for entries and range functions
- Add tests

Python codegen:
- Implement codegen for most expression types
- Add support for invoke codegen
- Add tests
2020-04-06 19:43:16 -07:00
Praneet Loke 50e1086124 Make sure there is a new-line between the package description and the first header on the index page. 2020-04-06 17:43:21 -07:00
Praneet Loke 22aeaa43b1
Move resource docs index file generation to Go templates (#4308)
* Add new templates for generating index files. Remove the now irrelevant code.

* Add comment for generating index files by deduping module names. Use the path format of a module name as the link.

* Add a trailing slash for module links in the index page.

* Move the categories rendered in the index file into their own template file. Handle kubernetes provider specific module name conversion while generating parent modules.

* Fix issue with the k8s provider resource being generated as a module rather than a resource on the package-level index page.

* Show the deprecation message of a resource at the top of the document.

* Move k8s specific things to its own file.

* Add title attribute to the list items. Show the last part of a module name, in case it contains path separators

* Lookup the package name from the Go language info object for k8s then use that to lookup the C# namespace.

* Move the logic for cleaning a property type string for display names to a separate function.

* Export the title function from go and dotnet code generators for use in the resource doc generator. Use the title function from the respective lang code gens to match the correct title case used there. Fix issue with the Kubernetes namespace not being stripped for C# property type strings.

* Skip including apiVersion and kind as input properties for Kubernetes until pulumi-kubernetes#1062 is merged.
2020-04-06 17:01:33 -07:00
Levi Blackstone d363be9de0
Propagate additionalSecretOutputs opt to Read in NodeJS (#4307) 2020-04-06 15:50:52 -06:00
Evan Boyle ab659aa0c1
Reimplement getRequiredPlugins for go sdk (#4297) 2020-04-06 12:30:40 -07:00
Lee Zen 4862d73186
Do not show the update version warning with --json flag (#4255)
Co-authored-by: Lee-Ming Zen <lee@pulumi.com>
2020-04-03 14:52:53 -07:00
Praneet Loke ea383991f2
Update resource docs generator to handle some k8s cases (#4270)
* Fix an issue with stripping the module name from type doc links in nodejs.

* Remove unused code that visited object types. Update the nested types code to account for types that may reference themselves. Added glog logging statements. Save the package-level language info objects, so we can use them later.

* Check if a type token has already been added as an input or an output type when collecting nested types.

* Rename appearsIn to typeUsage.

* Scan provider resource also using the special-case function if package is k8s.

* Simplify the display names for Pulumi types by removing the Pulumi prefix.
2020-04-03 11:26:52 -07:00
Mikhail Shilkov 6d32d575e0
Enable features in mock monitor (#4272) 2020-04-03 08:33:40 +02:00
Pat Gavlin b02a84b8d9
Add a code generator for Python programs. (#4285)
This code generator processes a bound Pulumi program represented using
an HCL2-based IR and converts it to an equivalent Python program.
2020-04-02 23:29:05 -07:00
Pat Gavlin 4ae2867a15
Add a code generator for NodeJS programs. (#4284)
This code generator processes a bound Pulumi program represented using
an HCL2-based IR and converts it to an equivalent NodeJS program.
2020-04-02 23:27:05 -07:00
Pat Gavlin 27ac065fdc
Add a package for binding HCL2 as Pulumi config. (#4105)
* Add a package for binding HCL2 as Pulumi config.

These changes add preliminary (read: incomplete) support for
representing Pulumi programs using HCL2. Language-specific code
generators can use this representation as a basis for understanding the
semantics of a Pulumi program.

* Appease the linter

* Updates to the Pulumi HCL2 projection

- config variables are now specified as `config <name> <type>`
- output variables are now specified as `output <name> <type>`
- apply arguments are assigned better names by the apply rewriters

* Update package references

* Appease the linter

* Remove an unused import
2020-04-02 22:36:13 -07:00
Mikhail Shilkov 0bce094dc1
Fix python mock's call (#4274)
Fix python mock's call
2020-04-03 07:28:52 +02:00