Merge branch 'release/0.16' into ellismg/merge-release
This commit is contained in:
commit
6e95bdda9c
|
@ -1,10 +1,16 @@
|
|||
|
||||
## 0.16.5 (unreleased)
|
||||
## 0.16.6 (Unreleased)
|
||||
|
||||
### Improvements
|
||||
|
||||
- Fix an issue where running two copies of `pulumi plugin install` in parallel for the same plugin version could cause one to fail with an error about renaming a directory.
|
||||
|
||||
## 0.16.5 (Released Novemeber 16th, 2018)
|
||||
|
||||
### Improvements
|
||||
|
||||
- Fix an issue where `pulumi plugin install` would fail on Windows with an access deined message.
|
||||
|
||||
## 0.16.4 (Released Novemeber 12th, 2018)
|
||||
|
||||
### Major Changes
|
||||
|
|
|
@ -154,7 +154,9 @@ func (info PluginInfo) Install(tarball io.ReadCloser) error {
|
|||
contract.IgnoreError(os.RemoveAll(tempDir))
|
||||
}()
|
||||
|
||||
// Unzip and untar the file as we go.
|
||||
// Unzip and untar the file as we go. We do this inside a function so that the `defer`'s to close files happen
|
||||
// before we later try to rename the directory. Otherwise, the open file handles cause issues on Windows.
|
||||
err = (func() error {
|
||||
defer contract.IgnoreClose(tarball)
|
||||
gzr, err := gzip.NewReader(tarball)
|
||||
if err != nil {
|
||||
|
@ -194,6 +196,12 @@ func (info PluginInfo) Install(tarball io.ReadCloser) error {
|
|||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
})()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// If two calls to `plugin install` for the same plugin are racing, the second one will be unable to rename
|
||||
// the directory. That's OK, just ignore the error. The temp directory created as part of the install will be
|
||||
// cleaned up when we exit by the defer above.
|
||||
|
|
|
@ -215,13 +215,12 @@ func TestStackOutputsJSON(t *testing.T) {
|
|||
e.RunCommand("pulumi", "login", "--cloud-url", e.LocalURL())
|
||||
e.RunCommand("pulumi", "stack", "init", "stack-outs")
|
||||
e.RunCommand("pulumi", "up", "--non-interactive", "--skip-preview")
|
||||
stdout, stderr := e.RunCommand("pulumi", "stack", "output", "--json")
|
||||
stdout, _ := e.RunCommand("pulumi", "stack", "output", "--json")
|
||||
assert.Equal(t, `{
|
||||
"foo": 42,
|
||||
"xyz": "ABC"
|
||||
}
|
||||
`, stdout)
|
||||
assert.Equal(t, "", stderr)
|
||||
}
|
||||
|
||||
// TestStackOutputsDisplayed ensures that outputs are printed at the end of an update
|
||||
|
|
Loading…
Reference in a new issue