Managed Folder No such file or directory

Solved!
David08
Level 1
Managed Folder No such file or directory

Hi, I've create a Python recipe with a Dataset and Managed Folder  as output and a Dataset as input.

My code:


Model_ScikitLearn = dataiku.Folder("v9OdRBEN")
Model_ScikitLearn_path = Model_ScikitLearn.get_path()

 

os.listdir(Model_ScikitLearn_path)

and gets this error:

- FileNotFoundError Traceback (most recent call last) <ipython-input-9-08881e72cb40> in <cell line: 1>() ----> 1 os.listdir(Model_ScikitLearn_path) FileNotFoundError: [Errno 2] No such file or directory: '/data/dataiku/dss_data/managed_folders/COMPETIDORAS/v9OdRBEN'

My managed folder have:

{'path': '/data/dataiku/dss_data/managed_folders/COMPETIDORAS/v9OdRBEN', 'projectKey': 'COMPETIDORAS', 'directoryBasedPartitioning': False, 'name': 'Model_ScikitLearn', 'id': 'v9OdRBEN', 'accessInfo': {'root': '/data/dataiku/dss_data/managed_folders/COMPETIDORAS/v9OdRBEN'}, 'type': 'Filesystem'}

 

0 Kudos
1 Solution

Dataiku's little dirty secret: it doesn't actually create the folder in the file system until you put a file in it. Go to your flow and add a dummy file to the folder manually. Then your code should work fine after that.

View solution in original post

2 Replies
David08
Level 1
Author

The folder was create when I create the Python Recipe

0 Kudos

Dataiku's little dirty secret: it doesn't actually create the folder in the file system until you put a file in it. Go to your flow and add a dummy file to the folder manually. Then your code should work fine after that.