Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mitogen
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
mitogen
Commits
749eddac
Commit
749eddac
authored
Mar 26, 2018
by
David Wilson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ansible: fix flake8 errors in helpers.py.
parent
2813d1a9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
6 deletions
+13
-6
ansible_mitogen/helpers.py
ansible_mitogen/helpers.py
+13
-6
No files found.
ansible_mitogen/helpers.py
View file @
749eddac
...
...
@@ -35,7 +35,8 @@ import re
import
stat
import
subprocess
import
threading
import
time
import
mitogen.core
# Prevent accidental import of an Ansible module from hanging on stdin read.
import
ansible.module_utils.basic
...
...
@@ -76,7 +77,10 @@ def monkey_exit_json(self, **kwargs):
kwargs
.
setdefault
(
'invocation'
,
{
'module_args'
:
self
.
params
})
kwargs
=
ansible
.
module_utils
.
basic
.
remove_values
(
kwargs
,
self
.
no_log_values
)
kwargs
=
ansible
.
module_utils
.
basic
.
remove_values
(
kwargs
,
self
.
no_log_values
)
self
.
do_cleanup_files
()
raise
Exit
(
kwargs
)
...
...
@@ -91,7 +95,10 @@ def monkey_fail_json(self, **kwargs):
kwargs
.
setdefault
(
'invocation'
,
{
'module_args'
:
self
.
params
})
kwargs
=
ansible
.
module_utils
.
basic
.
remove_values
(
kwargs
,
self
.
no_log_values
)
kwargs
=
ansible
.
module_utils
.
basic
.
remove_values
(
kwargs
,
self
.
no_log_values
)
self
.
do_cleanup_files
()
raise
ModuleError
(
kwargs
.
get
(
'msg'
),
kwargs
)
...
...
@@ -258,9 +265,9 @@ CHMOD_MASKS = {
'a'
:
(
stat
.
S_IRWXU
|
stat
.
S_IRWXG
|
stat
.
S_IRWXO
),
}
CHMOD_BITS
=
{
'u'
:
{
'r'
:
stat
.
S_IRUSR
,
'w'
:
stat
.
S_IWUSR
,
'x'
:
stat
.
S_IXUSR
},
'g'
:
{
'r'
:
stat
.
S_IRGRP
,
'w'
:
stat
.
S_IWGRP
,
'x'
:
stat
.
S_IXGRP
},
'o'
:
{
'r'
:
stat
.
S_IROTH
,
'w'
:
stat
.
S_IWOTH
,
'x'
:
stat
.
S_IXOTH
},
'u'
:
{
'r'
:
stat
.
S_IRUSR
,
'w'
:
stat
.
S_IWUSR
,
'x'
:
stat
.
S_IXUSR
},
'g'
:
{
'r'
:
stat
.
S_IRGRP
,
'w'
:
stat
.
S_IWGRP
,
'x'
:
stat
.
S_IXGRP
},
'o'
:
{
'r'
:
stat
.
S_IROTH
,
'w'
:
stat
.
S_IWOTH
,
'x'
:
stat
.
S_IXOTH
},
'a'
:
{
'r'
:
(
stat
.
S_IRUSR
|
stat
.
S_IRGRP
|
stat
.
S_IROTH
),
'w'
:
(
stat
.
S_IWUSR
|
stat
.
S_IWGRP
|
stat
.
S_IWOTH
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment