jake lee
07/30/2021, 9:02 AMFailed to load and execute Flow's environment: FlowStorageError('An error occurred while unpickling the flow:\n ModuleNotFoundError("No module named \'common\'",)\nThis may be due to a missing Python module in your current environment. Please ensure you have all required flow dependencies installed.',)
Again thank you so much!Kevin Kho
cloudpickle
works. You need to package your dependencies into a Docker container and use Docker Storage so that the agent can pull the container with the dependencies.
If you are using Local agent and LocalRun, there are two workarounds. First, is you can start the agent in the directory where the flow is so it has access to those files when it runs the flow. Second is that LocalRun
takes in a working_dir
where you can specify where the agent will run the flow from.jake lee
07/31/2021, 6:10 AMjake lee
07/31/2021, 10:18 AMimport sys
sys.path.append("..")
from common.Util import Util
so for the job I have set my directory as
flow.run_config = LocalRun(working_dir="/job")
but the task can’t figure out the common.Util, I’m sure this is a pretty basic question but please help a brother out! thank you so much!Kevin Kho
sys.path.append()
. It might be your working directory. Is that an absolute path?
Also, you can try running your agent in the job
directory and that might work. I think it’s just a matter of getting that path right.jake lee
08/04/2021, 11:45 PMKevin Kho