Skip to content

Missing autocompletion for python files in folders without __init__.py (Python Language Server) #2213

Description

@yznts

Environment data

  • VS Code version: 1.25.1
  • Extension version (available under the Extensions sidebar): 2018.7.0
  • OS and version: macOS 10.13.5
  • Python version (& distribution if applicable, e.g. Anaconda): 3.6
  • Type of virtual environment used (N/A | venv | virtualenv | conda | ...): virtualenv
  • Relevant/affected Python packages and their versions: None

Actual behavior

image

Expected behavior

Normal completion for nested files

Steps to reproduce:

  1. Trying to import from python file in folder without __init__.py

Logs

Logs for completed foo.bar()

Starting Microsoft Python language server.
[Info  - 10:05:14 AM] Created Microsoft.PythonTools.Interpreter.Ast.AstPythonInterpreter instance from Microsoft.PythonTools.Interpreter.Ast.AstPythonInterpreterFactory
Initializing for /usr/local/opt/python/bin/python3.6
##########Linting Output - pylint##########

--------------------------------------------------------------------
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)

##########Linting Output - pylint##########

--------------------------------------------------------------------
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)


Output from Console under the Developer Tools panel (toggle Developer Tools on under Help)

image

Activity

  1. ericsnowcurrently commented on Jul 31, 2018

    @ericsnowcurrently

    Thanks for letting us know about this, @yzinets. I was able to reproduce the problem. We'll take a look at it. I expect that the new language server is not taking namespace packages into account.

  2. MikhailArkhipov commented on Aug 23, 2018

    @MikhailArkhipov
  3. removed this from the Aug 2018 milestone on Sep 5, 2018
  4. luabud commented on Sep 11, 2019

    @luabud
    Member
  5. locked as resolved and limited conversation to collaborators on Sep 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area-intellisenseLSP-related functionality: auto-complete, docstrings, navigation, refactoring, etc.bugIssue identified by VS Code Team member as probable bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions