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

Macro prompt dialogs open very slowly when there is a console on the page #2114

Closed
3b opened this issue Jan 11, 2025 · 3 comments
Closed

Macro prompt dialogs open very slowly when there is a console on the page #2114

3b opened this issue Jan 11, 2025 · 3 comments
Labels
⚡ Type: Bug Something isn't working

Comments

@3b
Copy link

3b commented Jan 11, 2025

Mainsail Version:

v2.13.2

Browser:

Firefox

Device:

Desktop PC

Operating System:

Windows

What happened?

On screens with a console (/console, or / on desktop with a console panel), opening dialogs is very slow.
Other windows open at same time (/config, / on mobile without console panel, etc) show the dialog almost instantly.

What did you expect to happen instead?

Dialog opens quickly regardless of screen.

How to reproduce this bug?

Create a gcode macro that uses prompt dialogs.

[gcode_macro menu_test]
gcode:
  RESPOND TYPE=command MSG="action:prompt_begin start"
  RESPOND TYPE=command MSG="action:prompt_text 123"
  RESPOND TYPE=command MSG="action:prompt_text 456"
  RESPOND TYPE=command MSG="action:prompt_button 1"
  RESPOND TYPE=command MSG="action:prompt_button 2"
  RESPOND TYPE=command MSG="action:prompt_button 3"
  RESPOND TYPE=command MSG="action:prompt_button 4"
  RESPOND TYPE=command MSG="action:prompt_footer_button done|RESPOND TYPE=command MSG=action:prompt_end|warning"
  RESPOND TYPE=command MSG="action:prompt_show"

Open pages with and without consoles, then activate the macro. Windows showing pages with consoles take a few seconds to show the dialog, while it is quick on others.

Additional information:

also applies to at least firefox on android, and edge on windows.

The actual problem/cause might be "console is slow", not sure, but either way it makes debugging macros tedious.

@meteyou
Copy link
Member

meteyou commented Jan 11, 2025

it should not make any diffrenece if you have a console or not. its maybe just the rendering time of the console itself (maybe you have a huge number of new lines in your console).

so its just the GUI rendering time. nothing special to it. macro prompts are very slow an not made for "high speed inputs"

@meteyou meteyou closed this as not planned Won't fix, can't repro, duplicate, stale Jan 11, 2025
@3b
Copy link
Author

3b commented Jan 11, 2025

It seems to be the total number of lines in console. with empty console, it can add about 50 lines per second. With 500 lines in console it is about 2-3 per second (meaning about 3-4 seconds before a 10 line menu shows up).

Seems to drop off at around 500 rather than slowing proportional to size.

@meteyou
Copy link
Member

meteyou commented Jan 11, 2025

yeah, thats sounds reasonable! i think its more a "console bug" instead of a "macro prompt" bug

EDIT: pls open a new bug report with this description. maybe i can change the rendering to "render only visible entries"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⚡ Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants