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

Can't copy from compiler error output #2931

Open
lrhn opened this issue Apr 19, 2024 · 2 comments
Open

Can't copy from compiler error output #2931

lrhn opened this issue Apr 19, 2024 · 2 comments

Comments

@lrhn
Copy link
Member

lrhn commented Apr 19, 2024

What happened?

I wrote a program with compilation errors.
I tried to copy one of the errors.
The moment I clicked in the lower-right area where compilation errors are printed, the text area scrolled to the bottom.
I got the selection start placed, so I tried to at least move the cursor back up to where I wanted the selection to end,
but the text are kept scrolling to the bottom.

Steps to reproduce problem

Have program with multiple errors. Fx:

void main() {
  int x = "a";
  int y = "b";
  int z = "c";
}

Try to select and copy the first error message in the compiler output:

main.dart:2:11: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
  int x = "a";
          ^

Good luck!

Please do not auto-move a text area that has focus. The user might want to be looking at the point they're at, or select from it.

Additional info

Browser

Browser: Google Chrome

Version: 123.0.6312.122 (Official Build) (64-bit)

Are you using any extensions/plugins that affect website behavior
(particularly those that affect iframes, such as ad blockers)?

No. (Corp Linux laptop, no unusual extensions).

Are there any warnings or errors in your browser's JavaScript console?

Nothing related to the issue, which is UI/UX.
(The failure to compile was reported as a bad POST message.)

Machine

Operating system: Linux

Version: Debian 6.6.15-2rodete2 (2024-03-19)

Your code

void main() {
  int x = "a";
  int y = "b";
  int z = "c";
}

DartPad's output

Did DartPad print anything to the console pane?
No

@eernstg
Copy link
Member

eernstg commented Apr 19, 2024

Good catch! I've seen similar things, but didn't get around to report it. Workaround for now: Select the pane by clicking anywhere inside that area, 'Select All' (⌘-A, Control-A), paste the resulting text, delete anything which is not needed.

@lrhn
Copy link
Member Author

lrhn commented Apr 19, 2024

Yep. That was how I got the error message to paste into this issue. After trying ... several other things.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants