Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cut (Ctrl + X) deletes lines but pastes nothing #4185

Closed
ytyt-lead opened this issue Dec 9, 2020 · 5 comments
Closed

Cut (Ctrl + X) deletes lines but pastes nothing #4185

ytyt-lead opened this issue Dec 9, 2020 · 5 comments

Comments

@ytyt-lead
Copy link

Sometimes Ctrl + X works correctly (deletes lines from source cell and save them to the clipboard), but sometimes it just deletes lines from source cell and paste nothing into the destination cell. Ctrl + Z also doesn't restore deleted lines, so they are lost irretrievably.

Btw, Python extension become very buggy last month.
Ctrl + X doesn't work.
"Save as" doesn't work.
Variable explorer crashes after trying to display dictionary.
Phantom code in empty cell causes mythical syntax errors (like you type single line "x = 5" and get an error "()x = 5: invalid syntax").
Not cool at all, guys.

CPUs AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx (8 x 2296)
GPU Status 2d_canvas: enabled flash_3d: enabled flash_stage3d: enabled flash_stage3d_baseline: enabled gpu_compositing: enabled multiple_raster_threads: enabled_on oop_rasterization: disabled_off opengl: enabled_on protected_video_decode: unavailable_off rasterization: enabled skia_renderer: disabled_off_ok video_decode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled
Load (avg)  
Memory (System) 9.94GB (3.75GB free)
Process Argv --crash-reporter-id b0a3d91a-b073-470a-8715-c873fe3c9feb
Screen Reader no
VM 0%
@rchiodo
Copy link
Contributor

rchiodo commented Dec 9, 2020

Thanks for the feedback. I'll try to address each of the issues you found:

Ctrl + X doesn't work. -> This is a dupe of #4035

"Save as" doesn't work. -> Can you elaborate? This is likely by design if your picking from the file menu and you're not using the insiders version of VS code. File | Save and File | Save As are not supported with our older stuff as VS code doesn't recognize our 'editor' as being a document.

Variable explorer crashes after trying to display dictionary. -> Can you elaborate on this one as well? This might be a dupe of #4006

Phantom code in empty cell causes mythical syntax errors (like you type single line "x = 5" and get an error "()x = 5: invalid syntax"). -> This is this bug here which should be fixed very soon: #1701

@ytyt-lead
Copy link
Author

ytyt-lead commented Dec 10, 2020

Ctrl + X doesn't work. -> This is a dupe of #4035

No, this is not.
#4035 is about "deleting twice", and my issue is about "disappearing" of the code which was cutted.

  1. I cut some lines of code with Ctrl + X.
  2. Then I paste it in a new cell with Ctrl + V, and only 1 blank line appears.
  3. I try to paste from clipboard into any cell, including source cell - and nothing happens, only 1 blank line appears.
  4. I try to undo this cut - and nothing happens, my code just disappears.

This issue usually happens when I try to cut multiple line of code, not only one.

"Save as" doesn't work.

microsoft/vscode#108572

Variable explorer crashes after trying to display dictionary.

#4159
Already closed.

@rchiodo
Copy link
Contributor

rchiodo commented Dec 10, 2020

No, this is not.
#4035 is about "deleting twice", and my issue is about "disappearing" of the code which was cutted.

I cut some lines of code with Ctrl + X.
Then I paste it in a new cell with Ctrl + V, and only 1 blank line appears.
I try to paste from clipboard into any cell, including source cell - and nothing happens, only 1 blank line appears.
I try to undo this cut - and nothing happens, my code just disappears.
This issue usually happens when I try to cut multiple line of code, not only one.

This still sounds like the the same issue to me. CTRL+X is being handled twice. First time it cuts your actual lines. Second time it cuts a blank line. When you go to paste it pastes just the blank line. We have a potential fix for #4035 but we haven't been able to verify because nobody can repro. It was not in the latest release. Would you like to try a private binary?

microsoft/vscode#108572 is not a bug. It's by design. Unless you're using the insiders build of VS code or you end up in our 'custom editor' experiment, Save as is not supported for ipynb files.

#4159 should be fixed now. We released yesterday.

@greazer
Copy link
Member

greazer commented Dec 10, 2020

Ctrl-X is probably a dupe of #4035

@greazer
Copy link
Member

greazer commented Jun 5, 2021

Thanks for your feedback. This issue will be addressed once VS Code adds native support for editing notebooks. Please see microsoft/vscode#91987. You can experiment by using VS Code insiders, which defaults to the new notebook experience.

@greazer greazer closed this as completed Jun 5, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants