Linked Questions

Popular Questions

I'm trying to import a class from a module named Problem is, it's located within a directory called @file_directory.

So the structure is, I have at the top of the project directory, and also a directory called lib at the same level. Within 'lib' there is subdirectory named '@file_directory' and within it a module 'my_classes' as shown below.

-> /lib
   -> /@file_directory

What I can usually do is

from [email protected]_directory.myclasses import cust_class

But because the @ symbol is a wrapper symbol, it prevents me from importing files from '@file_directory'. The simple soultion is of course, just change the directory name but I want to keep the file name/don't have the rights to change it in the project. Is there a way to use like a escpae character to import module from a directory with special characters?

Related Questions