codelexity 0.2.0__tar.gz → 0.2.2__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: codelexity
3
- Version: 0.2.0
3
+ Version: 0.2.2
4
4
  Summary: A package that measures code complexity in the age of AI slop.
5
5
  Keywords: complexity,halstead,maintainability,cyclomatic,static-analysis,metrics
6
6
  License-Expression: MIT
@@ -25,7 +25,7 @@ Description-Content-Type: text/markdown
25
25
  # `Codelexity`
26
26
 
27
27
  ![version](https://img.shields.io/pypi/v/codelexity)
28
- ![coverage](https://img.shields.io/badge/coverage-77%25-green)
28
+ ![coverage](https://img.shields.io/badge/coverage-70%25-green)
29
29
  ![python](https://img.shields.io/badge/python-3.11%2B-blue)
30
30
 
31
31
  A python package that helps you measure, visualize and ultimately manage code complexity.
@@ -3,7 +3,7 @@
3
3
  # `Codelexity`
4
4
 
5
5
  ![version](https://img.shields.io/pypi/v/codelexity)
6
- ![coverage](https://img.shields.io/badge/coverage-77%25-green)
6
+ ![coverage](https://img.shields.io/badge/coverage-70%25-green)
7
7
  ![python](https://img.shields.io/badge/python-3.11%2B-blue)
8
8
 
9
9
  A python package that helps you measure, visualize and ultimately manage code complexity.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "codelexity"
3
- version = "0.2.0"
3
+ version = "0.2.2"
4
4
  description = "A package that measures code complexity in the age of AI slop."
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.11"
@@ -43,7 +43,7 @@ path = "src"
43
43
  editable = true
44
44
 
45
45
  [tool.bumpver]
46
- current_version = "0.2.0"
46
+ current_version = "0.2.2"
47
47
  version_pattern = "MAJOR.MINOR.PATCH"
48
48
  push = false
49
49
 
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "codelexity"
3
- version = "0.2.0"
3
+ version = "0.2.2"
4
4
  description = "A package that measures code complexity in the age of AI slop."
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.11"
@@ -48,7 +48,7 @@ dev = [
48
48
  ]
49
49
 
50
50
  [tool.bumpver]
51
- current_version = "0.2.0"
51
+ current_version = "0.2.2"
52
52
  version_pattern = "MAJOR.MINOR.PATCH"
53
53
  push = false # inspect the tag before it leaves the machine
54
54
 
@@ -108,7 +108,7 @@ def _resolve(name, search):
108
108
  def imports(module_path, root=None):
109
109
  """Full filesystem paths of the local modules `module_path` imports."""
110
110
  path = Path(module_path).resolve()
111
- code = compile(path.read_text(), str(path), "exec")
111
+ code = compile(path.read_text(encoding="utf-8"), str(path), "exec")
112
112
  root = Path(root).resolve() if root else path.parent
113
113
  search = sys.path + [str(root), *(str(d) for d in root.rglob("*") if d.is_dir())]
114
114
  names = {n for n in _import_names(code) if n.split(".")[0] not in sys.builtin_module_names}
@@ -118,7 +118,7 @@ def imports(module_path, root=None):
118
118
 
119
119
  def analyze_module(path, root=None):
120
120
  pth = Path(path).resolve()
121
- st = pth.open().read()
121
+ st = pth.read_text(encoding="utf-8")
122
122
  total, empty, comments = (
123
123
  len(st.split("\n")),
124
124
  len(empty_lines(st)),
File without changes