flyte 0.2.0b20__py3-none-any.whl → 0.2.0b21__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.

Potentially problematic release.


This version of flyte might be problematic. Click here for more details.

flyte/_image.py CHANGED
@@ -459,6 +459,10 @@ class Image:
459
459
  name: str,
460
460
  registry: str | None = None,
461
461
  python_version: Optional[Tuple[int, int]] = None,
462
+ index_url: Optional[str] = None,
463
+ extra_index_urls: Union[str, List[str], Tuple[str, ...], None] = None,
464
+ pre: bool = False,
465
+ extra_args: Optional[str] = None,
462
466
  arch: Union[Architecture, Tuple[Architecture, ...]] = "linux/amd64",
463
467
  ) -> Image:
464
468
  """
@@ -486,6 +490,10 @@ class Image:
486
490
  :param script: path to the uv script
487
491
  :param arch: architecture to use for the image, default is linux/amd64, use tuple for multiple values
488
492
  :param python_version: Python version for the image, if not specified, will use the current Python version
493
+ :param index_url: index url to use for pip install, default is None
494
+ :param extra_index_urls: extra index urls to use for pip install, default is None
495
+ :param pre: whether to allow pre-release versions, default is False
496
+ :param extra_args: extra arguments to pass to pip install, default is None
489
497
 
490
498
  :return: Image
491
499
  """
@@ -510,7 +518,13 @@ class Image:
510
518
  img = img.with_apt_packages("ca-certificates")
511
519
 
512
520
  if header.dependencies:
513
- return img.with_pip_packages(*header.dependencies)
521
+ return img.with_pip_packages(
522
+ *header.dependencies,
523
+ index_url=index_url,
524
+ extra_index_urls=extra_index_urls,
525
+ pre=pre,
526
+ extra_args=extra_args,
527
+ )
514
528
 
515
529
  # todo: override the _identifier_override to be the script name or a hash of the script contents
516
530
  # This is needed because inside the image, the identifier will be computed to be something different.
@@ -711,7 +725,14 @@ class Image:
711
725
  new_image = self.clone(addl_layer=CopyConfig(path_type=0, src=src, dst=dst))
712
726
  return new_image
713
727
 
714
- def with_uv_project(self, pyproject_file: Path) -> Image:
728
+ def with_uv_project(
729
+ self,
730
+ pyproject_file: Path,
731
+ index_url: Optional[str] = None,
732
+ extra_index_urls: Union[str, List[str], Tuple[str, ...], None] = None,
733
+ pre: bool = False,
734
+ extra_args: Optional[str] = None,
735
+ ) -> Image:
715
736
  """
716
737
  Use this method to create a new image with the specified uv.lock file layered on top of the current image
717
738
  Must have a corresponding pyproject.toml file in the same directory
@@ -71,7 +71,7 @@ async def convert_upload_default_inputs(interface: NativeInterface) -> List[comm
71
71
  vars = []
72
72
  literal_coros = []
73
73
  for input_name, (input_type, default_value) in interface.inputs.items():
74
- if default_value is not inspect.Parameter.empty:
74
+ if default_value and default_value is not inspect.Parameter.empty:
75
75
  lt = TypeEngine.to_literal_type(input_type)
76
76
  literal_coros.append(TypeEngine.to_literal(default_value, input_type, lt))
77
77
  vars.append((input_name, lt))
@@ -11,7 +11,7 @@ ACCELERATOR_DEVICE_MAP = {
11
11
  "A10G": "nvidia-a10g",
12
12
  "A100G": "nvidia-a100g",
13
13
  "L4": "nvidia-l4",
14
- "L40s": "nvidia-l40",
14
+ "L40s": "nvidia-l40s",
15
15
  "L4_VWS": "nvidia-l4-vws",
16
16
  "K80": "nvidia-tesla-k80",
17
17
  "M60": "nvidia-tesla-m60",
@@ -217,9 +217,12 @@ def _get_urun_container(
217
217
  if isinstance(task_template.image, str):
218
218
  raise flyte.errors.RuntimeSystemError("BadConfig", "Image is not a valid image")
219
219
  image_id = task_template.image.identifier
220
- if not serialize_context.image_cache or image_id not in serialize_context.image_cache.image_lookup:
220
+ if not serialize_context.image_cache:
221
221
  # This computes the image uri, computing hashes as necessary so can fail if done remotely.
222
222
  img_uri = task_template.image.uri
223
+ elif image_id not in serialize_context.image_cache.image_lookup:
224
+ img_uri = task_template.image.uri
225
+ logger.warning(f"Image uri {img_uri} not found in image_cache {serialize_context.image_cache.image_lookup}")
223
226
  else:
224
227
  img_uri = serialize_context.image_cache.image_lookup[image_id]
225
228
 
flyte/_version.py CHANGED
@@ -17,5 +17,5 @@ __version__: str
17
17
  __version_tuple__: VERSION_TUPLE
18
18
  version_tuple: VERSION_TUPLE
19
19
 
20
- __version__ = version = '0.2.0b20'
21
- __version_tuple__ = version_tuple = (0, 2, 0, 'b20')
20
+ __version__ = version = '0.2.0b21'
21
+ __version_tuple__ = version_tuple = (0, 2, 0, 'b21')
flyte/config/_reader.py CHANGED
@@ -147,7 +147,7 @@ def resolve_config_path() -> pathlib.Path | None:
147
147
  current_location_config = Path("config.yaml")
148
148
  if current_location_config.exists():
149
149
  return current_location_config
150
- logger.debug("No ./config.yaml found, returning None")
150
+ logger.debug("No ./config.yaml found")
151
151
 
152
152
  uctl_path_from_env = getenv(UCTL_CONFIG_ENV_VAR, None)
153
153
  if uctl_path_from_env:
@@ -133,7 +133,7 @@ async def create_channel(
133
133
  import aiofiles
134
134
 
135
135
  async with aiofiles.open(ca_cert_file_path, "rb") as f:
136
- st_cert = f.read()
136
+ st_cert = await f.read()
137
137
  ssl_credentials = grpc.ssl_channel_credentials(st_cert)
138
138
  else:
139
139
  ssl_credentials = grpc.ssl_channel_credentials()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: flyte
3
- Version: 0.2.0b20
3
+ Version: 0.2.0b21
4
4
  Summary: Add your description here
5
5
  Author-email: Ketan Umare <kumare3@users.noreply.github.com>
6
6
  Requires-Python: >=3.10
@@ -8,7 +8,7 @@ flyte/_environment.py,sha256=dmIFmFLRIklOEYL9gsP2IH3-MYcjHYyyOlqlcf3E6_A,2924
8
8
  flyte/_excepthook.py,sha256=nXts84rzEg6-7RtFarbKzOsRZTQR4plnbWVIFMAEprs,1310
9
9
  flyte/_group.py,sha256=7o1j16sZyUmYB50mOiq1ui4TBAKhRpDqLakV8Ya1kw4,803
10
10
  flyte/_hash.py,sha256=Of_Zl_DzzzF2jp4ZsLm-3o-xJFCCJ8_GubmLI1htx78,504
11
- flyte/_image.py,sha256=jnMJujIOCHkzot5KnCW1pglARNlkwv02PLA4GTD0qhs,29724
11
+ flyte/_image.py,sha256=6d_bxy2KOn0_wj895iPOxXKN5uzygUeT2fOhxG95dg4,30633
12
12
  flyte/_initialize.py,sha256=xKl_LYMluRt21wWqa6RTKuLo0_DCbSaTfUk27_brtNk,18232
13
13
  flyte/_interface.py,sha256=1B9zIwFDjiVp_3l_mk8EpA4g3Re-6DUBEBi9z9vDvPs,3504
14
14
  flyte/_logging.py,sha256=_yNo-Nx2yzh0MLoZGbnIYHGKei4wtQmSGM0lE30Ev7w,3662
@@ -24,7 +24,7 @@ flyte/_task_environment.py,sha256=B493b54xpnNFNtHek3cmT4XuNiPNVf2gx9Yylyb1ncw,69
24
24
  flyte/_timeout.py,sha256=zx5sFcbYmjJAJbZWSGzzX-BpC9HC7Jfs35T7vVhKwkk,1571
25
25
  flyte/_tools.py,sha256=JewkQZBR_M85tS6QY8e4xXue75jbOE48nID4ZHnc9jY,632
26
26
  flyte/_trace.py,sha256=C788bgoSc3st8kE8Cae2xegnLx2CT6uuRKKfaDrDUys,5122
27
- flyte/_version.py,sha256=2zwM42jgtTbQ5nghDiGlcpIjWP03pWSRnSChl7LzXQc,521
27
+ flyte/_version.py,sha256=sbSySP-E_nMvVuSaQWbQZTGdTG_B1w6UKrkfQnFlsN4,521
28
28
  flyte/errors.py,sha256=skXcdexLisFZFcTnUmMvMmuh4Ty96oJkyLKaipzkyeI,4954
29
29
  flyte/models.py,sha256=my7Vxo-NK6gHGahyqtHr42wYjPGw0nl2SGBBoSb6hIc,14733
30
30
  flyte/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -59,11 +59,11 @@ flyte/_internal/resolvers/_task_module.py,sha256=jwy1QYygUK7xmpCZLt1SPTfJCkfox3C
59
59
  flyte/_internal/resolvers/common.py,sha256=ADQLRoyGsJ4vuUkitffMGrMKKjy0vpk6X53g4FuKDLc,993
60
60
  flyte/_internal/resolvers/default.py,sha256=nX4DHUYod1nRvEsl_vSgutQVEdExu2xL8pRkyi4VWbY,981
61
61
  flyte/_internal/runtime/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
62
- flyte/_internal/runtime/convert.py,sha256=-ZjnymAhAmO6ngNkbhwrxRrvvXD0QQRnZUPptY1pyuo,13777
62
+ flyte/_internal/runtime/convert.py,sha256=rvKXEDQxFLyAslSJeOrqeG1kkXaYxHWxkBMloaZNCPc,13795
63
63
  flyte/_internal/runtime/entrypoints.py,sha256=Kyi19i7LYk7YM3ZV_Y4FXGt5Pc1tIftGkIDohopblyY,5127
64
64
  flyte/_internal/runtime/io.py,sha256=Lgdy4iPjlKjUO-V_AkoPZff6lywaFjZUG-PErRukmx4,4248
65
- flyte/_internal/runtime/resources_serde.py,sha256=tvMMv3l6cZEt_cfs7zVE_Kqs5qh-_r7fsEPxb6xMxMk,4812
66
- flyte/_internal/runtime/task_serde.py,sha256=H7cyRCS8eyicnWjQogcFPHxs1uX9FI5bZypUfBSzJOw,13873
65
+ flyte/_internal/runtime/resources_serde.py,sha256=TObMVsSjVcQhcY8-nY81pbvrz7TP-adDD5xV-LqAaxM,4813
66
+ flyte/_internal/runtime/task_serde.py,sha256=wjYZSr0aXCvo6egWLlTrrRgYbx-V6L1clY2jstJNQlk,14039
67
67
  flyte/_internal/runtime/taskrunner.py,sha256=rHWS4t5qgZnzGdGrs0_O0sSs_PVGoE1CNPDb-fTwwmo,7332
68
68
  flyte/_internal/runtime/types_serde.py,sha256=EjRh9Yypx9-20XXQprtNgp766LeQVRoYWtY6XPGMZQg,1813
69
69
  flyte/_protos/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -165,7 +165,7 @@ flyte/cli/main.py,sha256=7P8nBWvme7beBola5Oo-tHgn9ydWIA-J3w5XH_ORImM,4836
165
165
  flyte/config/__init__.py,sha256=MiwEYK5Iv7MRR22z61nzbsbvZ9Q6MdmAU_g9If1Pmb8,144
166
166
  flyte/config/_config.py,sha256=WElU--Kw4MM9zx1v-rLD8qYu2T5Zk0-1QbTpkEc27bc,10779
167
167
  flyte/config/_internal.py,sha256=LMcAtDjvTjf5bGlsJVxPuLxQQ82mLd00xK5-JlYGCi8,2989
168
- flyte/config/_reader.py,sha256=K_ZAxSbXVmswMmMtObQWnTw398r6EcwyHOg2i7bp2Cs,7037
168
+ flyte/config/_reader.py,sha256=coidKV5CVODEnqDnsHZ9-VMC0UGXanXhAZE1SmYRhxI,7021
169
169
  flyte/connectors/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
170
170
  flyte/extras/__init__.py,sha256=FhB0uK7H1Yo5De9vOuF7UGnezTKncj3u2Wo5uQdWN0g,74
171
171
  flyte/extras/_container.py,sha256=kxwiMltfMizjOKmsXYQ-rLOCHmX-TCCeJRM7ukuHoOg,11367
@@ -188,7 +188,7 @@ flyte/remote/_client/_protocols.py,sha256=JyBWHs5WsVOxEDUyG9X7wPLDzzzjkoaNhJlU-X
188
188
  flyte/remote/_client/controlplane.py,sha256=FsOfj4rO4MIMnYrpAT53F8q588VVf5t4sDuwoPuc840,3102
189
189
  flyte/remote/_client/auth/__init__.py,sha256=JQrIlwaqPlPzrxcOREhcfyFsC4LrfqL5TRz6A3JNSEA,413
190
190
  flyte/remote/_client/auth/_auth_utils.py,sha256=Is6mr18J8AMQlbtu-Q63aMJgrZ27dXXNSig8KshR1_8,545
191
- flyte/remote/_client/auth/_channel.py,sha256=GViIT63qabaMOe0gethEGwPR7M_E-MxAiVOlDFgYHps,9449
191
+ flyte/remote/_client/auth/_channel.py,sha256=HoVyxgjij1xNBXvQvQRRF0Gy0OU-7QHdl0jXRA6fq0o,9455
192
192
  flyte/remote/_client/auth/_client_config.py,sha256=Elit5TCLjMQDiktiUmMKy2POWwwb5rKgIXfG3-rpfbs,3304
193
193
  flyte/remote/_client/auth/_default_html.py,sha256=XAdgP-25WySMODbusWOcQQPiXin1h-hfzmRJv_Dg3tE,1651
194
194
  flyte/remote/_client/auth/_keyring.py,sha256=BL-FzGe5ryuBRCwwpvvG8IzkYuXiJTU2J0P1l-Za5IM,5176
@@ -221,8 +221,8 @@ flyte/types/_renderer.py,sha256=ygcCo5l60lHufyQISFddZfWwLlQ8kJAKxUT_XnR_6dY,4818
221
221
  flyte/types/_string_literals.py,sha256=NlG1xV8RSA-sZ-n-IFQCAsdB6jXJOAKkHWtnopxVVDk,4231
222
222
  flyte/types/_type_engine.py,sha256=CCjpqXNX2BMza2cKq42hJXwabWy8GWsimsgiGZJ_00M,96583
223
223
  flyte/types/_utils.py,sha256=pbts9E1_2LTdLygAY0UYTLYJ8AsN3BZyviSXvrtcutc,2626
224
- flyte-0.2.0b20.dist-info/METADATA,sha256=CiRUMUNThKu0qQUN5XxdtVgPnRUv8flBIGyQpqh2Tsg,5850
225
- flyte-0.2.0b20.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
226
- flyte-0.2.0b20.dist-info/entry_points.txt,sha256=MIq2z5dBurdCJfpXfMKzgBv7sJOakKRYxr8G0cMiTrg,75
227
- flyte-0.2.0b20.dist-info/top_level.txt,sha256=7dkyFbikvA12LEZEqawx8oDG1CMod6hTliPj7iWzgYo,6
228
- flyte-0.2.0b20.dist-info/RECORD,,
224
+ flyte-0.2.0b21.dist-info/METADATA,sha256=_A_r-O2ibG-Y8OBOhv9xiPuUXGqQyWtghF5ZY5NzLRo,5850
225
+ flyte-0.2.0b21.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
226
+ flyte-0.2.0b21.dist-info/entry_points.txt,sha256=MIq2z5dBurdCJfpXfMKzgBv7sJOakKRYxr8G0cMiTrg,75
227
+ flyte-0.2.0b21.dist-info/top_level.txt,sha256=7dkyFbikvA12LEZEqawx8oDG1CMod6hTliPj7iWzgYo,6
228
+ flyte-0.2.0b21.dist-info/RECORD,,