dagster-aws 0.28.8__py3-none-any.whl → 0.28.10__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.
@@ -244,6 +244,7 @@ class EcsStepHandler(StepHandler):
244
244
  ]
245
245
 
246
246
  task_overrides = self._get_task_overrides(step_tags) or {}
247
+ step_container_overrides = self._get_container_overrides(step_tags)
247
248
 
248
249
  task_overrides["containerOverrides"] = task_overrides.get("containerOverrides", [])
249
250
 
@@ -270,6 +271,8 @@ class EcsStepHandler(StepHandler):
270
271
  container_overrides["environment"] = (
271
272
  container_overrides.get("environment", []) + executor_env_vars
272
273
  )
274
+ # merge step container overrides (e.g., resourceRequirements)
275
+ container_overrides.update(step_container_overrides)
273
276
  break
274
277
  # if no existing container overrides for the executor container, add new container overrides
275
278
  else:
@@ -278,6 +281,7 @@ class EcsStepHandler(StepHandler):
278
281
  "name": executor_container_name,
279
282
  "command": args,
280
283
  "environment": executor_env_vars,
284
+ **step_container_overrides,
281
285
  }
282
286
  )
283
287
 
@@ -308,6 +312,12 @@ class EcsStepHandler(StepHandler):
308
312
 
309
313
  return overrides
310
314
 
315
+ def _get_container_overrides(self, step_tags: Mapping[str, str]) -> dict[str, Any]:
316
+ if tag_overrides := step_tags.get("ecs/container_overrides"):
317
+ return json.loads(tag_overrides)
318
+
319
+ return {}
320
+
311
321
  def _get_step_id(self, step_handler_context: StepHandlerContext):
312
322
  """Step ID is used to identify the ECS task in the ECS cluster.
313
323
  It is unique to specific step being executed and takes into account op-level retries.
@@ -522,6 +522,7 @@ class EcsRunLauncher(RunLauncher[T_DagsterInstance], ConfigurableClass):
522
522
  cpu_and_memory_overrides = self.get_cpu_and_memory_overrides(container_context, run)
523
523
 
524
524
  task_overrides = self._get_task_overrides(container_context, run)
525
+ run_container_overrides = self._get_container_overrides(run)
525
526
 
526
527
  container_overrides: list[dict[str, Any]] = [
527
528
  {
@@ -529,6 +530,7 @@ class EcsRunLauncher(RunLauncher[T_DagsterInstance], ConfigurableClass):
529
530
  "command": command,
530
531
  # containerOverrides expects cpu/memory as integers
531
532
  **{k: int(v) for k, v in cpu_and_memory_overrides.items()},
533
+ **run_container_overrides,
532
534
  }
533
535
  ]
534
536
 
@@ -626,6 +628,14 @@ class EcsRunLauncher(RunLauncher[T_DagsterInstance], ConfigurableClass):
626
628
 
627
629
  return overrides
628
630
 
631
+ def _get_container_overrides(self, run: DagsterRun) -> Mapping[str, Any]:
632
+ tag_overrides = run.tags.get("ecs/container_overrides")
633
+
634
+ if tag_overrides:
635
+ return json.loads(tag_overrides)
636
+
637
+ return {}
638
+
629
639
  def _get_run_task_kwargs_from_run(self, run: DagsterRun) -> Mapping[str, Any]:
630
640
  run_task_kwargs = run.tags.get("ecs/run_task_kwargs")
631
641
  if run_task_kwargs:
dagster_aws/version.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.28.8"
1
+ __version__ = "0.28.10"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dagster-aws
3
- Version: 0.28.8
3
+ Version: 0.28.10
4
4
  Summary: Package for AWS-specific Dagster framework solid and resource components.
5
5
  Home-page: https://github.com/dagster-io/dagster/tree/master/python_modules/libraries/dagster-aws
6
6
  Author: Dagster Labs
@@ -16,7 +16,7 @@ Classifier: Operating System :: OS Independent
16
16
  Requires-Python: >=3.10,<3.15
17
17
  License-File: LICENSE
18
18
  Requires-Dist: boto3
19
- Requires-Dist: dagster==1.12.8
19
+ Requires-Dist: dagster==1.12.10
20
20
  Requires-Dist: packaging
21
21
  Requires-Dist: requests
22
22
  Provides-Extra: redshift
@@ -1,7 +1,7 @@
1
1
  dagster_aws/__init__.py,sha256=n5d1NvkQvkVnjWetqKFOLCZUkymTJ0v2WMxLGsbA2Hk,166
2
2
  dagster_aws/_stubs.py,sha256=3C6ve6WLtuT2HtCn50hBAMIz-eEAwcZo4fCVnNxGBQw,1112
3
3
  dagster_aws/py.typed,sha256=la67KBlbjXN-_-DfGNcdOcjYumVpKG_Tkw-8n5dnGB4,8
4
- dagster_aws/version.py,sha256=rMjeJYs_MOkcUCEGMkmwm1PlX0JRu_r70Ywo8pJrCDs,23
4
+ dagster_aws/version.py,sha256=110BPTEyn13PDWnHpj0D7VMBpjnNxJ6-MM3ZHvQwyQ0,24
5
5
  dagster_aws/athena/__init__.py,sha256=J0-QydhSP3pUQk7CawztpaTm3Q1NFEpbubTM1eULbGo,413
6
6
  dagster_aws/athena/resources.py,sha256=h7Md_KQXHvtBHA019WZFzAFTClzEUDItDZNdhR2RrPY,11907
7
7
  dagster_aws/cloudwatch/__init__.py,sha256=iiyLEyTfNMThU4_SNM_Ns7IGXKR7wTKIvOUz9v_RQBA,82
@@ -10,8 +10,8 @@ dagster_aws/ecr/__init__.py,sha256=blvQFFCzujZvy11PfMZ7jFBEfklK5PP-99Mmd1DJ3_k,2
10
10
  dagster_aws/ecr/resources.py,sha256=3SiatAFl9vvkXFmxZjB6e2L20bM6gsKfaveiyTWSRdM,3252
11
11
  dagster_aws/ecs/__init__.py,sha256=E6SAG_YKJcdUIw57amZf3AqzqVUN-GLjrLCpPxSemMg,233
12
12
  dagster_aws/ecs/container_context.py,sha256=vB8C4d04iIhd0Gu9vRdYAfua9ib95N25uohEoev9yIY,18154
13
- dagster_aws/ecs/executor.py,sha256=Fv9pbtJyE0D1DZ2e2uguYS8JHinZFjvcIfwqguYhYDM,16969
14
- dagster_aws/ecs/launcher.py,sha256=FN5u1tFTwyRsHn1wwoqW7zrrej1JqoZKYBrUsWoG0jo,39234
13
+ dagster_aws/ecs/executor.py,sha256=_zVI3uDeQjGum4Zn7juqt-xhB3mwlGZfufgIGsXyvsU,17463
14
+ dagster_aws/ecs/launcher.py,sha256=a5GhBTa_hwLG9FO5d0aUhmCuv2xPKRsCA0FVcVlXFX4,39580
15
15
  dagster_aws/ecs/tasks.py,sha256=n5zigCqVhTsFQJS9g09eVHVCerZYJjhN_Hd-EEZJS7c,18443
16
16
  dagster_aws/ecs/test_utils.py,sha256=VqzOIws-fLoDxGrOMzE9ZuAbOF4t9AURIwjyM2Jid-E,2041
17
17
  dagster_aws/ecs/utils.py,sha256=CGgMjdoprtS9golz-H3yIDkSXPHxvOTmy5LJc43VVSo,5389
@@ -59,8 +59,8 @@ dagster_aws/utils/mrjob/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG
59
59
  dagster_aws/utils/mrjob/log4j.py,sha256=Gj2D5USX8swfBXlWf3-NiqeFvrs3h1SGJkOPbP3mke8,4392
60
60
  dagster_aws/utils/mrjob/retry.py,sha256=o8Y1Sgu8ABNnsm9jMCfagJpXmgpjcwDw6ufQmDV_Dus,4805
61
61
  dagster_aws/utils/mrjob/utils.py,sha256=pFKobTkgwPxQoQNlzGzD3jFxwIP-flQOspQxNKGg2dc,3684
62
- dagster_aws-0.28.8.dist-info/licenses/LICENSE,sha256=4lsMW-RCvfVD4_F57wrmpe3vX1xwUk_OAKKmV_XT7Z0,11348
63
- dagster_aws-0.28.8.dist-info/METADATA,sha256=vzYvpm4bKH_pFlHSlNy6dFxmIsv3PB54fqkPLM2o9KQ,1697
64
- dagster_aws-0.28.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
65
- dagster_aws-0.28.8.dist-info/top_level.txt,sha256=-hOwIi00tt_K9eXRhiyjst45X-Ffu5_QCdbKcm8UpDg,12
66
- dagster_aws-0.28.8.dist-info/RECORD,,
62
+ dagster_aws-0.28.10.dist-info/licenses/LICENSE,sha256=4lsMW-RCvfVD4_F57wrmpe3vX1xwUk_OAKKmV_XT7Z0,11348
63
+ dagster_aws-0.28.10.dist-info/METADATA,sha256=I4IbE0lWP3EW0qBCKudCLZoJwz-VdFKZHZaKbrU9tMw,1699
64
+ dagster_aws-0.28.10.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
65
+ dagster_aws-0.28.10.dist-info/top_level.txt,sha256=-hOwIi00tt_K9eXRhiyjst45X-Ffu5_QCdbKcm8UpDg,12
66
+ dagster_aws-0.28.10.dist-info/RECORD,,