omdev 0.0.0.dev176__py3-none-any.whl → 0.0.0.dev177__py3-none-any.whl

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.
omdev/interp/pyenv.py CHANGED
@@ -1,3 +1,4 @@
1
+ # ruff: noqa: UP006 UP007
1
2
  """
2
3
  TODO:
3
4
  - custom tags
@@ -9,7 +10,6 @@ TODO:
9
10
  - optionally install / upgrade pyenv itself
10
11
  - new vers dont need these custom mac opts, only run on old vers
11
12
  """
12
- # ruff: noqa: UP006 UP007
13
13
  import abc
14
14
  import dataclasses as dc
15
15
  import itertools
@@ -319,11 +319,11 @@ class PyenvVersionInstaller:
319
319
  full_args = [
320
320
  os.path.join(check.not_none(await self._pyenv.root()), 'plugins', 'python-build', 'bin', 'python-build'), # noqa
321
321
  *conf_args,
322
- self.install_dir(),
322
+ await self.install_dir(),
323
323
  ]
324
324
  else:
325
325
  full_args = [
326
- self._pyenv.exe(),
326
+ await self._pyenv.exe(),
327
327
  'install',
328
328
  *conf_args,
329
329
  ]
@@ -1,3 +1,4 @@
1
+ # ruff: noqa: UP006 UP007
1
2
  """
2
3
  TODO:
3
4
  - ~/.cache/omlish/interp/standalone/...
@@ -20,7 +21,6 @@ TODO:
20
21
  # COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
21
22
  # OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
23
  # https://github.com/tusharsadhwani/yen/blob/8d1bb0c1232c7b0159caefb1bf3a5348b93f7b43/src/yen/github.py
23
- # ruff: noqa: UP006 UP007
24
24
  import json
25
25
  import os.path
26
26
  import platform
@@ -91,6 +91,7 @@ class StandalonePythons:
91
91
 
92
92
  def fallback_release_data(self) -> GitHubReleaseData:
93
93
  """Returns the fallback release data, for when GitHub API gives an error."""
94
+
94
95
  log.warning('GitHub unreachable. Using fallback release data.')
95
96
  data_file = os.path.join(os.path.dirname(__file__), 'fallback_release_data.json')
96
97
  with open(data_file) as data:
@@ -101,6 +102,7 @@ class StandalonePythons:
101
102
 
102
103
  def get_latest_python_releases(self, is_linux_i686: bool) -> GitHubReleaseData:
103
104
  """Returns the list of python download links from the latest github release."""
105
+
104
106
  # They stopped shipping for 32 bit linux since after the 20230826 tag
105
107
  if is_linux_i686:
106
108
  data_file = os.path.join(os.path.dirname(__file__), 'linux_i686_release.json')
@@ -120,6 +122,7 @@ class StandalonePythons:
120
122
  @cached_nullary
121
123
  def list_pythons(self) -> ta.Mapping[str, str]:
122
124
  """Returns available python versions for your machine and their download links."""
125
+
123
126
  system, machine = platform.system(), platform.machine()
124
127
  download_link_suffixes = self.MACHINE_SUFFIX[system][machine]
125
128
  # linux suffixes are nested under glibc or musl builds
omdev/interp/system.py CHANGED
@@ -1,9 +1,9 @@
1
+ # ruff: noqa: UP006 UP007
1
2
  """
2
3
  TODO:
3
4
  - python, python3, python3.12, ...
4
5
  - check if path py's are venvs: sys.prefix != sys.base_prefix
