Skip to content

Commit 7b86093

Browse files
committed
WIP
1 parent 86f4862 commit 7b86093

File tree

5 files changed

+9
-107
lines changed

5 files changed

+9
-107
lines changed

.github/workflows/tests.yml

+1-63
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
- docs-master
1010

1111
env:
12-
#ANSIBLE_VERBOSITY: 3
12+
ANSIBLE_VERBOSITY: 3
1313
#MITOGEN_LOG_LEVEL: DEBUG
1414
MITOGEN_TEST_IMAGE_TEMPLATE: "ghcr.io/mitogen-hq/%(distro)s-test"
1515

@@ -24,57 +24,9 @@ jobs:
2424
fail-fast: false
2525
matrix:
2626
include:
27-
- name: Ans_27_210
28-
tox_env: py27-mode_ansible-ansible2.10
29-
- name: Ans_27_4
30-
tox_env: py27-mode_ansible-ansible4
31-
32-
- name: Ans_36_210
33-
python_version: '3.6'
34-
tox_env: py36-mode_ansible-ansible2.10
35-
- name: Ans_36_4
36-
python_version: '3.6'
37-
tox_env: py36-mode_ansible-ansible4
38-
39-
- name: Ans_311_210
40-
python_version: '3.11'
41-
tox_env: py311-mode_ansible-ansible2.10
42-
- name: Ans_311_3
43-
python_version: '3.11'
44-
tox_env: py311-mode_ansible-ansible3
45-
- name: Ans_311_4
46-
python_version: '3.11'
47-
tox_env: py311-mode_ansible-ansible4
48-
- name: Ans_311_5
49-
python_version: '3.11'
50-
tox_env: py311-mode_ansible-ansible5
51-
- name: Ans_313_6
52-
python_version: '3.13'
53-
tox_env: py313-mode_ansible-ansible6
54-
- name: Ans_313_7
55-
python_version: '3.13'
56-
tox_env: py313-mode_ansible-ansible7
57-
- name: Ans_313_8
58-
python_version: '3.13'
59-
tox_env: py313-mode_ansible-ansible8
60-
- name: Ans_313_9
61-
python_version: '3.13'
62-
tox_env: py313-mode_ansible-ansible9
6327
- name: Ans_313_10
6428
python_version: '3.13'
6529
tox_env: py313-mode_ansible-ansible10
66-
- name: Van_313_10
67-
python_version: '3.13'
68-
tox_env: py313-mode_ansible-ansible10-strategy_linear
69-
70-
- name: Mito_27
71-
tox_env: py27-mode_mitogen
72-
- name: Mito_36
73-
python_version: '3.6'
74-
tox_env: py36-mode_mitogen
75-
- name: Mito_313
76-
python_version: '3.13'
77-
tox_env: py313-mode_mitogen
7830

7931
steps:
8032
- uses: actions/checkout@v4
@@ -164,24 +116,10 @@ jobs:
164116
fail-fast: false
165117
matrix:
166118
include:
167-
- name: Mito_27
168-
tox_env: py27-mode_mitogen
169-
- name: Mito_313
170-
python_version: '3.13'
171-
tox_env: py313-mode_mitogen
172-
173-
- name: Loc_27_210
174-
tox_env: py27-mode_localhost-ansible2.10
175119
- name: Loc_313_10
176120
python_version: '3.13'
177121
tox_env: py313-mode_localhost-ansible10
178122

179-
- name: Van_27_210
180-
tox_env: py27-mode_localhost-ansible2.10-strategy_linear
181-
- name: Van_313_10
182-
python_version: '3.13'
183-
tox_env: py313-mode_localhost-ansible10-strategy_linear
184-
185123
steps:
186124
- uses: actions/checkout@v4
187125
- uses: actions/setup-python@v5

ansible_mitogen/connection.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -918,7 +918,7 @@ def reset(self):
918918
connection=self,
919919
play_context=self._play_context,
920920
loader=0,
921-
templar=0,
921+
templar=self.templar,
922922
shared_loader_obj=0
923923
)
924924

ansible_mitogen/mixins.py

+7-2
Original file line numberDiff line numberDiff line change
@@ -489,10 +489,13 @@ def _run_cmd():
489489

490490
for possible_python in possible_pythons:
491491
try:
492+
LOG.debug('_low_level_execute_command(): trying %s', possible_python)
492493
self._possible_python_interpreter = possible_python
493494
rc, stdout, stderr = _run_cmd()
495+
LOG.debug('_low_level_execute_command(): got rc=%d, stdout=%r, stderr=%r', rc, stdout, stderr)
494496
# TODO: what exception is thrown?
495-
except:
497+
except BaseException as exc:
498+
LOG.debug('%r._low_level_execute_command for possible_python=%r: %s, %r', self, possible_python, type(exc), exc)
496499
# we've reached the last python attempted and failed
497500
# TODO: could use enumerate(), need to check which version of python first had it though
498501
if possible_python == 'python':
@@ -501,10 +504,12 @@ def _run_cmd():
501504
continue
502505

503506
stdout_text = to_text(stdout, errors=encoding_errors)
507+
stderr_text = to_text(stderr, errors=encoding_errors)
504508

505509
return {
506510
'rc': rc,
507511
'stdout': stdout_text,
508512
'stdout_lines': stdout_text.splitlines(),
509-
'stderr': stderr,
513+
'stderr': stderr_text,
514+
'stderr_lines': stderr_text.splitlines(),
510515
}

tests/ansible/all.yml

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
- import_playbook: setup/all.yml
22
tags: setup
3-
- import_playbook: regression/all.yml
4-
tags: regression
53
- import_playbook: integration/all.yml
64
tags: integration

tests/ansible/integration/all.yml

-39
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,2 @@
1-
2-
#
3-
# This playbook imports all tests that are known to work at present.
4-
#
5-
6-
- import_playbook: action/all.yml
7-
tags: action
8-
- import_playbook: async/all.yml
9-
tags: async
10-
- import_playbook: become/all.yml
11-
tags: become
12-
- import_playbook: connection/all.yml
13-
tags: connection
14-
- import_playbook: connection_delegation/all.yml
15-
tags: connection_delegation
16-
- import_playbook: connection_loader/all.yml
17-
tags: connection_loader
18-
- import_playbook: context_service/all.yml
19-
tags: context_service
20-
- import_playbook: glibc_caches/all.yml
21-
tags: glibc_caches
22-
- import_playbook: interpreter_discovery/all.yml
23-
tags: interpreter_discovery
24-
- import_playbook: local/all.yml
25-
tags: local
26-
- import_playbook: module_utils/all.yml
27-
tags: module_utils
28-
- import_playbook: playbook_semantics/all.yml
29-
tags: playbook_semantics
30-
- import_playbook: process/all.yml
31-
tags: process
32-
- import_playbook: runner/all.yml
33-
tags: runner
341
- import_playbook: ssh/all.yml
352
tags: ssh
36-
- import_playbook: strategy/all.yml
37-
tags: strategy
38-
- import_playbook: stub_connections/all.yml
39-
tags: stub_connections
40-
- import_playbook: transport_config/all.yml
41-
tags: transport_config

0 commit comments

Comments
 (0)