Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
TEMPORAL WORKAROUND: https://www.reddit.com/r/vscode/comments/i45agt/cannot_type_code_into_python_interactive_console/
EDIT: this is a bug in new version of VSCode. There are also a few issues raised on github with the same problem. I will leave the question here, despite that it still gets minus points and got closed twice, as I was not able to find out any answer by googling, maybe it will help someone.
... Asking the same question once again, could you please tell me what details shall I add or how to specify the problem in better way, before you close it again in 10 minutes? I am desperate, can not work and have no one to ask, there is nothing on google with this issue....
So I am using VSCode and an interactive environment. By now everything worked just fine and I am not aware that something changed (I have not installed anything new, nor updated anything, so it might have been done somewhere in the background). Now the problem arises: I am able to run interactive, but only from the script with using cells #%% , however, the interactive window does not allow me to write anything into it directly into Type code here and press shift-enter to run. What is even more strange, yesterday it allowed me to write into this window some code and execute it and then suddenly it stopped working and I had to write code into the script again...
I am using VSCode Version: 1.51.1 and python 3.7.4 64-bit.
I have the same issue - it seems to be a bug in VScode. The only thing that works is simply to close it and open it again, until they fix it - anoying as it is
Related
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 1 year ago.
Improve this question
I'm using the Dark+ (default dark) theme in VS code for my normal python script writing. I recently started learning Jupyter Notebook with a course I'm taking and quickly realized that although the Jupyter notebook theme is very similar to the theme for python, it's not exactly the same. It's missing some colors.
As you can see "pandas" "pd" are teal (greenish blue), while "df" is light blue.
However all of those words in jupyter are completely white.
I tried playing around with other themes and the same issue is there. Not sure what's the issue and how can I fix it. I'm running it on a local machine on windows. Not using WSL, I think I had read that this is an issue with WSL.
The Jupyter Notebook in the VSCode lack of the support of Semantic Token Colorization. Like this:
The JupyterNoteBook lacks this feature for now. You can refer to this page for more details.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
Improve this question
I heard that it is not possible to give input to the python program In VS Code and for this issue We should open the python file on Command Prompt.
I wonder is it really true? Because Sometimes I write code on VS Code it asks for Input but sometimes It doesn't show anything. So what is going on?
The official python extension of VSCode provides Run and Debugging, almost like a IDE. It's impossible not to support input.
As for the source of your misunderstanding, it may be an extension like Code Runner, which does not support input, just quickly help you run the code and display the output.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
I've searched the Google and on stackoverflow for this, so if it exists anywhere, my sincerest apologies. I'm (obviously) a newbie to Python, and one of my main concern with finding a new module that does whatever new programming project comes my way is this:
What's preventing a module (once imported) from doing nefarious things, such as logging all keystrokes while the script is executing, then emailing that out?
Am I being paranoid?
Is this not possible in Python?
Is there a website where modules have been code reviewed, and people can download / install them without needing to worry?
Do I have to read the code of every module / sub-module every time I download it to ensure this exact thing isn't happening?
I'm currently using Python 3.5.1 64-bit on Windows 8, but I doubt that's too relevant.
Nothing prevents it. That's one of the benefits of open-source software (in the strictest sense of "source code that I can view"): you can, in theory, examine it to see exactly what it does before actually running it.
In practice, you usually just extend some level of trust to the source:
Is the module in wide use, such that others would have discovered or mentioned a problem in the first place?
Did I get the module from a reputable source?
Does the checksum of my copy match the checksum provided by my source?
If the answer to all three is yes, you can assume that the module isn't doing anything shady without explicitly verifying it yourself.
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 6 years ago.
Improve this question
I am running wine on Ubuntu 14 to execute a windows application on multiple files from the shell. From the 3000 files, about 4 or 5 fail and raise a pop up error which stops the loop. Then I need to press OK in order for the loop to continue. Is there any parameter in wine, (or some shell command in linux) to ignore errors?
I would like the loop to continue without me having to be there to press OK.
EDIT:
I am running the loop in python and using os module to execute the command in the shell so if there's anything I can do from the Python side using os that would work too.
The steps in the following link solved my issue! https://wiki.winehq.org/FAQ#How_do_I_disable_the_GUI_crash_dialog.3F
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 2 years ago.
The community reviewed whether to reopen this question 8 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I started to learn python language, and decided to try out PyCharm IDE, which looks really nice. But, whenever I write print it says "Unresolved reference 'print'". I can run the program, but this red-underline is really annoying. How can I fix this?
I have had the same problem as you, even though I configured Python 3.4.0 as the project's interpreter and all print's in the code were Python 3 compliant function calls.
I got it sorted out by doing this in PyCharm:
File -> Invalidate Caches / Restart... -> Invalidate and Restart
If you're in PyCharm and you're getting "Unresolved reference xrange" it's because xrange was removed in Python 3. Range takes over its functionality now. Was working on fast string concat from here:
https://waymoot.org/home/python_string/
And credit for the answer is from /r/learnpython:
https://www.reddit.com/r/learnpython/comments/2udj3s/pycharm_issue/
This could be related to the version of python you are using. Under python 2.x print is a statement:
print "hello world"
Under python 3, print is now a function call:
print("hello world")
Same problem, I deleted the .idea and __pycache__ directories in the project directory and everything was fine :)
Just delete .idea folder from your project directory.