Pedro Algarvio
3477300d7f
Add a test case to check for proper env selection when passing ?env=foo
. Refs #8196 .
2013-11-06 22:47:55 +00:00
Pedro Algarvio
943d130e8b
Several PyLint fixes.
2013-11-06 22:44:08 +00:00
Thomas S Hatch
0f149ed23a
Merge pull request #8254 from cachedout/#7691
...
Fix bug preventing minions from unloading custom modules.
2013-11-06 14:40:09 -08:00
Thomas S Hatch
f65d7e46c4
Merge pull request #8251 from heewa/pip_vcs_error_msg
...
Avoid hiding error context in VCS pip install.
2013-11-06 14:37:35 -08:00
Pedro Algarvio
62b7e8c9d1
Add missing commas.
2013-11-06 22:33:01 +00:00
Thomas S Hatch
a343e69d02
Merge pull request #8230 from s0undt3ch/issues/8196-environments
...
Properly pass `__env__` to states.
2013-11-06 14:23:26 -08:00
Pedro Algarvio
8c149be174
It's salt.utils
not salt.util
.
2013-11-06 22:17:50 +00:00
Thomas S Hatch
fdcbbbbf16
Merge pull request #8224 from basepi/includeerror8093
...
Make ambiguous or unknown includes failhard always
2013-11-06 14:14:12 -08:00
Pedro Algarvio
fce52f87ee
Deprecate __env__
in favor of saltenv
2013-11-06 22:04:01 +00:00
Pedro Algarvio
9c493ba0e6
Deprecate __env__
and env
in favor of saltenv
2013-11-06 22:00:51 +00:00
Pedro Algarvio
69c3bf328b
Deprecate __env__
and env
in favor of saltenv
2013-11-06 21:54:53 +00:00
Pedro Algarvio
7601e46825
Deprecate __env__
in favor of saltenv
2013-11-06 21:54:05 +00:00
Thomas S Hatch
efd6579805
Merge pull request #8222 from cro/track_mine_processes
...
Track mine processes, fixes #5729
2013-11-06 13:53:18 -08:00
Thomas S Hatch
1fb7f59700
Merge pull request #8217 from cachedout/file_traversal_fixing
...
File traversal fixing #6928
2013-11-06 13:49:27 -08:00
Pedro Algarvio
b253cfa9d8
Merge pull request #8305 from terminalmage/tests
...
Add CLI arg parser tests
2013-11-06 13:08:23 -08:00
Pedro Algarvio
2869795802
Deprecate __env__
in favor of saltenv
.
...
Formatting fixes.
Additionally support passing the salt environment to the render template function.
2013-11-06 20:56:10 +00:00
Pedro Algarvio
fbfd926fdd
__env__
is now known in the module's global scope.
2013-11-06 20:30:11 +00:00
Pedro Algarvio
1b5e2ff63f
Deprecate passing __env__
in states in favor of saltenv
2013-11-06 20:28:28 +00:00
Pedro Algarvio
2eabe32d0c
Deprecate passing __env__
in states in favor of saltenv
2013-11-06 20:27:53 +00:00
Pedro Algarvio
edda49ae1f
Deprecate passing __env__
in states in favor of saltenv
2013-11-06 20:27:09 +00:00
Pedro Algarvio
155422ff0f
No need to set __env__ = env
since that's done in function globals injection machinery.
2013-11-06 20:23:53 +00:00
Pedro Algarvio
962f8d4149
Support adding files to the testing prod state env.
2013-11-06 20:18:47 +00:00
Pedro Algarvio
9a22d3053e
The pip module no longer accepts __env__
as a kwarg
.
2013-11-06 20:15:23 +00:00
Pedro Algarvio
c516595a27
The salt pip
module no longer accepts __env__
as kwargs
.
...
It simply knows that from it's global scope.
2013-11-06 20:14:41 +00:00
Pedro Algarvio
fc229143d8
Withing the module, __env__
is known.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
4c84b1da3e
State unit tests need to have an hardcoded __env__
.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
56129e3610
Include the holy
directory for the __env__
selection test cases.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
c170d1e572
Updated test cases to include environment selection in states using __env__
.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
f9fca9b809
Accepting __env__
as a keyword argument is no longer required or aceptable
2013-11-06 20:04:54 +00:00
Pedro Algarvio
80916c6698
Deprecated env
as a keyword argument since __env__
is now available within the function's global scope.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
65d42890f2
Deprecated env
as a keyword argument since __env__
is now available within the function's global scope.
2013-11-06 20:04:54 +00:00
Pedro Algarvio
294f32ceab
Accepting __env__
as a keyword argument is no longer required or aceptable
2013-11-06 20:04:54 +00:00
Pedro Algarvio
79734ef8da
Accepting __env__
as a keyword argument is no longer required or aceptable
2013-11-06 20:04:54 +00:00
Pedro Algarvio
a9a0dc319f
Accepting __env__
as a keyword argument is no longer required or aceptable
2013-11-06 20:04:54 +00:00
Pedro Algarvio
2a1bb631a1
Accepting __env__
as a keyword argument is no longer required or aceptable
2013-11-06 20:04:54 +00:00
Pedro Algarvio
1d9e744296
Set the proper __env__
as a function global when calling the state function. Fixes #8196 .
...
To achieve this we're making use of python's `with` context managers.
Initially we check if the user is passing `env` from his state definition. If he his, then that's the `env` to use for as long as the state function is being executed. Passing `env` is also being deprecated, the users should use the more meaningful and unique `__env_`.
If the user passed `__env__` in his state definition, that's the `env` to use, or, if no specific environment is being selected on the users state definition, then the default one, `base` is what will be used.
This change makes it so that **any state module function** does not have to accept `__env__` as a keyword argument.
2013-11-06 20:04:53 +00:00
Pedro Algarvio
f4912bc797
Log the env in use.
2013-11-06 20:04:10 +00:00
Pedro Algarvio
0a03ecc6bc
Add required state file.
2013-11-06 20:04:10 +00:00
Pedro Algarvio
e334e232d1
Forgot to add the top file.
2013-11-06 20:04:10 +00:00
Pedro Algarvio
ec76b188b1
Correctly trigger the issue reported on #8196 .
2013-11-06 20:03:44 +00:00
Pedro Algarvio
2924f1c14a
Add a test case to check for proper env selection when passing ?env=foo
. Refs #8196 .
2013-11-06 20:03:44 +00:00
Erik Johnson
5ef4b31e97
Include more information in test docstrings
...
This adds additional information that describes the relevant code being
tested, so that if there is a problem it is easier to trace it back to
where the problem lies.
2013-11-06 14:03:33 -06:00
Erik Johnson
3c799c0bd5
Add test for arguments with dashes in the arg name
2013-11-06 14:00:02 -06:00
Erik Johnson
f24fb7c26f
Add test for unsupported kwarg
2013-11-06 13:38:30 -06:00
Pedro Algarvio
511e266f6c
Merge pull request #8302 from cachedout/change-log-level-for-acl-user-warning
...
Don't warn non-acl users about logging.
2013-11-06 11:19:52 -08:00
Mike Place
defed3c959
Don't warn non-acl users about logging.
...
This should be moved to debug, per @thatch45.
2013-11-06 11:48:46 -07:00
Pedro Algarvio
10091763f7
Merge pull request #8284 from terminalmage/exceptions-fix
...
Fix improper usage of Salt exception classes
2013-11-06 00:21:42 -08:00
Seth House
98f7fdae86
Merge pull request #8292 from gravyboat/develop
...
Updated minion.rst with a note on verify env for issue 8281.
2013-11-05 22:09:58 -08:00
Forrest Alvarez
a1b4848dbc
Updated minion.rst with a note on verify env for issue 8281.
2013-11-06 05:41:56 +00:00
Seth House
51def00c8f
Merge pull request #8290 from terminalmage/issue8279
...
Fix argument parsing for invalid kwargs
2013-11-05 19:47:59 -08:00