5
6
  """
6
- # ruff: noqa: UP006 UP007
7
7
  import dataclasses as dc
8
8
  import os
9
9
  import re
omdev/interp/uv.py ADDED
@@ -0,0 +1,21 @@
1
+ # ruff: noqa: UP006 UP007
2
+ """
3
+ uv run pip
4
+ uv run --python 3.11.6 pip
5
+ uv venv --python 3.11.6 --seed barf
6
+ python3 -m venv barf && barf/bin/pip install uv && barf/bin/uv venv --python 3.11.6 --seed barf2
7
+ """
8
+ import typing as ta
9
+
10
+ from .providers import InterpProvider
11
+ from .types import Interp
12
+ from .types import InterpSpecifier
13
+ from .types import InterpVersion
14
+
15
+
16
+ class PyenvInterpProvider(InterpProvider):
17
+ def get_installed_versions(self, spec: InterpSpecifier) -> ta.Awaitable[ta.Sequence[InterpVersion]]:
18
+ raise NotImplementedError
19
+
20
+ def get_installed_version(self, version: InterpVersion) -> ta.Awaitable[Interp]:
21
+ raise NotImplementedError
omdev/scripts/interp.py CHANGED
@@ -3156,11 +3156,11 @@ class PyenvVersionInstaller:
3156
3156
  full_args = [
3157
3157
  os.path.join(check.not_none(await self._pyenv.root()), 'plugins', 'python-build', 'bin', 'python-build'), # noqa
3158
3158
  *conf_args,
3159
- self.install_dir(),
3159
+ await self.install_dir(),
3160
3160
  ]
3161
3161
  else:
3162
3162
  full_args = [
3163
- self._pyenv.exe(),
3163
+ await self._pyenv.exe(),
3164
3164
  'install',
3165
3165
  *conf_args,
3166
3166
  ]
@@ -6360,11 +6360,11 @@ class PyenvVersionInstaller:
6360
6360
  full_args = [
6361
6361
  os.path.join(check.not_none(await self._pyenv.root()), 'plugins', 'python-build', 'bin', 'python-build'), # noqa
6362
6362
  *conf_args,
6363
- self.install_dir(),
6363
+ await self.install_dir(),
6364
6364
  ]
6365
6365
  else:
6366
6366
  full_args = [
6367
- self._pyenv.exe(),
6367
+ await self._pyenv.exe(),
6368
6368
  'install',
6369
6369
  *conf_args,
6370
6370
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: omdev
3
- Version: 0.0.0.dev176
3
+ Version: 0.0.0.dev177
4
4
  Summary: omdev
5
5
  Author: wrmsr
6
6
  License: BSD-3-Clause
@@ -12,7 +12,7 @@ Classifier: Operating System :: OS Independent
12
12
  Classifier: Operating System :: POSIX
13
13
  Requires-Python: >=3.12
14
14
  License-File: LICENSE
15
- Requires-Dist: omlish==0.0.0.dev176
15
+ Requires-Dist: omlish==0.0.0.dev177
16
16
  Provides-Extra: all
17
17
  Requires-Dist: black~=24.10; extra == "all"
18
18
  Requires-Dist: pycparser~=2.22; extra == "all"
@@ -85,11 +85,12 @@ omdev/interp/__main__.py,sha256=GMCqeGYltgt5dlJzHxY9gqisa8cRkrPfmZYuZnjg4WI,162
85
85
  omdev/interp/cli.py,sha256=kgqA-Pc2RVkvkEpAKde30R5JKemgwurUcG6uPaNJyFc,2234
86
86
  omdev/interp/inspect.py,sha256=ORfO90xfGftyvEJHuEOD5yPk-9mxdxn27SYHwZywWFI,2888
87
87
  omdev/interp/providers.py,sha256=yHZQ6gYjkvSmMBvrKy3I77D7PnW67Bf3igTKY8DD9K4,1839
88
- omdev/interp/pyenv.py,sha256=8SromtT5y6f5q0hT__-r5PZSOHg-PQc-6t-ITdS5eo4,14302
88
+ omdev/interp/pyenv.py,sha256=KgsAwVNdse8UAR_6Lt4V4Zxqgm-kteOpJHxiD5vKc4M,14314
89
89
  omdev/interp/resolvers.py,sha256=_xxmf9KrWg5Zpi4UjAMKMB8UgrXLq_sJ2Y5qpNhLjqw,3091
90
- omdev/interp/standalone.py,sha256=As4sDe9_Iq0b00Q28BaiEjnk9pRR6qq1fjSKnveqgfc,7722
91
- omdev/interp/system.py,sha256=-ihkrZbUFpnZu0Au4kQbl5oqQSXDtGabTTmn7fhTBts,3561
90
+ omdev/interp/standalone.py,sha256=jJnncea4PIuaW-KwD2YiWDn8zTmwmsJNUKpF-qC2bwo,7725
91
+ omdev/interp/system.py,sha256=-sIbIPgmDU9jKw_nw-zTgOertDJTJ6BwJ-i6fU81KsY,3561
92
92
  omdev/interp/types.py,sha256=5dFGYyaCrXN-VL43PhBvlEti97fYW3EzfBmK9N4Wmdo,2496
93
+ omdev/interp/uv.py,sha256=6EF5i_n530F9KUa99xT6RB8vF6FSqElDHu3lbk1ppBo,662
93
94
  omdev/magic/__init__.py,sha256=CBzRB71RLyylkrj8dph6JUEddA8KSMJvDgriHqFfJGU,478
94
95
  omdev/magic/find.py,sha256=tTmpWXAleaXG3_kNOsRF7s8D0CpYMXbdz6-HbCNBW90,7070
95
96
  omdev/magic/magic.py,sha256=h1nxoW6CV1MRCiHjDt3sO4kmG0qTtTRbkDNiPLGo2BE,224
@@ -134,8 +135,8 @@ omdev/scripts/bumpversion.py,sha256=Kn7fo73Hs8uJh3Hi3EIyLOlzLPWAC6dwuD_lZ3cIzuY,
134
135
  omdev/scripts/execrss.py,sha256=mR0G0wERBYtQmVIn63lCIIFb5zkCM6X_XOENDFYDBKc,651
135
136
  omdev/scripts/exectime.py,sha256=sFb376GflU6s9gNX-2-we8hgH6w5MuQNS9g6i4SqJIo,610
136
137
  omdev/scripts/importtrace.py,sha256=oa7CtcWJVMNDbyIEiRHej6ICfABfErMeo4_haIqe18Q,14041
137
- omdev/scripts/interp.py,sha256=Bdtcovhk8Sa8-LmbGyz5TLty7RI3W_DAjxjGQJUvR6s,100905
138
- omdev/scripts/pyproject.py,sha256=5hSzhpGKKT5lo0tj9zXXUFERx-3DwZgi7yP6QtXvnto,207450
138
+ omdev/scripts/interp.py,sha256=ReEfpyIB5UfJXFdnOLylO1czk51ZoskoNkSQkjaQ4CA,100917
139
+ omdev/scripts/pyproject.py,sha256=y-E70h9al-ijgogYqTlCqmMT53o0iW8D2F2MjPFuKuU,207462
139
140
  omdev/scripts/slowcat.py,sha256=lssv4yrgJHiWfOiHkUut2p8E8Tq32zB-ujXESQxFFHY,2728
140
141
  omdev/scripts/tmpexec.py,sha256=WTYcf56Tj2qjYV14AWmV8SfT0u6Y8eIU6cKgQRvEK3c,1442
141
142
  omdev/toml/__init__.py,sha256=Y3l4WY4JRi2uLG6kgbGp93fuGfkxkKwZDvhsa0Rwgtk,15
@@ -164,9 +165,9 @@ omdev/tools/json/rendering.py,sha256=jNShMfCpFR9-Kcn6cUFuOChXHjg71diuTC4x7Ofmz-o
164
165
  omdev/tools/pawk/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
165
166
  omdev/tools/pawk/__main__.py,sha256=VCqeRVnqT1RPEoIrqHFSu4PXVMg4YEgF4qCQm90-eRI,66
166
167
  omdev/tools/pawk/pawk.py,sha256=Eckymn22GfychCQcQi96BFqRo_LmiJ-EPhC8TTUJdB4,11446
167
- omdev-0.0.0.dev176.dist-info/LICENSE,sha256=B_hVtavaA8zCYDW99DYdcpDLKz1n3BBRjZrcbv8uG8c,1451
168
- omdev-0.0.0.dev176.dist-info/METADATA,sha256=yyLcm4nKv0osVHnZgppOaJP0ryA3NbBLqf9T9lNUzV8,1760
169
- omdev-0.0.0.dev176.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
170
- omdev-0.0.0.dev176.dist-info/entry_points.txt,sha256=dHLXFmq5D9B8qUyhRtFqTGWGxlbx3t5ejedjrnXNYLU,33
171
- omdev-0.0.0.dev176.dist-info/top_level.txt,sha256=1nr7j30fEWgLYHW3lGR9pkdHkb7knv1U1ES1XRNVQ6k,6
172
- omdev-0.0.0.dev176.dist-info/RECORD,,
168
+ omdev-0.0.0.dev177.dist-info/LICENSE,sha256=B_hVtavaA8zCYDW99DYdcpDLKz1n3BBRjZrcbv8uG8c,1451
169
+ omdev-0.0.0.dev177.dist-info/METADATA,sha256=Kg8GR5oTBzACAwXukDJ3oLe71RG42r87qe_3H8R1M64,1760
170
+ omdev-0.0.0.dev177.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
171
+ omdev-0.0.0.dev177.dist-info/entry_points.txt,sha256=dHLXFmq5D9B8qUyhRtFqTGWGxlbx3t5ejedjrnXNYLU,33
172
+ omdev-0.0.0.dev177.dist-info/top_level.txt,sha256=1nr7j30fEWgLYHW3lGR9pkdHkb7knv1U1ES1XRNVQ6k,6
173
+ omdev-0.0.0.dev177.dist-info/RECORD,,