As described in the title, I cannot get the import suggestions of classes starting with underscore (e.g: _A). Is there any VSCode or Python extension settings that I can modify to fix this issue?
CodePudding user response:
Adding __all__ = ['_My_Class', 'Name_Of_Other_Classes']
to the top of the file in which _My_Class is located MAY help.
It defines which classes should be imported by default when using the import file_with__my_class
statement. But even without the __all__
statement, the import suggestions work by default in my environment, as intended.
CodePudding user response:
I recommend using an autocomplete coding service. That should help.