Skip to content

Conversation

@oDomLuiz
Copy link

In all executions of import_logged_model or mlflow_utils.set_experiment(), if its second parameter is set to None, it prevents mlflow_utils.set_experiment() from executing the mandatory create_workspace_dir() step due to the lack of dbx_client, generating the error below:

`sys.exit(main())`
File "/usr/local/lib/python3.10/site-packages/click/core.py", line 1485, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.10/site-packages/click/core.py", line 1406, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.10/site-packages/click/core.py", line 1269, in invoke 
return ctx.invoke(self.callback, **ctx.params) 
File "/usr/local/lib/python3.10/site-packages/click/core.py", line 824, in invoke 
return callback(*args, **kwargs) 
File "/usr/local/lib/python3.10/site-packages/mlflow_export_import/logged_model/import_logged_model.py", line 123, in main 
import_logged_model( 
File "/usr/local/lib/python3.10/site-packages/mlflow_export_import/logged_model/import_logged_model.py", line 51, in import_logged_model 
exp = mlflow_utils.set_experiment(mlflow_client, None, experiment_name) 
File "/usr/local/lib/python3.10/site-packages/mlflow_export_import/common/mlflow_utils.py", line 33, in set_experiment
create_workspace_dir(dbx_client, os.path.dirname(exp_name))
File "/usr/local/lib/python3.10/site-packages/mlflow_export_import/common/mlflow_utils.py", line 90, in create_workspace_dir
dbx_client.post("workspace/mkdirs", { "path": workspace_dir })
AttributeError: 'NoneType' object has no attribute 'post'

Therefore, I imported create_dbx_client and created the dbx_client, passing it as a second parameter, thus correcting the error.

@a-gajam
Copy link
Collaborator

a-gajam commented Dec 12, 2025

LGTM. Do you have bandwidth to do the same for import-traces?

@a-gajam a-gajam self-requested a review December 12, 2025 18:01
@a-gajam a-gajam added the bug Something isn't working label Dec 12, 2025
@oDomLuiz
Copy link
Author

oDomLuiz commented Dec 15, 2025

LGTM. Do you have bandwidth to do the same for import-traces?

Adjustment also made for import-traces

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants