09-30-2023 08:14 PM
I am using %run command to import shared resources for each of my processes. Because it was the most easy way to import my common libraries. However, in that way, pyflake can't resolve the dependencies quite well. And I end up working in code with many red lines populated by pyflake. I have attached just one pyflake dependency error.
Is there a way for pyflake to load code which been loaded using %run magic command? Or in general how are you guys handling common utility file aside from the main processing file inside databricks?
09-30-2023 08:15 PM
10-03-2023 12:58 AM
You could use something like flake8 and customize the rules in the .flake8 file or ignore specific lines with #noqa.
10-04-2023 07:53 PM
Thank you for your reply, it's definetaly a way not to see the red lines.
However I am not sure it's a feasible way.
It would be best if there's a way a code formatter could detect classes and imports from file which loaded to databricks by %run command.
10-04-2023 11:34 PM
Hi @Eeg , Would you like to raise a request?
10-05-2023 12:05 AM
Sure, is this the right way to raise a request?
https://docs.databricks.com/en/resources/ideas.html#submit-feedback-from-the-workspace
10-05-2023 12:20 AM
Yes, Indeed.
10-04-2023 12:59 AM - edited 10-04-2023 12:59 AM
Hi @Eeg, We haven't heard from you since the last response from @btafur, and I was checking back to see if his suggestions helped you.
Or else, If you have any solution, please share it with the community, as it can be helpful to others.
Also, Please don't forget to click on the "Accept as Solution" button whenever the information provided helps resolve your question.
Excited to expand your horizons with us? Click here to Register and begin your journey to success!
Already a member? Login and join your local regional user group! If there isn’t one near you, fill out this form and we’ll create one for you to join!