counsyl / counsyl/puppet-sys

Timeout default of '0' breaks powershell

Open
#31 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Puppet
Stars
11
Forks
22
PR merge metrics
No merged PRs in 30d

Description

*This is either a puppet-sys issue or a powershell provider issue, unclear*:

with the [recent powershell module fix](https://github.com/puppetlabs/puppetlabs-powershell/pull/321) to support the timeout parameter of `exec`, execution of `sys::fetch` fails with the default `timeout` of `'0'`:

```
Debug: /Stage[main]/Windows::Nssm/Sys::Fetch[download-nssm]/Exec[fetch-download-nssm]/creates: Checking that 'creates' path 'C:\ProgramData\installers\nssm-2.24.zip' exists
Error: Failure waiting for PowerShell process 6044 to start pipe server
Error: /Stage[main]/Windows::Nssm/Sys::Fetch[download-nssm]/Exec[fetch-download-nssm]/returns: change from 'notrun' to ['0'] failed: Failure waiting for PowerShell process 6044 to start pipe server (corrective)
```

**0** should be **unlimited**, but, since it is a string, powershell provider interprets it as a non-false value (my guess). When overriden like this, everything works:

```puppet
Sys::Fetch{
timeout => 120, # a smaller number also works
}
# 0 doesn't seem to work though, unclear why.
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.