The Metaflow 2.3.5 release is a patch release.
- [Features](2.3.5_features)
- [Enable mounting host volumes in AWS Batch](441)
- [Bug Fixes](2.3.5_bugs)
- [Fix input values for Parameters of type `list` within a Metaflow Foreach task](651)
<a name="v2.3.5_features"></a> Features
[Enable mounting host volumes in AWS Batch](441)
With this release, you can now [mount and access instance host volumes](https://aws.amazon.com/premiumsupport/knowledge-center/batch-mount-efs/) within a Metaflow task running on AWS Batch. To access a host volume, you can add `host-volumes` argument to your `batch` decorator -
batch(host_volumes=['/home', '/var/log'])
<a name="v2.3.5_bugs"></a> Bug Fixes
[Fix input values for Parameters of type `list` within a Metaflow Foreach task](651)
The following flow had a bug where the value for `self.input` was being imputed to `None` rather than the dictionary element. This release fixes this issue -
python
from metaflow import FlowSpec, Parameter, step, JSONType
class ForeachFlow(FlowSpec):
numbers_param = Parameter(
"numbers_param",
type=JSONType,
default='[1,2,3]'
)
step
def start(self):
This works, and passes each number to the run_number step:
self.numbers = self.numbers_param
self.next(self.run_number, foreach='numbers')
But this doesn't:
self.next(self.run_number, foreach='numbers_param')
step
def run_number(self):
print(f"number is {self.input}")
self.next(self.join)
step
def join(self, inputs):
self.next(self.end)
step
def end(self):
pass
if __name__ == '__main__':
ForeachFlow()