question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Extension stops working when code has too many imports in the same line

See original GitHub issue

Environment data

  • VS Code version: 1.35.1, 1.36.1
  • Extension version (available under the Extensions sidebar): 2019.6.24221
  • OS and version: Windows 10 Enterprise
  • Python version (& distribution if applicable, e.g. Anaconda): 2.7
  • Type of virtual environment used (N/A | venv | virtualenv | conda | …): N/A
  • Relevant/affected Python packages and their versions: N/A
  • Jedi or Language Server? (i.e. what is "python.jediEnabled" set to; more info #3977): Jedi is OFF

Expected behaviour

Debugger should work

Actual behaviour

Debugger is not working after opening a specific Python file

Steps to reproduce:

  1. Unzip the test project: https://www.dropbox.com/s/railr60ddnp6k2c/bad_file.zip
  2. Open test.py and launch the debugger. It works
  3. Open bad_file.py
  4. Switch back to test.py and try to launch the debugger again. It will not run.

The whole extension seems to be broken at this point. Outline view is blank. Intellisense not working…

Screen recording of this scenario: https://www.dropbox.com/s/2dse3bq6jbd4wf3/bad_file.mp4

Logs

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

Nothing interesting there:

Starting Microsoft Python language server.
[Info  - 2:46:30 PM] Analysis cache path: C:\Users\GLEBSturov\AppData\Local\Microsoft\Python Language Server
[Info  - 2:46:30 PM] GetCurrentSearchPaths C:\Programs\Python27\python.exe 
[Info  - 2:46:30 PM] Interpreter search paths:
[Info  - 2:46:30 PM]     c:\programs\python27\dlls
[Info  - 2:46:30 PM]     c:\programs\python27\lib
[Info  - 2:46:30 PM]     c:\programs\python27\lib\lib-tk
[Info  - 2:46:30 PM]     c:\programs\python27
[Info  - 2:46:30 PM]     c:\programs\python27\lib\site-packages
[Info  - 2:46:30 PM] User search paths:
[Info  - 2:46:30 PM] Microsoft Python Language Server version 0.3.20.0
[Info  - 2:46:30 PM] Initializing for C:\Programs\Python27\python.exe

Output from Console under the Developer Tools panel (toggle Developer Tools on under Help; turn on source maps to make any tracebacks be useful by running Enable source map support for extension debugging)

Nothing interesting there

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
karrtikrcommented, Aug 7, 2019

@DonJayamanne I can reproduce it in the older version of the extension (2019.6.24221), but no longer on the latest version of the extension. I am guessing this issue was related to sending telemetry for imports. We can close this now.

0reactions
DonJayamannecommented, Aug 7, 2019

@karrtikr I’m unable to repro this. Are there any errors? Is this a debugger issue or extension issue? FYI - I’m unable to repro this.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Problem with two imports on the same line in VSCODE with ...
When saving a file, I get two imports ... from ... in a single line, for example: import { PanelGroup } from 'rsuite';import...
Read more >
Don't multi-line imports (let them take less space) / Conflict ...
Hi. There is a bug somewhere when builtin VSCode's source.organizeImports feature is used together with Prettier. People sometimes prefer to ...
Read more >
6 Common CSV Import Errors and How to Fix Them - Flatfile
One of the most common CSV import errors is that the file is simply too large. That can be caused by too many...
Read more >
C/C++ extension FAQ - Visual Studio Code
Frequently asked questions about the C/C++ extension in Visual Studio Code. ... How do I get the new IntelliSense to work with MinGW...
Read more >
Classes should not have too many "static" imports
Java static code analysis. Unique rules to find Bugs, Vulnerabilities, Security Hotspots, and Code Smells in your JAVA code.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found