RPA Studio, python scripts and modules

Hello, I’m having trouble organising my python code into submodules.

ATM I have a flow which just runs a python script. This works ok.

Now I’m trying to tidy up and separate this script into modules to be reused in other flows but I’m unable to do it.

From main I tried:

  • import helpersBDT
  • from . import helpersBDT
  • from helpersBDT import timestampString

I either get

  • ImportError: attempted relative import with no known parent package
  • ModuleNotFoundError: No module named ‘helpersBDT’

I have my helpersBDT.py in the same folder as the original script and I added a init.py file.

I’m running out of ideas.

Thanks,
Ana