ominfra 0.0.0.dev121__tar.gz → 0.0.0.dev122__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
Files changed (96) hide show
  1. {ominfra-0.0.0.dev121/ominfra.egg-info → ominfra-0.0.0.dev122}/PKG-INFO +3 -3
  2. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/_executor.py +9 -0
  3. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/pyremote/_runcommands.py +9 -0
  4. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/scripts/journald2aws.py +8 -0
  5. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/scripts/supervisor.py +13 -1
  6. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122/ominfra.egg-info}/PKG-INFO +3 -3
  7. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra.egg-info/requires.txt +2 -2
  8. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/pyproject.toml +3 -3
  9. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/LICENSE +0 -0
  10. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/MANIFEST.in +0 -0
  11. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/README.rst +0 -0
  12. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/.manifests.json +0 -0
  13. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/__about__.py +0 -0
  14. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/__init__.py +0 -0
  15. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/__init__.py +0 -0
  16. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/__init__.py +0 -0
  17. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/__main__.py +0 -0
  18. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/auth.py +0 -0
  19. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/cli.py +0 -0
  20. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/dataclasses.py +0 -0
  21. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/__init__.py +0 -0
  22. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/__main__.py +0 -0
  23. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/cursor.py +0 -0
  24. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/driver.py +0 -0
  25. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/main.py +0 -0
  26. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/journald2aws/poster.py +0 -0
  27. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/logs.py +0 -0
  28. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/aws/metadata.py +0 -0
  29. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/gcp/__init__.py +0 -0
  30. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/clouds/gcp/auth.py +0 -0
  31. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/cmds.py +0 -0
  32. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/configs.py +0 -0
  33. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/__init__.py +0 -0
  34. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/configs.py +0 -0
  35. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/__init__.py +0 -0
  36. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/base.py +0 -0
  37. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/__init__.py +0 -0
  38. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/dirs.py +0 -0
  39. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/nginx.py +0 -0
  40. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/repo.py +0 -0
  41. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/supervisor.py +0 -0
  42. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/systemd.py +0 -0
  43. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/user.py +0 -0
  44. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/concerns/venv.py +0 -0
  45. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/executor/main.py +0 -0
  46. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/__init__.py +0 -0
  47. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/_main.py +0 -0
  48. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/base.py +0 -0
  49. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/configs.py +0 -0
  50. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/deploy.py +0 -0
  51. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/main.py +0 -0
  52. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/nginx.py +0 -0
  53. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/repo.py +0 -0
  54. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/runtime.py +0 -0
  55. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/site.py +0 -0
  56. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/supervisor.py +0 -0
  57. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/poly/venv.py +0 -0
  58. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/deploy/remote.py +0 -0
  59. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/journald/__init__.py +0 -0
  60. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/journald/fields.py +0 -0
  61. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/journald/genmessages.py +0 -0
  62. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/journald/messages.py +0 -0
  63. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/journald/tailer.py +0 -0
  64. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/manage/__init__.py +0 -0
  65. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/manage/manage.py +0 -0
  66. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/pyremote/__init__.py +0 -0
  67. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/pyremote/bootstrap.py +0 -0
  68. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/pyremote/runcommands.py +0 -0
  69. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/scripts/__init__.py +0 -0
  70. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/ssh.py +0 -0
  71. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/__init__.py +0 -0
  72. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/__main__.py +0 -0
  73. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/compat.py +0 -0
  74. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/configs.py +0 -0
  75. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/context.py +0 -0
  76. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/datatypes.py +0 -0
  77. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/dispatchers.py +0 -0
  78. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/events.py +0 -0
  79. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/exceptions.py +0 -0
  80. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/main.py +0 -0
  81. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/poller.py +0 -0
  82. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/process.py +0 -0
  83. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/states.py +0 -0
  84. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/supervisor.py +0 -0
  85. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/supervisor/types.py +0 -0
  86. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/tailscale/__init__.py +0 -0
  87. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/tailscale/api.py +0 -0
  88. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/tailscale/cli.py +0 -0
  89. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/threadworkers.py +0 -0
  90. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/tools/__init__.py +0 -0
  91. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra/tools/listresources.py +0 -0
  92. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra.egg-info/SOURCES.txt +0 -0
  93. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra.egg-info/dependency_links.txt +0 -0
  94. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra.egg-info/entry_points.txt +0 -0
  95. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/ominfra.egg-info/top_level.txt +0 -0
  96. {ominfra-0.0.0.dev121 → ominfra-0.0.0.dev122}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ominfra
