Erik Johnson
9659b19819
salt.serializers.yaml/yamlex: remove invalid multi_constructor
...
The first argument to add_multi_constructor must be a YAML tag. This is
because when PyYAML looks for a constructor to match the tag (in order
to get the function to use for deserialization) it matches the tag using
`.startswith()`. Thus, when this is attempted using a constructor with a
tag value of `None`, an error is raised.
The ordering of the list of multi_constructors in the Loader object
appears to differ from platform to platform, which explains why this
only caused the unit tests to fail on one or two platforms. If a tag
match is found, then PyYAML stops iterating through the list of
multi_constructors, so this invalid one has been able to stay in Salt
without causing any noticeable trouble until now.
2018-05-09 10:48:02 -05:00
Nicole Thomas
85284caaf9
Merge pull request #47550 from pcn/fix-disable-term-protect-in-2018.3
...
Fixes a bad deletion I did that only surfaced in 2018.3
2018-05-09 09:36:32 -04:00
Nicole Thomas
f9083ff77e
Merge pull request #47554 from douglasjreynolds/lxc_unicode_fix
...
Converted unicode str version to a LooseVersion; matching line 2080.
2018-05-09 09:34:13 -04:00
Nicole Thomas
fe4e79f1de
Merge pull request #47518 from Ch3LL/zfs_support
...
Fix 47364: ensure we are not caching zfs.is_supported
2018-05-09 09:29:06 -04:00
Doug Reynolds
e6bce581c6
Converted unicode str version to _LooseVersion to match line 2080.
2018-05-08 23:36:35 -04:00
Peter C. Norton
d58a56877c
Fixes a bad deletion I did that only surfaced in 2018.3
2018-05-08 17:51:18 -04:00
Nicole Thomas
332e9f13a6
Merge pull request #47159 from terminalmage/whitelist_blacklist-iter-fix
...
Fix for whitelist/blacklist checking for non-list iterables
2018-05-08 16:43:50 -04:00
Nicole Thomas
21809ddc02
Merge pull request #47514 from rallytime/merge-2018.3
...
[2018.3] Merge forward from 2017.7 to 2018.3
2018-05-08 14:36:53 -04:00
Ch3LL
d19fef963e
remove unnecessary patch in zfs.is_supported test
2018-05-08 12:14:37 -04:00
Erik Johnson
ca936de372
Treat empty whitelist/blacklist as no whitelist/blacklist
2018-05-08 10:24:21 -05:00
rallytime
e2616b605f
Update the pip tests to use the parsing syntax generated in PR #47196
2018-05-08 10:42:14 -04:00
rallytime
b13b59791f
Remove double instance of adding --format=json
in pip module
...
Due to the merge forward, the `--format=json` block in the `list_upgrades`
function was being added twice. This was caught by a unit test. This commit
fixes this error by removing one of the blocks that adds the `--format=json`
option when pip is >= 9.0.
2018-05-08 10:40:34 -04:00
Erik Johnson
bcccaf2621
Raise a TypeError when invalid input passed to check_whitelist_blacklist
2018-05-08 09:30:23 -05:00
Erik Johnson
2ae510ff2b
Fix comment in test
2018-05-08 09:30:23 -05:00
Erik Johnson
17398efcf7
Fix for whitelist/blacklist checking for non-list iterables
...
A recent PY3-compatibility fix was made to `check_whitelist_blacklist`.
The function was previously checking for the `__iter__` attribute to
check if the blacklist and/or whitelist was a sequence of expressions
or a single expression. However, the `str` type has the `__iter__`
attribute in PY3 while it does not in PY2. To fix this, the check was
changed to see if the blacklist and/or whitelist were `list` types. This
however causes problems in `salt.daemons.masterapi` when we pass `set`
types.
To fix this, we just check if the whitelist and/or blacklist are string
types, rather than that they are _not_ some sort of sequence type.
2018-05-08 09:30:21 -05:00
Nicole Thomas
9559ac7679
Merge pull request #47516 from rallytime/bp-47505
...
Back-port #47505 to 2018.3
2018-05-08 09:32:32 -04:00
Nicole Thomas
bf79acfbc8
Merge pull request #47515 from rallytime/bp-47503
...
Back-port #47503 to 2018.3
2018-05-08 09:32:02 -04:00
Daniel Wallace
779b3ed056
Merge pull request #47531 from gtmanfred/2018.3
...
add ssh config doc for rosters
2018-05-07 17:26:29 -05:00
Daniel Wallace
92ded7162c
add ssh config doc for rosters
2018-05-07 17:25:38 -05:00
Nicole Thomas
95b2f9db30
Merge pull request #47520 from rallytime/cleanup-spaces
...
Cleanup weird spaces
2018-05-07 15:50:57 -04:00
rallytime
2ad60c7e81
Lint: remove duplicate function in helpers.py
2018-05-07 15:45:30 -04:00
Shane Lee
05fc52f124
Merge pull request #47495 from dwoz/uninstall_wart
...
Fix crufty nssm.exe reference
2018-05-07 13:12:48 -06:00
Shane Lee
caa36c9064
Merge branch '2018.3' into uninstall_wart
2018-05-07 13:12:11 -06:00
Nicole Thomas
3cc7d3ae7c
Merge pull request #47494 from ejparker12/fix-lxc-clone
...
Fixed lxc.clone unhandled exception in salt/modules/lxc.py
2018-05-07 15:03:58 -04:00
Nicole Thomas
adde83f639
Merge pull request #47497 from mateiw/2018.3-fix-ssh-extra-files-refs-issue-47496
...
Fix salt-ssh --extra-filerefs to include files even if no refs in states to apply
2018-05-07 15:02:49 -04:00
rallytime
e9cb080a00
Cleanup weird spaces
...
Some spaces between the `@` and the `skipIf` snuck into the branch
and the linter, nor the tests, caught this for some reason.
2018-05-07 14:51:39 -04:00
Erik Johnson
34b1b1ee53
Merge pull request #47441 from shengis/fix-run-env-reset
...
Fix _run to reset LANGUAGE env variable
2018-05-07 13:29:24 -05:00
Daniel A. Wozniak
7c60e4071e
Raise proper invocation errors
2018-05-07 13:57:53 -04:00
Ch3LL
58c4f29f96
Fix 47364: ensure we are not caching zfs.is_supported
2018-05-07 13:55:21 -04:00
Peter Sagerson
821dbb88a0
Fix #47502 : Remove an extraneous (accidentally introduced?) call to rstrip.
2018-05-07 13:43:10 -04:00
Nicole Thomas
17cfd4f7cf
Merge pull request #47507 from gtmanfred/2018.3
...
fix win_task for py3
2018-05-07 13:41:20 -04:00
rallytime
75480158b3
Lint: cur_version should just be pip_version
2018-05-07 13:37:32 -04:00
rallytime
5565d5e9b1
Update old utils paths with new utils paths
2018-05-07 13:36:47 -04:00
rallytime
786076ac03
Merge branch '2017.7' into '2018.3'
...
Conflicts:
- pkg/windows/modules/get-settings.psm1
- salt/modules/cmdmod.py
- salt/modules/pip.py
- salt/modules/win_lgpo.py
- salt/states/pip_state.py
- tests/integration/states/test_pip.py
- tests/support/helpers.py
- tests/unit/modules/test_pip.py
- tests/whitelist.txt
2018-05-07 13:17:01 -04:00
Mike Place
62fc16b721
Merge branch '2018.3' into fix-run-env-reset
2018-05-07 08:58:16 -05:00
Mike Place
a4c2df8fb2
Merge pull request #47472 from terminalmage/hashutils
...
salt.utils.hashutils: Fix UnicodeEncodeError in several funcs
2018-05-07 08:31:06 -05:00
Daniel Wallace
19db39f402
fix win_task for py3
...
.keys() on python3 creates a dict_keys object which cannot be indexed like a
list, if we just call list() on the dictionary we get a list of keys.
2018-05-07 08:11:52 -05:00
Daniel Wallace
8b0a370189
Merge pull request #47485 from gtmanfred/2018.3
...
add openstack modules to doc index.rst
2018-05-07 08:11:41 -05:00
Daniel Wallace
c86163d79f
add openstack modules to doc index.rst
2018-05-07 08:11:08 -05:00
Matei Albu
d67239aae7
--extra-filerefs include files even if no refs in states to apply
...
Fixes #47496
2018-05-06 12:04:48 +02:00
Daniel A. Wozniak
3557fc5fa6
Fix crufty nssm.exe reference
2018-05-05 22:32:05 -07:00
Beth Parker
e0e2c9782d
Fixed lxc.clone unhandled exception in salt/modules/lxc.py
...
Fixes #47322
2018-05-05 23:08:15 -05:00
Nicole Thomas
8df37f734a
Merge pull request #47482 from gtmanfred/2018.3
...
add all autodoc for new salt openstack modules
2018-05-04 17:03:37 -04:00
Daniel Wallace
611ca1fc03
Merge pull request #47476 from gtmanfred/2017.7
...
Specify the cache directory for newer virtualenv modules
2018-05-04 14:20:44 -05:00
Daniel Wallace
1f91a85587
specify cache dir for pip install
2018-05-04 12:48:52 -05:00
Nicole Thomas
7c3f2c56da
Merge pull request #47412 from twangboy/fix_47125
...
Fix issue where the cwd was being removed
2018-05-04 13:28:10 -04:00
Nicole Thomas
4846e957c4
Merge pull request #47467 from twangboy/cleanup_settings
...
Remove unused settings, update NSIS
2018-05-04 13:11:37 -04:00
Daniel Wozniak
d20ca15c5d
Merge pull request #47447 from dwoz/strv
...
Fix failing test due to windows console encoding
2018-05-04 09:41:29 -07:00
Erik Johnson
7266c9984d
salt.utils.hashutils: Fix UnicodeEncodeError in several funcs
...
Many funcs in this module only convert the input to bytes on Python 3
because the hashing and base64-encoding funcs used in this module
require bytes as input. However, on Python 2, to get bytes the input
will be coerced to a str type if it is a unicode type. This will result
in a UnicodeEncodeError when the unicode string contains non-ascii
characters.
This commit ensures that all input which is going to be encoded/hashed
is converted to a bytes type first, and also ensures that all
base64-encoded results are returned as a unicode string on Python 2 to
conform with changes that have been made in 2018.3 to use unicode types
where possible.
2018-05-04 11:13:29 -05:00
Daniel Wozniak
8c5b30b541
Merge pull request #47466 from dwoz/randbytes
...
bytes file that decodes the same utf-8 and cp1252
2018-05-04 08:54:23 -07:00