truss 0.11.12rc511__py3-none-any.whl → 0.11.12rc513__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 truss might be problematic. Click here for more details.

@@ -760,7 +760,6 @@ class ServingImageBuilder(ImageBuilder):
760
760
  user_id = config.docker_server.run_as_user_id
761
761
  else:
762
762
  user_id = 60000
763
- # dockerfile_contents += f"\nENV APP_HOME=$HOME"
764
763
  dockerfile_contents += f"\nCOPY --chown={user_id}:{user_id} ./bptr-manifest /static-bptr/static-bptr-manifest.json"
765
764
  docker_file_path = build_dir / MODEL_DOCKERFILE_NAME
766
765
  docker_file_path.write_text(dockerfile_contents)
@@ -1,6 +1,5 @@
1
1
  import atexit
2
2
  import logging
3
- import os
4
3
  import time
5
4
  from functools import lru_cache
6
5
  from pathlib import Path
@@ -14,10 +13,6 @@ LAZY_DATA_RESOLVER_PATH = [
14
13
  Path("/static-bptr/static-bptr-manifest.json"),
15
14
  ]
16
15
 
17
- # Add fallback for as-is deployments if HOME is set
18
- if os.environ.get("HOME"):
19
- LAZY_DATA_RESOLVER_PATH.append(Path(os.environ.get("HOME")) / "bptr-manifest")
20
-
21
16
  MISSING_COLLECTION_MESSAGE = """model_cache: Data was not collected. Missing lazy_data_resolver.block_until_download_complete().
22
17
  This is a potential bug by the user implementation of model.py when using model_cache.
23
18
  We need you to call the block_until_download_complete() method during __init__ or load() method of your model.
@@ -53,18 +48,7 @@ class LazyDataResolverV2:
53
48
  self._lock = Lock()
54
49
  self._start_time = time.time()
55
50
  self.logger = logger or logging.getLogger(__name__)
56
-
57
- # Debug logging for bptr manifest detection
58
- self.logger.info(f"LazyDataResolverV2: Checking for bptr manifest in paths: {LAZY_DATA_RESOLVER_PATH}")
59
- bptr_found = self.bptr_exists()
60
- self.logger.info(f"LazyDataResolverV2: bptr_exists() = {bptr_found}")
61
- if bptr_found:
62
- for path in LAZY_DATA_RESOLVER_PATH:
63
- if path.exists():
64
- self.logger.info(f"LazyDataResolverV2: Found bptr manifest at {path}")
65
- break
66
-
67
- self._is_collected_by_user = not bptr_found
51
+ self._is_collected_by_user = not self.bptr_exists()
68
52
  thread = Thread(target=self._prefetch_in_thread, daemon=True)
69
53
  thread.start()
70
54
 
@@ -108,24 +92,13 @@ class LazyDataResolverV2:
108
92
  def _fetch(self) -> Union[str, Exception]:
109
93
  """cached and locked method to fetch the data."""
110
94
  if not self.bptr_exists():
111
- self.logger.info("LazyDataResolverV2: No bptr manifest found, skipping download")
112
95
  return "" # no data to resolve
113
-
114
- self.logger.info("LazyDataResolverV2: bptr manifest found, attempting to import truss_transfer")
115
- try:
116
- import truss_transfer
117
- self.logger.info("LazyDataResolverV2: truss_transfer imported successfully")
118
- except ImportError as e:
119
- self.logger.error(f"LazyDataResolverV2: Failed to import truss_transfer: {e}")
120
- return e
96
+ import truss_transfer
121
97
 
122
98
  try:
123
- self.logger.info(f"LazyDataResolverV2: Calling truss_transfer.lazy_data_resolve with data_dir: {self._data_dir}")
124
- result = truss_transfer.lazy_data_resolve(str(self._data_dir))
125
- self.logger.info(f"LazyDataResolverV2: truss_transfer.lazy_data_resolve completed successfully")
126
- return result
99
+ return truss_transfer.lazy_data_resolve(str(self._data_dir))
127
100
  except Exception as e:
128
- self.logger.error(f"LazyDataResolverV2: Error occurred while fetching data: {e}")
101
+ self.logger.error(f"Error occurred while fetching data: {e}")
129
102
  return e
130
103
 
131
104
  def raise_if_not_collected(self):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: truss
3
- Version: 0.11.12rc511
3
+ Version: 0.11.12rc513
4
4
  Summary: A seamless bridge from model development to model delivery
5
5
  Project-URL: Repository, https://github.com/basetenlabs/truss
6
6
  Project-URL: Homepage, https://truss.baseten.co
@@ -36,7 +36,7 @@ truss/contexts/docker_build_setup.py,sha256=cF4ExZgtYvrWxvyCAaUZUvV_DB_7__MqVomU
36
36
  truss/contexts/truss_context.py,sha256=uS6L-ACHxNk0BsJwESOHh1lA0OGGw0pb33aFKGsASj4,436
37
37
  truss/contexts/image_builder/cache_warmer.py,sha256=TGMV1Mh87n2e_dSowH0sf0rZhZraDOR-LVapZL3a5r8,7377
38
38
  truss/contexts/image_builder/image_builder.py,sha256=IuRgDeeoHVLzIkJvKtX3807eeqEyaroCs_KWDcIHZUg,1461
39
- truss/contexts/image_builder/serving_image_builder.py,sha256=NsTLCMOvJX1cUa4XXr6B-ksyb6JTB3BhTFlIwv9IKK4,34412
39
+ truss/contexts/image_builder/serving_image_builder.py,sha256=hNiIo58GoBcrcPoEJi6hBgCPrev1VFvIBB003al92G0,34347
40
40
  truss/contexts/image_builder/util.py,sha256=y2-CjUKv0XV-0w2sr1fUCflysDJLsoU4oPp6tvvoFnk,1203
41
41
  truss/contexts/local_loader/docker_build_emulator.py,sha256=3n0eIlJblz_sldh4AN8AHQDyfjQGdYyld5FabBdd9wE,3563
42
42
  truss/contexts/local_loader/dockerfile_parser.py,sha256=GoRJ0Af_3ILyLhjovK5lrCGn1rMxz6W3l681ro17ZzI,1344
@@ -107,7 +107,7 @@ truss/templates/server/common/tracing.py,sha256=XSTXNoRtV8vXwveJoX3H32go0JKnLmzn
107
107
  truss/templates/server/common/patches/whisper/patch.py,sha256=kDECQ-wmEpeAZFhUTQP457ofueeMsm7DgNy9tqinhJQ,2383
108
108
  truss/templates/shared/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
109
109
  truss/templates/shared/dynamic_config_resolver.py,sha256=75s42NFhQI5jL7BqlJH_UkuQS7ptbtFh13f2nh6X5Wo,920
110
- truss/templates/shared/lazy_data_resolver.py,sha256=zRsGRF62NQUWtYkqkKx3A-F0912mN3ug6Dorkh2iJzs,7408
110
+ truss/templates/shared/lazy_data_resolver.py,sha256=SMw3L24R_UkNXuL0fO-AN02rUTHfy0Aiz3JTyS0PAEc,5978
111
111
  truss/templates/shared/log_config.py,sha256=l9udyu4VKHZePlfK9LQEd5TOUUodPuehypsXRSUL4Ac,5411
112
112
  truss/templates/shared/secrets_resolver.py,sha256=3prDe3Q06NTmUEe7KCW-W4TD1CzGck9lpDG789209z4,2110
113
113
  truss/templates/shared/serialization.py,sha256=_WC_2PPkRi-MdTwxwjG8LKQptnHi4sANfpOlKWevqWc,3736
@@ -370,8 +370,8 @@ truss_train/deployment.py,sha256=lWWANSuzBWu2M4oK4qD7n-oVR1JKdmw2Pn5BJQHg-Ck,307
370
370
  truss_train/loader.py,sha256=0o66EjBaHc2YY4syxxHVR4ordJWs13lNXnKjKq2wq0U,1630
371
371
  truss_train/public_api.py,sha256=9N_NstiUlmBuLUwH_fNG_1x7OhGCytZLNvqKXBlStrM,1220
372
372
  truss_train/restore_from_checkpoint.py,sha256=8hdPm-WSgkt74HDPjvCjZMBpvA9MwtoYsxVjOoa7BaM,1176
373
- truss-0.11.12rc511.dist-info/METADATA,sha256=VWj3mukBoorVAsnApqqIQ3RoaDkuWNI80gUCGyuPeBw,6683
374
- truss-0.11.12rc511.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
375
- truss-0.11.12rc511.dist-info/entry_points.txt,sha256=-MwKfHHQHQ6j0HqIgvxrz3CehCmczDLTD-OsRHnjjuU,130
376
- truss-0.11.12rc511.dist-info/licenses/LICENSE,sha256=FTqGzu85i-uw1Gi8E_o0oD60bH9yQ_XIGtZbA1QUYiw,1064
377
- truss-0.11.12rc511.dist-info/RECORD,,
373
+ truss-0.11.12rc513.dist-info/METADATA,sha256=OOL0pd_emhFSRATQvhMOR7unZloZ1UPqzxpJT9tXAow,6683
374
+ truss-0.11.12rc513.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
375
+ truss-0.11.12rc513.dist-info/entry_points.txt,sha256=-MwKfHHQHQ6j0HqIgvxrz3CehCmczDLTD-OsRHnjjuU,130
376
+ truss-0.11.12rc513.dist-info/licenses/LICENSE,sha256=FTqGzu85i-uw1Gi8E_o0oD60bH9yQ_XIGtZbA1QUYiw,1064
377
+ truss-0.11.12rc513.dist-info/RECORD,,