3
- Version: 0.0.0.dev121
3
+ Version: 0.0.0.dev122
4
4
  Summary: ominfra
5
5
  Author: wrmsr
6
6
  License: BSD-3-Clause
@@ -12,8 +12,8 @@ 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: omdev==0.0.0.dev121
16
- Requires-Dist: omlish==0.0.0.dev121
15
+ Requires-Dist: omdev==0.0.0.dev122
16
+ Requires-Dist: omlish==0.0.0.dev122
17
17
  Provides-Extra: all
18
18
  Requires-Dist: paramiko~=3.5; extra == "all"
19
19
  Requires-Dist: asyncssh~=2.18; extra == "all"
@@ -66,6 +66,7 @@ import subprocess
66
66
  import sys
67
67
  import textwrap
68
68
  import threading
69
+ import types
69
70
  import typing as ta
70
71
  import uuid
71
72
  import weakref # noqa
@@ -255,6 +256,14 @@ def get_optional_alias_arg(spec: ta.Any) -> ta.Any:
255
256
  return it
256
257
 
257
258
 
259
+ def is_new_type(spec: ta.Any) -> bool:
260
+ if isinstance(ta.NewType, type):
261
+ return isinstance(spec, ta.NewType)
262
+ else:
263
+ # Before https://github.com/python/cpython/commit/c2f33dfc83ab270412bf243fb21f724037effa1a
264
+ return isinstance(spec, types.FunctionType) and spec.__code__ is ta.NewType.__code__.co_consts[1] # type: ignore # noqa
265
+
266
+
258
267
  def deep_subclasses(cls: ta.Type[T]) -> ta.Iterator[ta.Type[T]]:
259
268
  seen = set()
260
269
  todo = list(reversed(cls.__subclasses__()))
@@ -24,6 +24,7 @@ import subprocess
24
24
  import sys
25
25
  import textwrap
26
26
  import threading
27
+ import types
27
28
  import typing as ta
28
29
  import uuid
29
30
  import weakref # noqa
@@ -338,6 +339,14 @@ def get_optional_alias_arg(spec: ta.Any) -> ta.Any:
338
339
  return it
339
340
 
340
341
 
342
+ def is_new_type(spec: ta.Any) -> bool:
343
+ if isinstance(ta.NewType, type):
344
+ return isinstance(spec, ta.NewType)
345
+ else:
346
+ # Before https://github.com/python/cpython/commit/c2f33dfc83ab270412bf243fb21f724037effa1a
347
+ return isinstance(spec, types.FunctionType) and spec.__code__ is ta.NewType.__code__.co_consts[1] # type: ignore # noqa
348
+
349
+
341
350
  def deep_subclasses(cls: ta.Type[T]) -> ta.Iterator[ta.Type[T]]:
342
351
  seen = set()
343
352
  todo = list(reversed(cls.__subclasses__()))
@@ -1102,6 +1102,14 @@ def get_optional_alias_arg(spec: ta.Any) -> ta.Any:
1102
1102
  return it
1103
1103
 
1104
1104
 
1105
+ def is_new_type(spec: ta.Any) -> bool:
1106
+ if isinstance(ta.NewType, type):
1107
+ return isinstance(spec, ta.NewType)
1108
+ else:
1109
+ # Before https://github.com/python/cpython/commit/c2f33dfc83ab270412bf243fb21f724037effa1a
1110
+ return isinstance(spec, types.FunctionType) and spec.__code__ is ta.NewType.__code__.co_consts[1] # type: ignore # noqa
1111
+
1112
+
1105
1113
  def deep_subclasses(cls: ta.Type[T]) -> ta.Iterator[ta.Type[T]]:
1106
1114
  seen = set()
1107
1115
  todo = list(reversed(cls.__subclasses__()))
@@ -1511,6 +1511,14 @@ def get_optional_alias_arg(spec: ta.Any) -> ta.Any:
1511
1511
  return it
1512
1512
 
1513
1513
 
1514
+ def is_new_type(spec: ta.Any) -> bool:
1515
+ if isinstance(ta.NewType, type):
1516
+ return isinstance(spec, ta.NewType)
1517
+ else:
1518
+ # Before https://github.com/python/cpython/commit/c2f33dfc83ab270412bf243fb21f724037effa1a
1519
+ return isinstance(spec, types.FunctionType) and spec.__code__ is ta.NewType.__code__.co_consts[1] # type: ignore # noqa
1520
+
1521
+
1514
1522
  def deep_subclasses(cls: ta.Type[T]) -> ta.Iterator[ta.Type[T]]:
1515
1523
  seen = set()
1516
1524
  todo = list(reversed(cls.__subclasses__()))
@@ -1687,7 +1695,7 @@ def as_injector_key(o: ta.Any) -> InjectorKey:
1687
1695
  raise TypeError(o)
1688
1696
  if isinstance(o, InjectorKey):
1689
1697
  return o
1690
- if isinstance(o, (type, ta.NewType)):
1698
+ if isinstance(o, type) or is_new_type(o):
1691
1699
  return InjectorKey(o)
1692
1700
  raise TypeError(o)
1693
1701
 
@@ -1803,6 +1811,7 @@ class _InjectorBindings(InjectorBindings):
1803
1811
  def as_injector_bindings(*args: InjectorBindingOrBindings) -> InjectorBindings:
1804
1812
  bs: ta.List[InjectorBinding] = []
1805
1813
  ps: ta.List[InjectorBindings] = []
1814
+
1806
1815
  for a in args:
1807
1816
  if isinstance(a, InjectorBindings):
1808
1817
  ps.append(a)
@@ -1810,6 +1819,7 @@ def as_injector_bindings(*args: InjectorBindingOrBindings) -> InjectorBindings:
1810
1819
  bs.append(a)
1811
1820
  else:
1812
1821
  raise TypeError(a)
1822
+
1813
1823
  return _InjectorBindings(
1814
1824
  bs or None,
1815
1825
  ps or None,
@@ -1831,10 +1841,12 @@ class OverridesInjectorBindings(InjectorBindings):
1831
1841
 
1832
1842
  def injector_override(p: InjectorBindings, *args: InjectorBindingOrBindings) -> InjectorBindings:
1833
1843
  m: ta.Dict[InjectorKey, InjectorBinding] = {}
1844
+
1834
1845
  for b in as_injector_bindings(*args).bindings():
1835
1846
  if b.key in m:
1836
1847
  raise DuplicateInjectorKeyError(b.key)
1837
1848
  m[b.key] = b
1849
+
1838
1850
  return OverridesInjectorBindings(p, m)
1839
1851
 
1840
1852
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ominfra
3
- Version: 0.0.0.dev121
3
+ Version: 0.0.0.dev122
4
4
  Summary: ominfra
5
5
  Author: wrmsr
6
6
  License: BSD-3-Clause
@@ -12,8 +12,8 @@ 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: omdev==0.0.0.dev121
16
- Requires-Dist: omlish==0.0.0.dev121
15
+ Requires-Dist: omdev==0.0.0.dev122
16
+ Requires-Dist: omlish==0.0.0.dev122
17
17
  Provides-Extra: all
18
18
  Requires-Dist: paramiko~=3.5; extra == "all"
19
19
  Requires-Dist: asyncssh~=2.18; extra == "all"
@@ -1,5 +1,5 @@
1
- omdev==0.0.0.dev121
2
- omlish==0.0.0.dev121
1
+ omdev==0.0.0.dev122
2
+ omlish==0.0.0.dev122
3
3
 
4
4
  [all]
5
5
  paramiko~=3.5
@@ -12,7 +12,7 @@ authors = [
12
12
  urls = {source = 'https://github.com/wrmsr/omlish'}
13
13
  license = {text = 'BSD-3-Clause'}
14
14
  requires-python = '>=3.12'
15
- version = '0.0.0.dev121'
15
+ version = '0.0.0.dev122'
16
16
  classifiers = [
17
17
  'License :: OSI Approved :: BSD License',
18
18
  'Development Status :: 2 - Pre-Alpha',
@@ -22,8 +22,8 @@ classifiers = [
22
22
  ]
23
23
  description = 'ominfra'
24
24
  dependencies = [
25
- 'omdev == 0.0.0.dev121',
26
- 'omlish == 0.0.0.dev121',
25
+ 'omdev == 0.0.0.dev122',
26
+ 'omlish == 0.0.0.dev122',
27
27
  ]
28
28
 
29
29
  [project.optional-dependencies]
File without changes
File without changes