unexpected token 'open'
See original GitHub issueIssue Type: Bug
with open("test.html", 'w', encoding='utf-8') as f:
f.write(page.text)
unexpected token ‘open’
Extension version: 2018.7.0 VS Code version: Code 1.25.1 (1dfc5e557209371715f655691b1235b6b26a06be, 2018-07-11T15:43:53.668Z) OS version: Windows_NT x64 10.0.17134
System Info
Item | Value |
---|---|
CPUs | Intel® Core™ i5-5200U CPU @ 2.20GHz (4 x 2195) |
GPU Status | 2d_canvas: unavailable_software flash_3d: unavailable_software flash_stage3d: unavailable_software flash_stage3d_baseline: unavailable_software gpu_compositing: unavailable_software multiple_raster_threads: unavailable_off native_gpu_memory_buffers: disabled_software rasterization: unavailable_software video_decode: unavailable_software video_encode: unavailable_software vpx_decode: unavailable_software webgl: unavailable_off webgl2: unavailable_off |
Memory (System) | 7.92GB (4.18GB free) |
Process Argv | D:\Microsoft VS Code\Code.exe F:\文档\GitHub\Protein |
Screen Reader | no |
VM | 67% |
Issue Analytics
- State:
- Created 5 years ago
- Comments:11 (2 by maintainers)
Top Results From Across the Web
unexpected token 'open' · Issue #2210 · microsoft/vscode-python
I'm getting the issue as well. I believe I'm using the new language server, but don't have a way to check. I'm also...
Read more >How to solve unexpected token parser 16 visual studio code
There are 3 things that could be. The first is simple, restart your editor and see if the issue persists. The second thing...
Read more >SyntaxError: Unexpected token - JavaScript - MDN Web Docs
The JavaScript exceptions "unexpected token" occur when a specific language construct was expected, but something else was provided.
Read more >python unexpected token bug, in visual studio 2019
When you input Non-English characters, it will prompt “unexpected token”. Check your input method, use English input method to enter characters.
Read more >Unexpected Token Error in VS Code
I'm trying to set up VS Code for ObjectScript using the instructions found here. I've got both Cache 2018.1.2.309.0 and IRIS 2020.1.0.215.0.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Most probably was caused by threading issue where text buffer was going out of sync with between LS and VS Code. Fixed by https://github.com/Microsoft/PTVS/pull/4645
I am running Python 3.7.0
I did the same thing, and notice the server was downloaded again, and no longer received this error.