Improve local testability
Closed this issue · 3 comments
Running Pkg.test("MLJFlow")
locally requires that an MLflow service is already running on your machine and that the uri "http://localhost:5000" will work to connect to it. On my mac, that uri will not work and I must manually edit it to be "http://127.0.1:5000", which is a pain.
Here's one suggestion: To run tests one must set a local env variable "MLFLOW_URI" to the uri of an active MLflow service. If the env is empty a helpful warning explaining what to do is thrown.
@pebeto Do you have any other suggestions?
In this case, are we going to set a default value for MLFLOW_URI
?
I consider this change like something practical, but it can be tedious for the end-user. However, not all of us have mljflow
running on the same port, so I think it's good to go.
| In this case, are we going to set a default value for MLFLOW_URI?
The problem with setting a default is this: If we get an error, how do we know it's because the URI's don't match and not for some other reason?
Reopening as not complete. We need to:
-
Change the URI's in tests to the one set by the environment var. There at two places, here is one:
Line 2 in 4387aef
-
Set the env variable appropriately in CI.yml
@pebeto In the future, can we please have reviewable PR's for new changes, rather than direct commits to dev?