project_name
string
class_name
string
class_modifiers
string
class_implements
int64
class_extends
int64
function_name
string
function_body
string
cyclomatic_complexity
int64
NLOC
int64
num_parameter
int64
num_token
int64
num_variable
int64
start_line
int64
end_line
int64
function_index
int64
function_params
string
function_variable
string
function_return_type
string
function_body_line_type
string
function_num_functions
int64
function_num_lines
int64
outgoing_function_count
int64
outgoing_function_names
string
incoming_function_count
int64
incoming_function_names
string
lexical_representation
string
Sema4AI_actions
public
public
0
0
create_package_yaml
def create_package_yaml(tmpdir, exclude_patterns=None):"""Create a package.yaml file with exclusion patterns."""temp_dir = Path(tmpdir)package_yaml = temp_dir / "package.yaml"if exclude_patterns is None:exclude_patterns = ["./.git/**","./.vscode/**","./devdata/**","./output/**","./venv/**","./.venv/**","./.DS_store/**"...
3
33
2
86
4
43
79
43
tmpdir,exclude_patterns
['package_content', 'exclude_patterns', 'temp_dir', 'package_yaml']
Returns
{"Assign": 4, "AugAssign": 1, "Expr": 2, "For": 1, "If": 1, "Return": 1}
2
37
2
["Path", "package_yaml.write_text"]
3
["_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.actions_core_tests.test_find_action_paths_py.test_handles_complex_exclusion_patterns", "_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.acti...
The function (create_package_yaml) defined within the public class called public.The function start at line 43 and ends at 79. It contains 33 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [43.0], and this function return a value. It declares 2.0 functions, It has 2.0 funct...
Sema4AI_actions
public
public
0
0
library_roots
def library_roots(tmpdir):"""Create a library roots directory under tmpdir for testing."""temp_dir = Path(tmpdir)lib_root = temp_dir / "site-packages"lib_root.mkdir()return [str(lib_root)]
1
5
1
29
2
83
88
83
tmpdir
['temp_dir', 'lib_root']
Returns
{"Assign": 2, "Expr": 2, "Return": 1}
3
6
3
["Path", "lib_root.mkdir", "str"]
0
[]
The function (library_roots) defined within the public class called public.The function start at line 83 and ends at 88. It contains 5 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters, and this function return a value. It declares 3.0 functions, and It has 3.0 functions ...
Sema4AI_actions
public
public
0
0
test_finds_all_python_files_with_default_pattern
def test_finds_all_python_files_with_default_pattern(tmpdir, library_roots):"""Test that FindActionPaths finds all Python files with default pattern."""temp_dir = Path(tmpdir)expected_files = create_test_structure(tmpdir)finder = FindActionPaths(temp_dir, ["*"], library_roots)found_files = [str(f.relative_to(temp_dir))...
2
6
2
66
4
91
99
91
tmpdir,library_roots
['expected_files', 'found_files', 'temp_dir', 'finder']
None
{"Assign": 4, "Expr": 1}
8
9
8
["Path", "create_test_structure", "FindActionPaths", "replace", "str", "f.relative_to", "set", "set"]
0
[]
The function (test_finds_all_python_files_with_default_pattern) defined within the public class called public.The function start at line 91 and ends at 99. It contains 6 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [91.0] and does not return any value. It declares 8.0 fun...
Sema4AI_actions
public
public
0
0
test_respects_glob_patterns
def test_respects_glob_patterns(tmpdir, library_roots):"""Test that FindActionPaths respects glob patterns."""temp_dir = Path(tmpdir)create_test_structure(tmpdir)# Test specific patternfinder = FindActionPaths(temp_dir, ["test1.py"], library_roots)found_files = [f.name for f in finder]assert found_files == ["test1.py"]
2
6
2
47
3
102
111
102
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 2}
3
10
3
["Path", "create_test_structure", "FindActionPaths"]
0
[]
The function (test_respects_glob_patterns) defined within the public class called public.The function start at line 102 and ends at 111. It contains 6 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [102.0] and does not return any value. It declares 3.0 functions, and It ha...
Sema4AI_actions
public
public
0
0
test_handles_multiple_glob_patterns
def test_handles_multiple_glob_patterns(tmpdir, library_roots):"""Test that FindActionPaths handles multiple glob patterns."""temp_dir = Path(tmpdir)create_test_structure(tmpdir)finder = FindActionPaths(temp_dir, ["*1.py", "t*t2.py", "test4.py"], library_roots)found_files = {str(f.relative_to(temp_dir)).replace("\\", "...
2
6
2
68
3
114
122
114
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 2}
6
9
6
["Path", "create_test_structure", "FindActionPaths", "replace", "str", "f.relative_to"]
0
[]
The function (test_handles_multiple_glob_patterns) defined within the public class called public.The function start at line 114 and ends at 122. It contains 6 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [114.0] and does not return any value. It declares 6.0 functions, an...
Sema4AI_actions
public
public
0
0
test_skips_directories_with_package_yaml_exclusions
def test_skips_directories_with_package_yaml_exclusions(tmpdir, library_roots):"""Test that FindActionPaths skips directories based on package.yaml exclusions."""temp_dir = Path(tmpdir)create_test_structure(tmpdir)# Create package.yaml with exclusion patternscreate_package_yaml(tmpdir,["./.git/**","./.venv/**","./venv/...
2
20
2
102
3
125
151
125
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 3}
7
27
7
["Path", "create_test_structure", "create_package_yaml", "FindActionPaths", "str", "str", "str"]
0
[]
The function (test_skips_directories_with_package_yaml_exclusions) defined within the public class called public.The function start at line 125 and ends at 151. It contains 20 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [125.0] and does not return any value. It declares ...
Sema4AI_actions
public
public
0
0
test_respects_package_yaml_exclusion_patterns
def test_respects_package_yaml_exclusion_patterns(tmpdir, library_roots):"""Test that FindActionPaths respects specific exclusion patterns from package.yaml."""temp_dir = Path(tmpdir)# Create test structure(temp_dir / "test1.py").write_text("# test file 1")(temp_dir / "test2.py").write_text("# test file 2")(temp_dir / ...
2
15
2
124
3
154
177
154
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 8}
9
24
9
["Path", "write_text", "write_text", "mkdir", "write_text", "mkdir", "write_text", "create_package_yaml", "FindActionPaths"]
0
[]
The function (test_respects_package_yaml_exclusion_patterns) defined within the public class called public.The function start at line 154 and ends at 177. It contains 15 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [154.0] and does not return any value. It declares 9.0 fu...
Sema4AI_actions
public
public
0
0
test_handles_complex_exclusion_patterns
def test_handles_complex_exclusion_patterns(tmpdir, library_roots):"""Test that FindActionPaths handles complex glob patterns from package.yaml."""temp_dir = Path(tmpdir)(temp_dir / "nested").mkdir()# Create test structure(temp_dir / "test1.py").write_text("# test file 1")(temp_dir / "test2.pyc").write_text("# compiled...
2
16
2
133
3
180
204
180
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 8}
9
25
9
["Path", "mkdir", "write_text", "write_text", "write_text", "write_text", "write_text", "create_package_yaml", "FindActionPaths"]
0
[]
The function (test_handles_complex_exclusion_patterns) defined within the public class called public.The function start at line 180 and ends at 204. It contains 16 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [180.0] and does not return any value. It declares 9.0 function...
Sema4AI_actions
public
public
0
0
test_avoids_library_roots
def test_avoids_library_roots(tmpdir, library_roots):"""Test that FindActionPaths avoids library roots."""temp_dir = Path(tmpdir)# Create a structure that mimics a library rootlib_root = Path(library_roots[0])(lib_root / "some_lib.py").write_text("# library file")# Create a regular file outside library root(temp_dir / ...
2
9
2
82
4
207
223
207
tmpdir,library_roots
['found_files', 'finder', 'temp_dir', 'lib_root']
None
{"Assign": 4, "Expr": 3}
6
17
6
["Path", "Path", "write_text", "write_text", "FindActionPaths", "str"]
0
[]
The function (test_avoids_library_roots) defined within the public class called public.The function start at line 207 and ends at 223. It contains 9 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [207.0] and does not return any value. It declares 6.0 functions, and It has ...
Sema4AI_actions
public
public
0
0
test_handles_nonexistent_paths
def test_handles_nonexistent_paths(tmpdir, library_roots):"""Test that FindActionPaths handles nonexistent paths gracefully."""temp_dir = Path(tmpdir)nonexistent_path = temp_dir / "nonexistent"finder = FindActionPaths(nonexistent_path, ["*.py"], library_roots)found_files = list(finder)assert found_files == []
1
6
2
42
4
226
234
226
tmpdir,library_roots
['found_files', 'nonexistent_path', 'temp_dir', 'finder']
None
{"Assign": 4, "Expr": 1}
3
9
3
["Path", "FindActionPaths", "list"]
0
[]
The function (test_handles_nonexistent_paths) defined within the public class called public.The function start at line 226 and ends at 234. It contains 6 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [226.0] and does not return any value. It declares 3.0 functions, and It...
Sema4AI_actions
public
public
0
0
test_handles_permission_errors.mock_iterdir
def mock_iterdir(self):if self == restricted_dir:raise PermissionError("Permission denied")return original_iterdir(self)
2
4
1
20
0
250
253
250
null
[]
None
null
0
0
0
null
0
null
The function (test_handles_permission_errors.mock_iterdir) defined within the public class called public.The function start at line 250 and ends at 253. It contains 4 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_handles_permission_errors
def test_handles_permission_errors(tmpdir, library_roots):"""Test that FindActionPaths handles permission errors gracefully."""temp_dir = Path(tmpdir)create_test_structure(tmpdir)# Create a directory that might cause permission issuesrestricted_dir = temp_dir / "restricted"restricted_dir.mkdir()(restricted_dir / "test....
3
15
2
89
5
237
264
237
tmpdir,library_roots
['temp_dir', 'original_iterdir', 'restricted_dir', 'finder', 'found_files']
Returns
{"Assign": 7, "Expr": 4, "If": 1, "Return": 1, "Try": 1}
8
28
8
["Path", "create_test_structure", "restricted_dir.mkdir", "write_text", "PermissionError", "original_iterdir", "FindActionPaths", "len"]
0
[]
The function (test_handles_permission_errors) defined within the public class called public.The function start at line 237 and ends at 264. It contains 15 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [237.0], and this function return a value. It declares 8.0 functions, an...
Sema4AI_actions
public
public
0
0
test_sorts_output_consistently
def test_sorts_output_consistently(tmpdir, library_roots):"""Test that FindActionPaths provides consistent ordering."""temp_dir = Path(tmpdir)create_test_structure(tmpdir)finder1 = FindActionPaths(temp_dir, ["*.py"], library_roots)files1 = [str(f.relative_to(temp_dir)) for f in finder1]finder2 = FindActionPaths(temp_di...
3
8
2
80
5
267
278
267
tmpdir,library_roots
['files1', 'temp_dir', 'files2', 'finder2', 'finder1']
None
{"Assign": 5, "Expr": 2}
8
12
8
["Path", "create_test_structure", "FindActionPaths", "str", "f.relative_to", "FindActionPaths", "str", "f.relative_to"]
0
[]
The function (test_sorts_output_consistently) defined within the public class called public.The function start at line 267 and ends at 278. It contains 8 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [267.0] and does not return any value. It declares 8.0 functions, and It...
Sema4AI_actions
public
public
0
0
test_handles_empty_directory
def test_handles_empty_directory(tmpdir, library_roots):"""Test that FindActionPaths handles empty directories."""temp_dir = Path(tmpdir)finder = FindActionPaths(temp_dir, ["*.py"], library_roots)found_files = list(finder)assert found_files == []
1
5
2
37
3
281
287
281
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 1}
3
7
3
["Path", "FindActionPaths", "list"]
0
[]
The function (test_handles_empty_directory) defined within the public class called public.The function start at line 281 and ends at 287. It contains 5 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [281.0] and does not return any value. It declares 3.0 functions, and It h...
Sema4AI_actions
public
public
0
0
test_handles_non_python_files
def test_handles_non_python_files(tmpdir, library_roots):"""Test that FindActionPaths only returns Python files."""temp_dir = Path(tmpdir)# Create non-Python files(temp_dir / "test.txt").write_text("text file")(temp_dir / "test.py").write_text("# python file")(temp_dir / "test.js").write_text("// javascript file")finde...
2
10
2
83
3
290
304
290
tmpdir,library_roots
['found_files', 'temp_dir', 'finder']
None
{"Assign": 3, "Expr": 4}
5
15
5
["Path", "write_text", "write_text", "write_text", "FindActionPaths"]
0
[]
The function (test_handles_non_python_files) defined within the public class called public.The function start at line 290 and ends at 304. It contains 10 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [290.0] and does not return any value. It declares 5.0 functions, and It...
Sema4AI_actions
public
public
0
0
test_respects_depth_limitation
def test_respects_depth_limitation(tmpdir, library_roots):"""Test that FindActionPaths respects the 3-level depth limitation."""temp_dir = Path(tmpdir)# Create a deep directory structure (4 levels)deep_path = temp_dir / "level1" / "level2" / "level3" / "level4"deep_path.mkdir(parents=True)# Create Python files at diffe...
2
16
2
152
5
307
335
307
tmpdir,library_roots
['temp_dir', 'finder', 'deep_path', 'found_files', 'expected_files']
None
{"Assign": 5, "Expr": 7}
10
29
10
["Path", "deep_path.mkdir", "write_text", "write_text", "write_text", "write_text", "write_text", "FindActionPaths", "sorted", "sorted"]
0
[]
The function (test_respects_depth_limitation) defined within the public class called public.The function start at line 307 and ends at 335. It contains 16 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [307.0] and does not return any value. It declares 10.0 functions, and ...
Sema4AI_actions
public
public
0
0
test_fixture_module
def test_fixture_module(datadir, str_regression):from devutils.fixtures import sema4ai_actions_runresult = sema4ai_actions_run(["run","--console-colors=plain","--preload-module=my_config","--preload-module=my_config2",],returncode=0,cwd=str(datadir),)stdout = result.stdout.decode("utf-8")found = []for line in stdout.sp...
3
18
2
88
3
1
20
1
datadir,str_regression
['stdout', 'result', 'found']
None
{"Assign": 3, "Expr": 2, "For": 1, "If": 1}
7
20
7
["sema4ai_actions_run", "str", "result.stdout.decode", "stdout.splitlines", "found.append", "str_regression.check", "join"]
0
[]
The function (test_fixture_module) defined within the public class called public.The function start at line 1 and ends at 20. It contains 18 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [1.0] and does not return any value. It declares 7.0 functions, and It has 7.0 functi...
Sema4AI_actions
public
public
0
0
_clear_callbacks
def _clear_callbacks():before_action_run._callbacks = ()before_all_actions_run._callbacks = ()after_action_run._callbacks = ()after_all_actions_run._callbacks = ()
1
5
0
28
0
15
19
15
[]
None
{"Assign": 4}
0
5
0
[]
2
["_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.actions_core_tests.test_fixtures_py.clear_callbacks", "_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.actions_core_tests.test_lifecycle_py....
The function (_clear_callbacks) defined within the public class called public.The function start at line 15 and ends at 19. It contains 5 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It has 2.0 functions calling this function which are [...
Sema4AI_actions
public
public
0
0
clear_callbacks
def clear_callbacks():_clear_callbacks()yield_clear_callbacks()
1
4
0
11
0
23
26
23
[]
None
{"Expr": 3}
3
4
3
["_clear_callbacks", "_clear_callbacks", "pytest.fixture"]
0
[]
The function (clear_callbacks) defined within the public class called public.The function start at line 23 and ends at 26. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 3.0 functions, and It has 3.0 functions ca...
Sema4AI_actions
public
public
0
0
test_setup_default.fixture
def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = True
1
4
1
14
0
36
39
36
null
[]
None
null
0
0
0
null
0
null
The function (test_setup_default.fixture) defined within the public class called public.The function start at line 36 and ends at 39. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_setup_default
def test_setup_default():assert len(before_action_run) == 0assert len(before_all_actions_run) == 0is_called = False@actions_setupdef fixture(task):assert task == "placeholder"nonlocal is_calledis_called = Trueassert not is_calledassert len(before_action_run) == 1assert len(before_all_actions_run) == 0before_action_run(...
1
11
0
48
1
29
46
29
['is_called']
None
{"Assign": 2, "Expr": 1}
5
18
5
["len", "len", "len", "len", "before_action_run"]
0
[]
The function (test_setup_default) defined within the public class called public.The function start at line 29 and ends at 46. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 5.0 functions, and It has 5.0 function...
Sema4AI_actions
public
public
0
0
test_setup_all.fixture
def fixture(tasks):assert isinstance(tasks, Iterable)nonlocal is_calledis_called = True
1
4
1
17
0
56
59
56
null
[]
None
null
0
0
0
null
0
null
The function (test_setup_all.fixture) defined within the public class called public.The function start at line 56 and ends at 59. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_setup_all
def test_setup_all():assert len(before_action_run) == 0assert len(before_all_actions_run) == 0is_called = False@actions_setup(scope="session")def fixture(tasks):assert isinstance(tasks, Iterable)nonlocal is_calledis_called = Trueassert not is_calledassert len(before_action_run) == 0assert len(before_all_actions_run) ==...
1
11
0
54
1
49
66
49
['is_called']
None
{"Assign": 2, "Expr": 1}
7
18
7
["len", "len", "isinstance", "actions_setup", "len", "len", "before_all_actions_run"]
0
[]
The function (test_setup_all) defined within the public class called public.The function start at line 49 and ends at 66. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 7.0 functions, and It has 7.0 functions ca...
Sema4AI_actions
public
public
0
0
test_setup_task.fixture
def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = True
1
4
1
14
0
76
79
76
null
[]
None
null
0
0
0
null
0
null
The function (test_setup_task.fixture) defined within the public class called public.The function start at line 76 and ends at 79. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_setup_task
def test_setup_task():assert len(before_action_run) == 0assert len(before_all_actions_run) == 0is_called = False@actions_setup(scope="action")def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = Trueassert not is_calledassert len(before_action_run) == 1assert len(before_all_actions_run) == 0befor...
1
11
0
53
1
69
86
69
['is_called']
None
{"Assign": 2, "Expr": 1}
6
18
6
["len", "len", "actions_setup", "len", "len", "before_action_run"]
0
[]
The function (test_setup_task) defined within the public class called public.The function start at line 69 and ends at 86. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 6.0 functions, and It has 6.0 functions c...
Sema4AI_actions
public
public
0
0
test_teardown_default.fixture
def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = True
1
4
1
14
0
96
99
96
null
[]
None
null
0
0
0
null
0
null
The function (test_teardown_default.fixture) defined within the public class called public.The function start at line 96 and ends at 99. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_teardown_default
def test_teardown_default():assert len(after_action_run) == 0assert len(after_all_actions_run) == 0is_called = False@actions_teardowndef fixture(task):assert task == "placeholder"nonlocal is_calledis_called = Trueassert not is_calledassert len(after_action_run) == 1assert len(after_all_actions_run) == 0after_action_run...
1
11
0
48
1
89
106
89
['is_called']
None
{"Assign": 2, "Expr": 1}
5
18
5
["len", "len", "len", "len", "after_action_run"]
0
[]
The function (test_teardown_default) defined within the public class called public.The function start at line 89 and ends at 106. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 5.0 functions, and It has 5.0 func...
Sema4AI_actions
public
public
0
0
test_teardown_all.fixture
def fixture(tasks):assert isinstance(tasks, Iterable)nonlocal is_calledis_called = True
1
4
1
17
0
116
119
116
null
[]
None
null
0
0
0
null
0
null
The function (test_teardown_all.fixture) defined within the public class called public.The function start at line 116 and ends at 119. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_teardown_all
def test_teardown_all():assert len(after_action_run) == 0assert len(after_all_actions_run) == 0is_called = False@actions_teardown(scope="session")def fixture(tasks):assert isinstance(tasks, Iterable)nonlocal is_calledis_called = Trueassert not is_calledassert len(after_action_run) == 0assert len(after_all_actions_run) ...
1
11
0
54
1
109
126
109
['is_called']
None
{"Assign": 2, "Expr": 1}
7
18
7
["len", "len", "isinstance", "actions_teardown", "len", "len", "after_all_actions_run"]
0
[]
The function (test_teardown_all) defined within the public class called public.The function start at line 109 and ends at 126. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 7.0 functions, and It has 7.0 functio...
Sema4AI_actions
public
public
0
0
test_teardown_task.fixture
def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = True
1
4
1
14
0
136
139
136
null
[]
None
null
0
0
0
null
0
null
The function (test_teardown_task.fixture) defined within the public class called public.The function start at line 136 and ends at 139. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_teardown_task
def test_teardown_task():assert len(after_action_run) == 0assert len(after_all_actions_run) == 0is_called = False@actions_teardown(scope="action")def fixture(task):assert task == "placeholder"nonlocal is_calledis_called = Trueassert not is_calledassert len(after_action_run) == 1assert len(after_all_actions_run) == 0aft...
1
11
0
53
1
129
146
129
['is_called']
None
{"Assign": 2, "Expr": 1}
6
18
6
["len", "len", "actions_teardown", "len", "len", "after_action_run"]
0
[]
The function (test_teardown_task) defined within the public class called public.The function start at line 129 and ends at 146. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 6.0 functions, and It has 6.0 functi...
Sema4AI_actions
public
public
0
0
test_raises.raises_setup
def raises_setup(_):raise RuntimeError("Oopsie")
1
2
1
10
0
151
152
151
null
[]
None
null
0
0
0
null
0
null
The function (test_raises.raises_setup) defined within the public class called public.The function start at line 151 and ends at 152. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_raises.raises_teardown
def raises_teardown(_):raise RuntimeError("Oopsie #2")
1
2
1
10
0
155
156
155
null
[]
None
null
0
0
0
null
0
null
The function (test_raises.raises_teardown) defined within the public class called public.The function start at line 155 and ends at 156. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_raises
def test_raises():@actions_setupdef raises_setup(_):raise RuntimeError("Oopsie")@actions_teardowndef raises_teardown(_):raise RuntimeError("Oopsie #2")assert len(before_action_run) == 1assert len(after_action_run) == 1with pytest.raises(RuntimeError):before_action_run(None)after_action_run(None)
1
10
0
42
0
149
164
149
[]
None
{"Expr": 2, "With": 1}
7
16
7
["RuntimeError", "RuntimeError", "len", "len", "pytest.raises", "before_action_run", "after_action_run"]
0
[]
The function (test_raises) defined within the public class called public.The function start at line 149 and ends at 164. It contains 10 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 7.0 functions, and It has 7.0 functions cal...
Sema4AI_actions
public
public
0
0
test_setup_generator.fixture_gen
def fixture_gen(task):assert task == "task"yieldnonlocal is_calledis_called = True
1
5
1
15
0
174
178
174
null
[]
None
null
0
0
0
null
0
null
The function (test_setup_generator.fixture_gen) defined within the public class called public.The function start at line 174 and ends at 178. It contains 5 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_setup_generator
def test_setup_generator():assert len(before_action_run) == 0assert len(after_action_run) == 0is_called = False@actions_setupdef fixture_gen(task):assert task == "task"yieldnonlocal is_calledis_called = Trueassert not is_calledassert len(before_action_run) == 1assert len(after_action_run) == 0before_action_run("task")a...
1
17
0
83
1
167
194
167
['is_called']
None
{"Assign": 2, "Expr": 3}
10
28
10
["len", "len", "len", "len", "before_action_run", "len", "len", "after_action_run", "len", "len"]
0
[]
The function (test_setup_generator) defined within the public class called public.The function start at line 167 and ends at 194. It contains 17 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 10.0 functions, and It has 10.0 fu...
Sema4AI_actions
public
public
0
0
test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task.my_cache
def my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()
1
4
0
20
0
23
26
23
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task.my_cache) defined within the public class called public.The function start at line 23 and ends at 26. It contains 4 lines of code and it has a cyclomatic complexity o...
Sema4AI_actions
public
public
0
0
test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task.write_on_exit
def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()
1
3
0
19
0
30
32
30
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task.write_on_exit) defined within the public class called public.The function start at line 30 and ends at 32. It contains 3 lines of code and it has a cyclomatic complex...
Sema4AI_actions
public
public
0
0
test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task
def my_task():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()my_cache()def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.register(write_on_exit)
1
9
0
31
0
16
34
16
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_cmdline.test_force_early_exit_cmdline.check.my_task) defined within the public class called public.The function start at line 16 and ends at 34. It contains 9 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any valu...
Sema4AI_actions
public
public
0
0
test_force_early_exit_cmdline.check
def check():from sema4ai.actions import action, session_cache@actiondef my_task():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()my_cache()def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.re...
1
4
0
16
0
12
34
12
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_cmdline.check) defined within the public class called public.The function start at line 12 and ends at 34. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_force_early_exit_cmdline
def test_force_early_exit_cmdline(pyfile, kill):from devutils.fixtures import sema4ai_actions_run@pyfiledef check():from sema4ai.actions import action, session_cache@actiondef my_task():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stde...
4
18
2
116
3
8
52
8
pyfile,kill
['result', 'cmdline', 'stderr']
None
{"Assign": 3, "Expr": 9, "If": 3}
15
45
15
["sys.stderr.write", "sys.stderr.write", "sys.stderr.flush", "my_cache", "sys.stderr.write", "sys.stderr.flush", "atexit.register", "cmdline.append", "sema4ai_actions_run", "os.path.dirname", "result.stderr.decode", "stderr.count", "stderr.count", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_force_early_exit_cmdline) defined within the public class called public.The function start at line 8 and ends at 52. It contains 18 lines of code and it has a cyclomatic complexity of 4. It takes 2 parameters, represented as [8.0] and does not return any value. It declares 15.0 functions, and It has...
Sema4AI_actions
public
public
0
0
test_force_early_exit.test_force_early_exit.check.test_force_early_exit.test_force_early_exit.check.my_action.my_cache
def my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()
1
4
0
20
0
71
74
71
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit.test_force_early_exit.check.test_force_early_exit.test_force_early_exit.check.my_action.my_cache) defined within the public class called public.The function start at line 71 and ends at 74. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not tak...
Sema4AI_actions
public
public
0
0
test_force_early_exit.test_force_early_exit.check.test_force_early_exit.test_force_early_exit.check.my_action.write_on_exit
def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()
1
3
0
19
0
78
80
78
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit.test_force_early_exit.check.test_force_early_exit.test_force_early_exit.check.my_action.write_on_exit) defined within the public class called public.The function start at line 78 and ends at 80. It contains 3 lines of code and it has a cyclomatic complexity of 1. The function does no...
Sema4AI_actions
public
public
0
0
test_force_early_exit.test_force_early_exit.check.my_action
def my_action():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()my_cache()def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.register(write_on_exit)
1
9
0
31
0
64
82
64
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit.test_force_early_exit.check.my_action) defined within the public class called public.The function start at line 64 and ends at 82. It contains 9 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_force_early_exit.check
def check():from sema4ai.actions import action, session_cache@actiondef my_action():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flush()my_cache()def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit....
1
4
0
16
0
60
82
60
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit.check) defined within the public class called public.The function start at line 60 and ends at 82. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_force_early_exit
def test_force_early_exit(pyfile, kill):from devutils.fixtures import sema4ai_actions_run@pyfiledef check():from sema4ai.actions import action, session_cache@actiondef my_action():import syssys.stderr.write("Executed\n")import atexit@session_cachedef my_cache():yieldsys.stderr.write("my_cache_teardown\n")sys.stderr.flu...
3
26
2
162
5
56
110
56
pyfile,kill
['env', 'stderr', 'stdout', 'log_target', 'result']
None
{"Assign": 5, "Expr": 8, "If": 2}
19
55
19
["sys.stderr.write", "sys.stderr.write", "sys.stderr.flush", "my_cache", "sys.stderr.write", "sys.stderr.flush", "atexit.register", "dict", "sema4ai_actions_run", "os.path.dirname", "result.stderr.decode", "result.stdout.decode", "stderr.count", "Path", "os.path.dirname", "log_target.exists", "stderr.count", "stderr.co...
0
[]
The function (test_force_early_exit) defined within the public class called public.The function start at line 56 and ends at 110. It contains 26 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [56.0] and does not return any value. It declares 19.0 functions, and It has 19.0...
Sema4AI_actions
public
public
0
0
test_force_early_exit_with_error.test_force_early_exit_with_error.check.test_force_early_exit_with_error.test_force_early_exit_with_error.check.my_task.write_on_exit
def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()
1
3
0
19
0
128
130
128
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_with_error.test_force_early_exit_with_error.check.test_force_early_exit_with_error.test_force_early_exit_with_error.check.my_task.write_on_exit) defined within the public class called public.The function start at line 128 and ends at 130. It contains 3 lines of code and it has a cycl...
Sema4AI_actions
public
public
0
0
test_force_early_exit_with_error.test_force_early_exit_with_error.check.my_task
def my_task():import syssys.stderr.write("Executed\n")import atexitdef write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.register(write_on_exit)raise RuntimeError("Something bad happened (retcode should be 1)")
1
7
0
29
0
122
133
122
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_with_error.test_force_early_exit_with_error.check.my_task) defined within the public class called public.The function start at line 122 and ends at 133. It contains 7 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return ...
Sema4AI_actions
public
public
0
0
test_force_early_exit_with_error.check
def check():from sema4ai.actions import action@actiondef my_task():import syssys.stderr.write("Executed\n")import atexitdef write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.register(write_on_exit)raise RuntimeError("Something bad happened (retcode should be 1)")
1
4
0
14
0
118
133
118
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_with_error.check) defined within the public class called public.The function start at line 118 and ends at 133. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_force_early_exit_with_error
def test_force_early_exit_with_error(pyfile, kill):from devutils.fixtures import sema4ai_actions_run@pyfiledef check():from sema4ai.actions import action@actiondef my_task():import syssys.stderr.write("Executed\n")import atexitdef write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()atexit.register(wr...
2
22
2
143
5
114
155
114
pyfile,kill
['env', 'stderr', 'stdout', 'log_target', 'result']
None
{"Assign": 5, "Expr": 4, "If": 1}
17
42
17
["sys.stderr.write", "sys.stderr.write", "sys.stderr.flush", "atexit.register", "RuntimeError", "dict", "sema4ai_actions_run", "os.path.dirname", "result.stderr.decode", "result.stdout.decode", "Path", "os.path.dirname", "log_target.exists", "stderr.count", "stderr.count", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_force_early_exit_with_error) defined within the public class called public.The function start at line 114 and ends at 155. It contains 22 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [114.0] and does not return any value. It declares 17.0 functions, and...
Sema4AI_actions
public
public
0
0
test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.my_task.write_on_exit
def write_on_exit():sys.stderr.write("atexit_executed\n")sys.stderr.flush()process.terminate()
1
4
0
24
0
187
190
187
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.my_task.write_on_exit) defined within the public class called public.The function start at line 187 and ends at 190. It contains 4...
Sema4AI_actions
public
public
0
0
test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.my_task
def my_task():import subprocessimport sysimport textwrapcode = textwrap.dedent("""import timewhile True:print('.')time.sleep(1)""")process = subprocess.Popen([sys.executable, "-c", code])sys.stderr.write("Executed\n")import atexitprint(f"pid:{process.pid}")def write_on_exit():sys.stderr.write("atexit_executed\n")sys.st...
1
18
0
57
0
167
192
167
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_kills_subprocesses.test_force_early_exit_kills_subprocesses.check.my_task) defined within the public class called public.The function start at line 167 and ends at 192. It contains 18 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and...
Sema4AI_actions
public
public
0
0
test_force_early_exit_kills_subprocesses.check
def check():from sema4ai.actions import action@actiondef my_task():import subprocessimport sysimport textwrapcode = textwrap.dedent("""import timewhile True:print('.')time.sleep(1)""")process = subprocess.Popen([sys.executable, "-c", code])sys.stderr.write("Executed\n")import atexitprint(f"pid:{process.pid}")def write_...
1
4
0
14
0
163
192
163
null
[]
None
null
0
0
0
null
0
null
The function (test_force_early_exit_kills_subprocesses.check) defined within the public class called public.The function start at line 163 and ends at 192. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_force_early_exit_kills_subprocesses
def test_force_early_exit_kills_subprocesses(pyfile, kill):from devutils.fixtures import sema4ai_actions_run@pyfiledef check():from sema4ai.actions import action@actiondef my_task():import subprocessimport sysimport textwrapcode = textwrap.dedent("""import timewhile True:print('.')time.sleep(1)""")process = subprocess....
2
14
2
99
5
159
203
159
pyfile,kill
['env', 'stderr', 'code', 'result', 'process']
None
{"Assign": 5, "Expr": 6, "If": 1}
16
45
16
["textwrap.dedent", "subprocess.Popen", "sys.stderr.write", "print", "sys.stderr.write", "sys.stderr.flush", "process.terminate", "atexit.register", "dict", "sema4ai_actions_run", "os.path.dirname", "result.stderr.decode", "stderr.count", "stderr.count", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_force_early_exit_kills_subprocesses) defined within the public class called public.The function start at line 159 and ends at 203. It contains 14 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [159.0] and does not return any value. It declares 16.0 functi...
Sema4AI_actions
public
public
0
0
test_interrupt_main_thread.interrupt
def interrupt():# sleep here so that the main thread in the test can get to the sleep# too (otherwise if we interrupt too fast we won't really check that the# sleep itself got interrupted -- although if that happens on some tests# runs it's not really an issue either).time.sleep(1)interrupt_main_thread()
1
3
0
13
0
11
17
11
null
[]
None
null
0
0
0
null
0
null
The function (test_interrupt_main_thread.interrupt) defined within the public class called public.The function start at line 11 and ends at 17. It contains 3 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_interrupt_main_thread
def test_interrupt_main_thread():def interrupt():# sleep here so that the main thread in the test can get to the sleep# too (otherwise if we interrupt too fast we won't really check that the# sleep itself got interrupted -- although if that happens on some tests# runs it's not really an issue either).time.sleep(1)inter...
2
19
0
73
4
10
38
10
['t', 'actual_timeout', 'timeout', 'initial_time']
None
{"Assign": 4, "Expr": 4, "Try": 1}
8
29
8
["time.sleep", "interrupt_main_thread", "time.monotonic", "threading.Thread", "t.start", "time.sleep", "time.monotonic", "AssertionError"]
0
[]
The function (test_interrupt_main_thread) defined within the public class called public.The function start at line 10 and ends at 38. It contains 19 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value. It declares 8.0 functions, and It has 8.0 ...
Sema4AI_actions
public
public
0
0
test_create_interrupt_this_thread_callback.__init__
def __init__(self):threading.Thread.__init__(self)self.finished = Falseself.daemon = Trueself.interrupt_thread = Noneself.interrupted = False
1
6
1
33
0
45
50
45
null
[]
None
null
0
0
0
null
0
null
The function (test_create_interrupt_this_thread_callback.__init__) defined within the public class called public.The function start at line 45 and ends at 50. It contains 6 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_create_interrupt_this_thread_callback.run
def run(self):try:self.interrupt_thread = create_interrupt_this_thread_callback()while True:time.sleep(0.2)except KeyboardInterrupt:self.interrupted = Truefinally:self.finished = True
4
9
1
40
0
52
60
52
null
[]
None
null
0
0
0
null
0
null
The function (test_create_interrupt_this_thread_callback.run) defined within the public class called public.The function start at line 52 and ends at 60. It contains 9 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_create_interrupt_this_thread_callback
def test_create_interrupt_this_thread_callback():from devutils.fixtures import wait_for_conditionclass MyThread(threading.Thread):def __init__(self):threading.Thread.__init__(self)self.finished = Falseself.daemon = Trueself.interrupt_thread = Noneself.interrupted = Falsedef run(self):try:self.interrupt_thread = create_...
1
11
0
60
1
41
70
41
['t']
None
{"Assign": 8, "Expr": 6, "Try": 1, "While": 1}
8
30
8
["threading.Thread.__init__", "create_interrupt_this_thread_callback", "time.sleep", "MyThread", "t.start", "wait_for_condition", "t.interrupt_thread", "wait_for_condition"]
0
[]
The function (test_create_interrupt_this_thread_callback) defined within the public class called public.The function start at line 41 and ends at 70. It contains 11 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 8.0 functions, ...
Sema4AI_actions
public
public
0
0
_clear_callbacks
def _clear_callbacks():before_action_run._callbacks = ()before_all_actions_run._callbacks = ()after_action_run._callbacks = ()after_all_actions_run._callbacks = ()
1
5
0
28
0
14
18
14
[]
None
{"Assign": 4}
0
5
0
[]
2
["_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.actions_core_tests.test_fixtures_py.clear_callbacks", "_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.95053458_Sema4AI_actions.actions.tests.actions_core_tests.test_lifecycle_py....
The function (_clear_callbacks) defined within the public class called public.The function start at line 14 and ends at 18. It contains 5 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It has 2.0 functions calling this function which are [...
Sema4AI_actions
public
public
0
0
clear_callbacks
def clear_callbacks():_clear_callbacks()yield_clear_callbacks()
1
4
0
11
0
22
25
22
[]
None
{"Expr": 3}
3
4
3
["_clear_callbacks", "_clear_callbacks", "pytest.fixture"]
0
[]
The function (clear_callbacks) defined within the public class called public.The function start at line 22 and ends at 25. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 3.0 functions, and It has 3.0 functions ca...
Sema4AI_actions
public
public
0
0
test_session_cache_yield.my_function
def my_function():calls.append("before")yield next(counter)calls.append("after")
1
4
0
21
0
36
39
36
null
[]
None
null
0
0
0
null
0
null
The function (test_session_cache_yield.my_function) defined within the public class called public.The function start at line 36 and ends at 39. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_session_cache_yield
def test_session_cache_yield():assert len(after_all_actions_run) == 0counter = itertools.count()calls = []@session_cachedef my_function():calls.append("before")yield next(counter)calls.append("after")assert len(after_all_actions_run) == 0initial = my_function()assert len(after_all_actions_run) == 1assert calls == ["bef...
1
21
0
126
3
28
60
28
['counter', 'calls', 'initial']
None
{"Assign": 3, "Expr": 5}
16
33
16
["len", "itertools.count", "calls.append", "next", "calls.append", "len", "my_function", "len", "my_function", "my_function", "after_all_actions_run", "len", "my_function", "len", "after_all_actions_run", "len"]
0
[]
The function (test_session_cache_yield) defined within the public class called public.The function start at line 28 and ends at 60. It contains 21 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 16.0 functions, and It has 16.0 ...
Sema4AI_actions
public
public
0
0
test_session_cache_return.my_function
def my_function():return next(counter)
1
2
0
9
0
69
70
69
null
[]
None
null
0
0
0
null
0
null
The function (test_session_cache_return.my_function) defined within the public class called public.The function start at line 69 and ends at 70. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_session_cache_return
def test_session_cache_return():assert len(after_all_actions_run) == 0counter = itertools.count()@session_cachedef my_function():return next(counter)assert len(after_all_actions_run) == 0initial = my_function()assert len(after_all_actions_run) == 1assert my_function() == initialassert my_function() == initial# Emulate ...
1
16
0
86
2
63
86
63
['counter', 'initial']
Returns
{"Assign": 2, "Expr": 2, "Return": 1}
14
24
14
["len", "itertools.count", "next", "len", "my_function", "len", "my_function", "my_function", "after_all_actions_run", "len", "my_function", "len", "after_all_actions_run", "len"]
0
[]
The function (test_session_cache_return) defined within the public class called public.The function start at line 63 and ends at 86. It contains 16 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters, and this function return a value. It declares 14.0 functions, and It has ...
Sema4AI_actions
public
public
0
0
test_integrated
def test_integrated(datadir, str_regression):from devutils.fixtures import sema4ai_actions_runresult = sema4ai_actions_run(["run", "-a", "task1", "--console-colors=plain"],returncode=0,cwd=str(datadir),)str_regression.check_until_header(result.stdout.decode("utf-8"))
1
8
2
52
1
89
97
89
datadir,str_regression
['result']
None
{"Assign": 1, "Expr": 1}
4
9
4
["sema4ai_actions_run", "str", "str_regression.check_until_header", "result.stdout.decode"]
0
[]
The function (test_integrated) defined within the public class called public.The function start at line 89 and ends at 97. It contains 8 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [89.0] and does not return any value. It declares 4.0 functions, and It has 4.0 functions...
Sema4AI_actions
public
public
0
0
test_load_autolog_config.show_error
def show_error(self, error):raise AssertionError(error)
1
2
2
12
0
26
27
26
null
[]
None
null
0
0
0
null
0
null
The function (test_load_autolog_config.show_error) defined within the public class called public.The function start at line 26 and ends at 27. It contains 2 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [26.0] and does not return any value..
Sema4AI_actions
public
public
0
0
test_load_autolog_config
def test_load_autolog_config(tmpdir, str_regression) -> None:from pathlib import Pathfrom robocorp.log.pyproject_config import (read_pyproject_toml,read_robocorp_auto_log_config,)target = tmpdir / "pyproject.toml"target.write_text("""[tool.robocorp.log]log_filter_rules = [{name = "RPA", kind = "log_on_project_call"},{n...
1
25
2
78
3
1
31
1
tmpdir,str_regression
['target', 'config', 'pyproject_info']
None
{"Assign": 3, "Expr": 2}
8
31
8
["target.write_text", "read_pyproject_toml", "Path", "AssertionError", "read_robocorp_auto_log_config", "Ctx", "str_regression.check", "str"]
0
[]
The function (test_load_autolog_config) defined within the public class called public.The function start at line 1 and ends at 31. It contains 25 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [1.0] and does not return any value. It declares 8.0 functions, and It has 8.0 f...
Sema4AI_actions
public
public
0
0
test_load_autolog_config_exclude_default.show_error
def show_error(self, error):raise AssertionError(error)
1
2
2
12
0
59
60
59
null
[]
None
null
0
0
0
null
0
null
The function (test_load_autolog_config_exclude_default.show_error) defined within the public class called public.The function start at line 59 and ends at 60. It contains 2 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [59.0] and does not return any value..
Sema4AI_actions
public
public
0
0
test_load_autolog_config_exclude_default
def test_load_autolog_config_exclude_default(tmpdir, str_regression) -> None:from pathlib import Pathfrom robocorp.log.pyproject_config import (read_pyproject_toml,read_robocorp_auto_log_config,)target = tmpdir / "pyproject.toml"target.write_text("""[tool.robocorp.log]log_filter_rules = [{name = "RPA.*", kind = "log_on...
1
25
2
78
3
34
63
34
tmpdir,str_regression
['target', 'config', 'pyproject_info']
None
{"Assign": 3, "Expr": 2}
8
30
8
["target.write_text", "read_pyproject_toml", "Path", "AssertionError", "read_robocorp_auto_log_config", "Ctx", "str_regression.check", "str"]
0
[]
The function (test_load_autolog_config_exclude_default) defined within the public class called public.The function start at line 34 and ends at 63. It contains 25 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [34.0] and does not return any value. It declares 8.0 functions,...
Sema4AI_actions
public
public
0
0
test_read_toml_settings.show_error
def show_error(self, message):errors_shown.append(message)
1
2
2
13
0
10
11
10
null
[]
None
null
0
0
0
null
0
null
The function (test_read_toml_settings.show_error) defined within the public class called public.The function start at line 10 and ends at 11. It contains 2 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [10.0] and does not return any value..
Sema4AI_actions
public
public
0
0
test_read_toml_settings
def test_read_toml_settings():from robocorp.log.pyproject_config import PyProjectInfo, read_section_from_tomlerrors_shown = []class Context:def show_error(self, message):errors_shown.append(message)context = Context()toml_contents = {}assert (read_section_from_toml(PyProjectInfo(Path("pyproject.toml"), toml_contents), ...
1
47
0
191
3
4
58
4
['errors_shown', 'context', 'toml_contents']
None
{"Assign": 7, "Expr": 2}
18
55
18
["errors_shown.append", "Context", "read_section_from_toml", "PyProjectInfo", "Path", "read_section_from_toml", "PyProjectInfo", "Path", "read_section_from_toml", "PyProjectInfo", "Path", "read_section_from_toml", "PyProjectInfo", "Path", "errors_shown.clear", "read_section_from_toml", "PyProjectInfo", "Path"]
0
[]
The function (test_read_toml_settings) defined within the public class called public.The function start at line 4 and ends at 58. It contains 47 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 18.0 functions, and It has 18.0 fu...
Sema4AI_actions
public
public
0
0
test_replace_refs
def test_replace_refs():from sema4ai.actions._remove_refs import replace_refsjson = {"a": ["foobar"],"b": {"$ref": "#/a"},"c": {"$ref": "#/a"},"d": {"$ref": "#/c"},}result = replace_refs(json)assert result == {"a": ["foobar"],"b": ["foobar"],"c": ["foobar"],"d": ["foobar"],}
1
15
0
81
2
4
19
4
['result', 'json']
None
{"Assign": 2}
1
16
1
["replace_refs"]
0
[]
The function (test_replace_refs) defined within the public class called public.The function start at line 4 and ends at 19. It contains 15 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 function cal...
Sema4AI_actions
public
public
0
0
test_replace_refs_later_ref
def test_replace_refs_later_ref():from sema4ai.actions._remove_refs import replace_refsjson = {"b": {"$ref": "#/a"},"c": {"$ref": "#/a"},"d": {"$ref": "#/c"},"a": ["foobar"],}result = replace_refs(json)assert result == {"a": ["foobar"],"b": ["foobar"],"c": ["foobar"],"d": ["foobar"],}
1
15
0
81
2
22
37
22
['result', 'json']
None
{"Assign": 2}
1
16
1
["replace_refs"]
0
[]
The function (test_replace_refs_later_ref) defined within the public class called public.The function start at line 22 and ends at 37. It contains 15 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 f...
Sema4AI_actions
public
public
0
0
test_circular_ref
def test_circular_ref():from sema4ai.actions._remove_refs import JsonRefError, replace_refsjson = {"b": {"$ref": "#/c"},"c": {"$ref": "#/b"},}with pytest.raises(JsonRefError):replace_refs(json)
1
8
0
46
1
40
48
40
['json']
None
{"Assign": 1, "Expr": 1, "With": 1}
2
9
2
["pytest.raises", "replace_refs"]
0
[]
The function (test_circular_ref) defined within the public class called public.The function start at line 40 and ends at 48. It contains 8 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It has 2.0 functions ...
Sema4AI_actions
public
public
0
0
test_list_ref
def test_list_ref():from sema4ai.actions._remove_refs import replace_refsjson = {"a": [1],"b": {"$ref": "#/a"},}assert replace_refs(json) == {"a": [1], "b": [1]}
1
7
0
49
1
51
58
51
['json']
None
{"Assign": 1}
1
8
1
["replace_refs"]
0
[]
The function (test_list_ref) defined within the public class called public.The function start at line 51 and ends at 58. It contains 7 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 function called ...
Sema4AI_actions
public
public
0
0
test_deep_ref
def test_deep_ref():from sema4ai.actions._remove_refs import replace_refsjson = {"a": "string","b": {"$ref": "#/a"},"e": {"$ref": "#/d"},"c": {"$ref": "#/b"},"d": {"$ref": "#/c"},"f": {"$ref": "#/e"},}assert replace_refs(json) == {"a": "string","b": "string","c": "string","d": "string","e": "string","f": "string",}
1
18
0
92
1
61
79
61
['json']
None
{"Assign": 1}
1
19
1
["replace_refs"]
0
[]
The function (test_deep_ref) defined within the public class called public.The function start at line 61 and ends at 79. It contains 18 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 function called...
Sema4AI_actions
public
public
0
0
test_bad_ref
def test_bad_ref():from sema4ai.actions._remove_refs import JsonRefError, replace_refsjson = {"a": ["foobar"],"b": {"$ref": "#/a"},"c": {"$ref": "#/x"},}with pytest.raises(JsonRefError):replace_refs(json)
1
9
0
52
1
82
91
82
['json']
None
{"Assign": 1, "Expr": 1, "With": 1}
2
10
2
["pytest.raises", "replace_refs"]
0
[]
The function (test_bad_ref) defined within the public class called public.The function start at line 82 and ends at 91. It contains 9 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It has 2.0 functions calle...
Sema4AI_actions
public
public
0
0
test_reuse_main_lifecycle
def test_reuse_main_lifecycle(datadir, str_regression):target = datadir / "main.py"try:_output = subprocess.check_output([sys.executable, str(target)], cwd=str(datadir))# print(_output.decode("utf-8"))except CalledProcessError as err:print(err.stdout.decode("utf-8"))if err.stderr:print(err.stderr.decode("utf-8"))raise
3
11
2
71
2
6
17
6
datadir,str_regression
['_output', 'target']
None
{"Assign": 2, "Expr": 2, "If": 1, "Try": 1}
7
12
7
["subprocess.check_output", "str", "str", "print", "err.stdout.decode", "print", "err.stderr.decode"]
0
[]
The function (test_reuse_main_lifecycle) defined within the public class called public.The function start at line 6 and ends at 17. It contains 11 lines of code and it has a cyclomatic complexity of 3. It takes 2 parameters, represented as [6.0] and does not return any value. It declares 7.0 functions, and It has 7.0 ...
Sema4AI_actions
public
public
0
0
methoda
def methoda(a: str) -> int:"""This is methoda.Args:a: This is argument a."""return 1
1
2
1
12
0
8
15
8
a
[]
int
{"Expr": 1, "Return": 1}
0
8
0
[]
0
[]
The function (methoda) defined within the public class called public.The function start at line 8 and ends at 15. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
methodb
def methodb(a: str = "a") -> int:"""This is methodb.Args:a: This is argument a.Returns:The number 1."""return 1
1
2
1
14
0
18
28
18
a
[]
int
{"Expr": 1, "Return": 1}
0
11
0
[]
0
[]
The function (methodb) defined within the public class called public.The function start at line 18 and ends at 28. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
methodc
def methodc(a: int = 1) -> int:"""This is methodc.Args:a: This is argument a.Returns:The number 1."""return 1
1
2
1
14
0
31
41
31
a
[]
int
{"Expr": 1, "Return": 1}
0
11
0
[]
0
[]
The function (methodc) defined within the public class called public.The function start at line 31 and ends at 41. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_task_schema
def test_task_schema():from sema4ai.actions._action import Actiontask = Action(PluginManager(), __name__, __file__, methoda)input_schema = task.input_schemaassert input_schema == {"properties": {"a": {"title": "A", "type": "string", "description": "This is argument a."}},"required": ["a"],"type": "object",}task = Actio...
1
36
0
186
4
44
83
44
['input_schema', 'options', 'task', 'output_schema']
None
{"Assign": 8}
9
40
9
["Action", "PluginManager", "Action", "PluginManager", "Action", "PluginManager", "Action", "PluginManager", "dict"]
0
[]
The function (test_task_schema) defined within the public class called public.The function start at line 44 and ends at 83. It contains 36 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 9.0 functions, and It has 9.0 functions ...
Sema4AI_actions
public
public
0
0
test_task_schema_default_value_type
def test_task_schema_default_value_type():from sema4ai.actions._action import Actiontask = Action(PluginManager(), __name__, __file__, methodc)input_schema = task.input_schemaassert input_schema == {"properties": {"a": {"default": 1,"title": "A","type": "integer","description": "This is argument a.",}},"type": "object"...
1
15
0
65
2
86
101
86
['input_schema', 'task']
None
{"Assign": 2}
2
16
2
["Action", "PluginManager"]
0
[]
The function (test_task_schema_default_value_type) defined within the public class called public.The function start at line 86 and ends at 101. It contains 15 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and I...
Sema4AI_actions
public
public
0
0
unicode_ação_Σ
def unicode_ação_Σ(ação: int = 1) -> int:"""This is a method. In this methodthe description spans multiple linesand this must be properly supportedin the spec.Args:ação: This is an argumentReturns:The number 1."""return 1
1
2
1
14
0
104
117
104
ação
[]
int
{"Expr": 1, "Return": 1}
0
14
0
[]
0
[]
The function (unicode_ação_Σ) defined within the public class called public.The function start at line 104 and ends at 117. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_task_unicode
def test_task_unicode():from sema4ai.actions._action import Actiontask = Action(PluginManager(), __name__, __file__, unicode_ação_Σ)input_schema = task.input_schemaassert input_schema == {"properties": {"ação": {"type": "integer","description": "This is an argument","title": "Ação","default": 1,}},"type": "object",}
1
15
0
65
2
120
135
120
['input_schema', 'task']
None
{"Assign": 2}
2
16
2
["Action", "PluginManager"]
0
[]
The function (test_task_unicode) defined within the public class called public.The function start at line 120 and ends at 135. It contains 15 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It has 2.0 functio...
Sema4AI_actions
public
public
0
0
method_custom_type
def method_custom_type(a: MyCustomData) -> MyCustomData:return a
1
2
1
11
0
144
145
144
a
[]
MyCustomData
{"Return": 1}
0
2
0
[]
0
[]
The function (method_custom_type) defined within the public class called public.The function start at line 144 and ends at 145. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_task_schema_custom_type
def test_task_schema_custom_type():from sema4ai.actions._action import Actiontask = Action(PluginManager(), __name__, __file__, method_custom_type)input_schema = task.input_schemaassert input_schema == {"properties": {"a": {"properties": {"name": {"title": "Name", "type": "string"},"price": {"title": "Price", "type": "...
1
39
0
213
3
148
188
148
['input_schema', 'task', 'output_schema']
None
{"Assign": 3}
2
41
2
["Action", "PluginManager"]
0
[]
The function (test_task_schema_custom_type) defined within the public class called public.The function start at line 148 and ends at 188. It contains 39 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It has ...
Sema4AI_actions
public
public
0
0
method_custom_dependent_type
def method_custom_dependent_type(a: MyDataWithDependent) -> MyDataWithDependent:return a
1
2
1
11
0
200
201
200
a
[]
MyDataWithDependent
{"Return": 1}
0
2
0
[]
0
[]
The function (method_custom_dependent_type) defined within the public class called public.The function start at line 200 and ends at 201. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
Sema4AI_actions
public
public
0
0
test_task_schema_dependent_type
def test_task_schema_dependent_type():from sema4ai.actions._action import Actiontask = Action(PluginManager(), __name__, __file__, method_custom_dependent_type)input_schema = task.input_schemaassert input_schema == {"properties": {"a": {"properties": {"name": {"title": "Name", "type": "string"},"dependent": {"propertie...
1
39
0
201
3
204
244
204
['input_schema', 'task', 'output_schema']
None
{"Assign": 3}
2
41
2
["Action", "PluginManager"]
0
[]
The function (test_task_schema_dependent_type) defined within the public class called public.The function start at line 204 and ends at 244. It contains 39 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It h...
Sema4AI_actions
public
public
0
0
check
def check(datadir, args, msg="", returncode=1):from devutils.fixtures import sema4ai_actions_runresult = sema4ai_actions_run(["run", "--console-colors=plain"] + args,returncode=returncode,cwd=str(datadir),)stdout = result.stdout.decode("utf-8")if returncode:assert (msg), f'When an error is expected, the "msg" must be g...
2
13
4
72
2
5
20
5
datadir,args,msg,returncode
['stdout', 'result']
None
{"Assign": 2, "If": 1}
3
16
3
["sema4ai_actions_run", "str", "result.stdout.decode"]
873
["_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.3546011_hashdist_hashdist.hashdist.spec.tests.test_utils_py.test_substitute", "_.content.gdrive.MyDrive.Phd_Thesis.Dataset_Creation.Output.Cloned_Repo_3.3569128_timothycrosley_deprecated_frosted.frosted.api_py.check_path", "_.content.gdrive.MyD...
The function (check) defined within the public class called public.The function start at line 5 and ends at 20. It contains 13 lines of code and it has a cyclomatic complexity of 2. It takes 4 parameters, represented as [5.0] and does not return any value. It declares 3.0 functions, It has 3.0 functions called inside w...
Sema4AI_actions
public
public
0
0
test_tasks_arguments_json_input
def test_tasks_arguments_json_input(datadir, tmpdir) -> None:json_input = Path(tmpdir / "my.json")json_input.write_text(json.dumps({"s": "1"}))check(datadir, ["-a=accept_str", f"--json-input={json_input}"], returncode=0)json_input = Path(tmpdir / "my.json")json_input.write_text(json.dumps({"s": 1}))check(datadir,["-a=a...
1
12
2
88
1
23
37
23
datadir,tmpdir
['json_input']
None
{"Assign": 2, "Expr": 4}
8
15
8
["Path", "json_input.write_text", "json.dumps", "check", "Path", "json_input.write_text", "json.dumps", "check"]
0
[]
The function (test_tasks_arguments_json_input) defined within the public class called public.The function start at line 23 and ends at 37. It contains 12 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [23.0] and does not return any value. It declares 8.0 functions, and It ...
Sema4AI_actions
public
public
0
0
test_tasks_unicode
def test_tasks_unicode(datadir) -> None:check(datadir, ["-a=unicode_ação_Σ", "--", "--ação=1"], returncode=0)
1
2
1
23
0
40
41
40
datadir
[]
None
{"Expr": 1}
1
2
1
["check"]
0
[]
The function (test_tasks_unicode) defined within the public class called public.The function start at line 40 and ends at 41. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 function ca...
Sema4AI_actions
public
public
0
0
test_tasks_custom_data
def test_tasks_custom_data(datadir) -> None:custom = json.dumps({"name": "foo","price": 22,"is_offer": None,})check(datadir, ["-a=custom_data", "--", f"--data={custom}"], returncode=0)
1
9
1
45
1
44
52
44
datadir
['custom']
None
{"Assign": 1, "Expr": 1}
2
9
2
["json.dumps", "check"]
0
[]
The function (test_tasks_custom_data) defined within the public class called public.The function start at line 44 and ends at 52. It contains 9 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 2.0 functions, and It has 2.0 funct...
Sema4AI_actions
public
public
0
0
test_tasks_custom_bad_data
def test_tasks_custom_bad_data(datadir) -> None:check(datadir,["-a=custom_data", "--", "--data={error}"],returncode=1,msg="(error interpreting contents for data as a json)",)
1
7
1
28
0
55
61
55
datadir
[]
None
{"Expr": 1}
1
7
1
["check"]
0
[]
The function (test_tasks_custom_bad_data) defined within the public class called public.The function start at line 55 and ends at 61. It contains 7 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declare 1.0 function, and It has 1.0 fun...
Sema4AI_actions
public
public
0
0
test_tasks_arguments
def test_tasks_arguments(datadir) -> None:check(datadir, ["-a=accept_str", "--", "--s=1"], returncode=0)check(datadir,["-a=return_tuple"],"It's not possible to call: 'return_tuple' because the passed arguments don't match the expected signature.",)check(datadir,["-a=return_tuple", "--", "a=2"],"It's not possible to cal...
1
66
1
251
0
64
135
64
datadir
[]
None
{"Expr": 14}
14
72
14
["check", "check", "check", "check", "check", "check", "check", "check", "check", "check", "check", "check", "check", "check"]
0
[]
The function (test_tasks_arguments) defined within the public class called public.The function start at line 64 and ends at 135. It contains 66 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value. It declares 14.0 functions, and It has 14.0 fun...
Sema4AI_actions
public
public
0
0
test_tasks_mutable
def test_tasks_mutable(datadir) -> None:from devutils.fixtures import sema4ai_actions_runresult = sema4ai_actions_run(["run", "--console-colors=plain", "-a", "division_error"],returncode=0,cwd=str(datadir),)stdout = result.stdout.decode("utf-8")assert "division by zero" in stdoutresult = sema4ai_actions_run(["run", "--...
1
16
1
93
2
1
20
1
datadir
['stdout', 'result']
None
{"Assign": 4}
6
20
6
["sema4ai_actions_run", "str", "result.stdout.decode", "sema4ai_actions_run", "str", "result.stdout.decode"]
0
[]
The function (test_tasks_mutable) defined within the public class called public.The function start at line 1 and ends at 20. It contains 16 lines of code and it has a cyclomatic complexity of 1. It take 1 parameter, represented as [1.0] and does not return any value. It declares 6.0 functions, and It has 6.0 functions...
Sema4AI_actions
public
public
0
0
test_neverending_teardown
def test_neverending_teardown(datadir, arg) -> None:from devutils.fixtures import sema4ai_actions_runcmdline = ["run","--console-colors=plain",]additional_env: Optional[Dict[str, str]] = Noneif arg == "argument":cmdline.extend(("--teardown-dump-threads-timeout=0.5","--teardown-interrupt-timeout=1",))else:additional_env...
2
27
2
109
4
9
38
9
datadir,arg
['result', 'cmdline', 'stderr', 'additional_env']
None
{"AnnAssign": 1, "Assign": 4, "Expr": 1, "If": 1}
6
30
6
["cmdline.extend", "sema4ai_actions_run", "str", "result.stderr.decode", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_neverending_teardown) defined within the public class called public.The function start at line 9 and ends at 38. It contains 27 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [9.0] and does not return any value. It declares 6.0 functions, and It has 6.0 ...
Sema4AI_actions
public
public
0
0
test_neverending_teardown_just_interrupt
def test_neverending_teardown_just_interrupt(datadir, arg) -> None:from devutils.fixtures import sema4ai_actions_runcmdline = ["run","--console-colors=plain",]additional_env: Optional[Dict[str, str]] = Noneif arg == "argument":cmdline.extend(("--teardown-dump-threads-timeout=0","--teardown-interrupt-timeout=1",))else:a...
2
27
2
109
4
42
71
42
datadir,arg
['result', 'cmdline', 'stderr', 'additional_env']
None
{"AnnAssign": 1, "Assign": 4, "Expr": 1, "If": 1}
6
30
6
["cmdline.extend", "sema4ai_actions_run", "str", "result.stderr.decode", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_neverending_teardown_just_interrupt) defined within the public class called public.The function start at line 42 and ends at 71. It contains 27 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [42.0] and does not return any value. It declares 6.0 functions,...
Sema4AI_actions
public
public
0
0
test_neverending_teardown_just_dump_threads
def test_neverending_teardown_just_dump_threads(datadir, arg) -> None:from devutils.fixtures import sema4ai_actions_runcmdline = ["run","--console-colors=plain",]additional_env: Optional[Dict[str, str]] = Noneif arg == "argument":cmdline.extend(("--teardown-dump-threads-timeout=.5",))else:additional_env = {"RC_TEARDOWN...
2
24
2
131
3
75
102
75
datadir,arg
['cmdline', 'stderr', 'additional_env']
None
{"AnnAssign": 2, "Assign": 3, "Expr": 2, "If": 1, "With": 1}
8
28
8
["cmdline.extend", "pytest.raises", "sema4ai_actions_run", "str", "typing.cast", "stderr_bytes.decode", "stderr.count", "pytest.mark.parametrize"]
0
[]
The function (test_neverending_teardown_just_dump_threads) defined within the public class called public.The function start at line 75 and ends at 102. It contains 24 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [75.0] and does not return any value. It declares 8.0 functi...