wexample-filestate-python 8.1.1__tar.gz → 8.2.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (95) hide show
  1. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/PKG-INFO +4 -4
  2. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/README.md +2 -2
  3. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/pyproject.toml +2 -2
  4. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/file/python_test_stub_file.py +12 -22
  5. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/__init__.py +0 -0
  6. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/__pycache__/__init__.py +0 -0
  7. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/common/__init__.py +0 -0
  8. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/common/__pycache__/__init__.py +0 -0
  9. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/common/pipy_gateway.py +0 -0
  10. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_option/__init__.py +0 -0
  11. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_option/__pycache__/__init__.py +0 -0
  12. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_option/mixin/__init__.py +0 -0
  13. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_option/mixin/__pycache__/__init__.py +0 -0
  14. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_option/mixin/with_stdout_wrapping_mixin.py +0 -0
  15. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_value/__init__.py +0 -0
  16. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_value/__pycache__/__init__.py +0 -0
  17. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/config_value/python_config_value.py +0 -0
  18. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/const/__init__.py +0 -0
  19. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/const/__pycache__/__init__.py +0 -0
  20. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/const/name_pattern.py +0 -0
  21. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/const/path.py +0 -0
  22. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/const/python_file.py +0 -0
  23. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/event/__init__.py +0 -0
  24. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/event/src/__init__.py +0 -0
  25. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/event/src/wexample_event/__init__.py +0 -0
  26. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/file/__init__.py +0 -0
  27. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/file/__pycache__/__init__.py +0 -0
  28. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/file/python_file.py +0 -0
  29. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/helpers/__init__.py +0 -0
  30. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/helpers/__pycache__/__init__.py +0 -0
  31. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/helpers/package.py +0 -0
  32. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/helpers/python/__init__.py +0 -0
  33. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/helpers/toml.py +0 -0
  34. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/__init__.py +0 -0
  35. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/__pycache__/__init__.py +0 -0
  36. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/__init__.py +0 -0
  37. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/abstract_python_file_content_option.py +0 -0
  38. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/add_future_annotations_option.py +0 -0
  39. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/add_return_types_option.py +0 -0
  40. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/class_name_matches_file_name_option.py +0 -0
  41. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/fix_attrs_option.py +0 -0
  42. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/fix_blank_lines_option.py +0 -0
  43. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/format_option.py +0 -0
  44. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/fstringify_option.py +0 -0
  45. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/modernize_typing_option.py +0 -0
  46. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_class_attributes_option.py +0 -0
  47. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_class_docstring_option.py +0 -0
  48. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_class_methods_option.py +0 -0
  49. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_constants_option.py +0 -0
  50. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_iterable_items_option.py +0 -0
  51. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_main_guard_option.py +0 -0
  52. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_module_docstring_option.py +0 -0
  53. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_module_functions_option.py +0 -0
  54. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_module_metadata_option.py +0 -0
  55. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/order_type_checking_block_option.py +0 -0
  56. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/relocate_imports_option.py +0 -0
  57. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/remove_unused_option.py +0 -0
  58. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/sort_imports_option.py +0 -0
  59. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python/unquote_annotations_option.py +0 -0
  60. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/option/python_option.py +0 -0
  61. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/options_provider/__init__.py +0 -0
  62. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/options_provider/__pycache__/__init__.py +0 -0
  63. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/options_provider/python_options_provider.py +0 -0
  64. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/py.typed +0 -0
  65. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/__init__.py +0 -0
  66. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/__pycache__/__init__.py +0 -0
  67. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/cst_cache.py +0 -0
  68. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_attrs_utils.py +0 -0
  69. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_blank_lines_utils.py +0 -0
  70. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_class_attributes_utils.py +0 -0
  71. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_class_docstring_utils.py +0 -0
  72. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_class_methods_utils.py +0 -0
  73. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_constants_utils.py +0 -0
  74. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_docstring_utils.py +0 -0
  75. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_functions_utils.py +0 -0
  76. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_iterable_utils.py +0 -0
  77. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_main_guard_utils.py +0 -0
  78. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_module_metadata_utils.py +0 -0
  79. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/python_type_checking_utils.py +0 -0
  80. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/__init__.py +0 -0
  81. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/__pycache__/__init__.py +0 -0
  82. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/python_import_rewriter.py +0 -0
  83. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/python_localize_runtime_imports.py +0 -0
  84. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/python_parser_import_index.py +0 -0
  85. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/python_runtime_symbol_collector.py +0 -0
  86. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/src/wexample_filestate_python/utils/relocate_imports/python_usage_collector.py +0 -0
  87. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/helpers/__init__.py +0 -0
  88. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/helpers/test_package.py +0 -0
  89. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/helpers/test_toml.py +0 -0
  90. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/tests/__init__.py +0 -0
  91. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/unit/__init__.py +0 -0
  92. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/unit/helpers/__init__.py +0 -0
  93. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/unit/helpers/test_package.py +0 -0
  94. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/unit/helpers/test_toml.py +0 -0
  95. {wexample_filestate_python-8.1.1 → wexample_filestate_python-8.2.1}/tests/wexample_tests/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wexample-filestate-python
3
- Version: 8.1.1
3
+ Version: 8.2.1
4
4
  Summary: Helpers for Python.
