Repository navigation
bug: pygame.error video system not initialised in pygame #16098
Copy link
Copy link
Closed
Labels
area-editor-*User-facing catch-allUser-facing catch-allbugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable buginfo-neededIssue requires more information from posterIssue requires more information from poster
Description
Pygame gives error pygame.error: No available video device on vs code while running a program but the same program when ran it pycharm , it gave no error. The drivers are updated too.
Environment data
- VS Code version: Version: 1.55.2
- Extension version (available under the Extensions sidebar): v202
- OS and version: Linux x64 5.8.0-50-generic snap
- Python version (& distribution if applicable, e.g. Anaconda): XXX
- Type of virtual environment used (N/A | venv | virtualenv | conda | ...): N/A
- Relevant/affected Python packages and their versions: XXX
- Relevant/affected Python-related VS Code extensions and their versions: XXX
- Value of the
python.languageServersetting: XXX
[NOTE: If you suspect that your issue is related to the Microsoft Python Language Server (python.languageServer: 'Microsoft'), please download our new language server Pylance from the VS Code marketplace to see if that fixes your issue]
Expected behaviour
Actual behaviour
Steps to reproduce:
[NOTE: Self-contained, minimal reproducing code samples are extremely helpful and will expedite addressing your issue]
- XXX
Logs
Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)
Error 2021-04-30 13:43:15: stderr jediProxy Error (stderr) /home/karuna/.vscode/extensions/ms-python.python-2021.4.765268190/pythonFiles/completion.py:590: DeprecationWarning: Providing the line is now done in the functions themselves like `Script(...).complete(line, column)`
script = jedi.Script(
/home/karuna/.vscode/extensions/ms-python.python-2021.4.765268190/pythonFiles/completion.py:590: DeprecationWarning: Providing the column is now done in the functions themselves like `Script(...).complete(line, column)`
script = jedi.Script(
/home/karuna/.vscode/extensions/ms-python.python-2021.4.765268190/pythonFiles/completion.py:590: DeprecationWarning: Deprecated since version 0.17.0. Use the project API instead, which means Script(project=Project(dir, sys_path=sys_path)) instead.
script = jedi.Script(
/home/karuna/.vscode/extensions/ms-python.python-2021.4.765268190/pythonFiles/completion.py:624: DeprecationWarning: Deprecated since version 0.16.0. Use Script(...).infer instead.
script.goto_definitions(), request["id"]
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area-editor-*User-facing catch-allUser-facing catch-allbugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable buginfo-neededIssue requires more information from posterIssue requires more information from poster


Activity
kimadeline commentedon May 3, 2021
Hi Karuna Tata (@starlightknown), thank you for reaching out.
Does the program run if you run it in the terminal directly? A quick search for
pygame.error: No available video devicereturns a couple of Stack Overflow questions, are they any of the answers that are relevant to your use case?starlightknown commentedon May 4, 2021
no it doesn't and yes I tried all those solutions from stackoverflow , they didn't work. One solution which was
import pygame pygame.init() pygame.display.list_modes()did something but raised another error video not initializedkimadeline commentedon May 4, 2021
If your program doesn't run in the terminal, then it isn't a problem with the extension itself, but with your program. As such, I will move your question to a discussion.