Matheus Moreno03/31/2022, 10:40 PM
, the path is not really obvious/human-friendly.
Jay Ganbat03/31/2022, 10:50 PM
it should put your data there and you can configre paths and names to be human readable
return FlyteFile(path=local_path, remote_path=somewhere_remote)
Matheus Moreno03/31/2022, 11:07 PM
and then call another function to retrieve the file on the bucket?
return FlyteFile(path='test.pickle', remote_path='<s3://my-s3-bucket/flyte-example/say_hello.pickle>')
and it doesn't even run; in fact, I'm receiving a 500 error from the server.
@task def retrieve_from_s3(uri: PythonPickledFile) -> str: uri.download() with open(uri.path, 'r') as handle: x = pickle.load(handle) return x
Jay Ganbat03/31/2022, 11:09 PM
FLyte should be able to automically download it for you
with open(uri, 'r') as handle:
something like above
2022-03-10 08:25:02,782 [INFO] Entering timed context: Copying (<gs://remote_file> -> /tmp/flytequjfq95e/local_flytekit/local_file)
Matheus Moreno03/31/2022, 11:13 PM
Message: Failed to get data from <s3://my-s3-bucket/flyte-example/say_hello.pkl> to /tmp/flytek5pbstuv/local_flytekit/5186be74bee2a9b806fa2c15e358371b/say_hello.pkl (recursive=False). Original exception: Called process exited with error code: 1. Stderr dump: b'fatal error: An error occurred (403) when calling the HeadObject operation: Forbidden\n' User error.
Jay Ganbat03/31/2022, 11:14 PM
Matheus Moreno03/31/2022, 11:17 PM
Jay Ganbat03/31/2022, 11:28 PM
Matheus Moreno03/31/2022, 11:53 PM
Matheus Moreno04/01/2022, 1:42 PM