Skip to content

Commit

Permalink
fix yaml parse error
Browse files Browse the repository at this point in the history
  • Loading branch information
Shrinandan-N committed Jul 27, 2024
1 parent e1e2590 commit 3835992
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sky/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ def from_yaml_config(
mount_path = storage[0]
assert mount_path, 'Storage mount path cannot be empty.'
try:
region = config['resources'].get('region', None)
resources = config.get('resources', None)
region = resources.get('region', None) if resources else None
storage_obj = storage_lib.Storage.from_yaml_config(
storage[1], region)
except exceptions.StorageSourceError as e:
Expand Down

0 comments on commit 3835992

Please sign in to comment.