5
5
  Author-Email: weeger <contact@wexample.com>
6
6
  License: MIT
@@ -19,7 +19,7 @@ Requires-Dist: libcst
19
19
  Requires-Dist: packaging
20
20
  Requires-Dist: tomli
21
21
  Requires-Dist: wexample-api>=6.6.0
22
- Requires-Dist: wexample-filestate>=14.1.0
22
+ Requires-Dist: wexample-filestate>=15.0.0
23
23
  Provides-Extra: dev
24
24
  Requires-Dist: pytest; extra == "dev"
25
25
  Requires-Dist: pytest-cov; extra == "dev"
@@ -27,7 +27,7 @@ Description-Content-Type: text/markdown
27
27
 
28
28
  # filestate_python
29
29
 
30
- Version: 8.1.1
30
+ Version: 8.2.1
31
31
 
32
32
  Helpers for Python.
33
33
 
@@ -117,7 +117,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
117
117
  - packaging:
118
118
  - tomli:
119
119
  - wexample-api: >=6.6.0
120
- - wexample-filestate: >=14.1.0
120
+ - wexample-filestate: >=15.0.0
121
121
 
122
122
  ## Versioning & Compatibility Policy
123
123
 
@@ -1,6 +1,6 @@
1
1
  # filestate_python
2
2
 
3
- Version: 8.1.1
3
+ Version: 8.2.1
4
4
 
5
5
  Helpers for Python.
6
6
 
@@ -90,7 +90,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
90
90
  - packaging:
91
91
  - tomli:
92
92
  - wexample-api: >=6.6.0
93
- - wexample-filestate: >=14.1.0
93
+ - wexample-filestate: >=15.0.0
94
94
 
95
95
  ## Versioning & Compatibility Policy
96
96
 
@@ -6,7 +6,7 @@ build-backend = "pdm.backend"
6
6
 
7
7
  [project]
8
8
  name = "wexample-filestate-python"
9
- version = "8.1.1"
9
+ version = "8.2.1"
10
10
  description = "Helpers for Python."
11
11
  authors = [
12
12
  { name = "weeger", email = "contact@wexample.com" },
@@ -28,7 +28,7 @@ dependencies = [
28
28
  "packaging",
29
29
  "tomli",
30
30
  "wexample-api>=6.6.0",
31
- "wexample-filestate>=14.1.0",
31
+ "wexample-filestate>=15.0.0",
32
32
  ]
33
33
 
34
34
  [project.readme]
@@ -5,9 +5,7 @@ from wexample_helpers.decorator.base_class import base_class
5
5
  from wexample_filestate_python.file.python_file import PythonFile
6
6
 
7
7
 
8
- def _is_skippable_class(class_name: str, class_node) -> bool:
9
- import libcst as cst
10
-
8
+ def _is_skippable_class(class_name: str, class_node, cst) -> bool:
11
9
  if class_name.startswith("Abstract"):
12
10
  return True
13
11
  for decorator in class_node.decorators:
@@ -23,9 +21,7 @@ def _is_skippable_class(class_name: str, class_node) -> bool:
23
21
  return False
24
22
 
25
23
 
26
- def _public_function_names(module) -> list[str]:
27
- import libcst as cst
28
-
24
+ def _public_function_names(module, cst) -> list[str]:
29
25
  return [
30
26
  node.name.value
31
27
  for node in module.body
@@ -33,9 +29,7 @@ def _public_function_names(module) -> list[str]:
33
29
  ]
34
30
 
35
31
 
36
- def _public_method_names(class_node) -> list[str]:
37
- import libcst as cst
38
-
32
+ def _public_method_names(class_node, cst) -> list[str]:
39
33
  statements = getattr(class_node.body, "body", ())
40
34
  return [
41
35
  stmt.name.value
@@ -56,30 +50,26 @@ def _render_stub(primary_module_name: str, module) -> str:
56
50
  for node in module.body:
57
51
  if isinstance(node, cst.ClassDef):
58
52
  class_name = node.name.value
59
- if _is_skippable_class(class_name, node):
53
+ if _is_skippable_class(class_name, node, cst):
60
54
  continue
61
- methods = _public_method_names(node)
55
+ methods = _public_method_names(node, cst)
62
56
  if not methods:
63
57
  continue
64
58
  lines.append(f"class Test{class_name}:")
65
59
  for method_name in methods:
66
- lines.extend([
67
- f" def test_{method_name}(self) -> None:",
68
- " pass",
69
- "",
70
- ])
60
+ lines.append(f" def test_{method_name}(self) -> None:")
61
+ lines.append(" pass")
62
+ lines.append("")
71
63
  classes_emitted = True
72
64
 
73
- func_names = _public_function_names(module)
65
+ func_names = _public_function_names(module, cst)
74
66
  if func_names:
75
67
  if classes_emitted:
76
68
  lines.append("")
77
69
  for func_name in func_names:
78
- lines.extend([
79
- f"def test_{func_name}() -> None:",
80
- " pass",
81
- "",
82
- ])
70
+ lines.append(f"def test_{func_name}() -> None:")
71
+ lines.append(" pass")
72
+ lines.append("")
83
73
 
84
74
  if not classes_emitted and not func_names:
85
75
  # No public surface — emit a placeholder so the file is valid pytest