Conversation
|
Hey! Your PR title Please update it to start with one of:
Where See CONTRIBUTING.md for details. |
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
|
That failure is unrelated to my fix... In fact, I think my fix fixes what that failure is complaining about: you no longer have to pass something because now the default DOES work. |
|
Well, the type changed so these have to be fixed. |
Many callsites don’t pass duration, relying on the default. The way the default was specified was wrong, resulting in an 'undefined' value if no duration is passed instead of 5000. Passing `undefined` to setTimeout causes an immediate timeout (in practise a very shortly visible TUI toast UI.
c7a32d4 to
c9638c9
Compare
Still, not related to this one-liner fix. I hope the fact that it says "Some checks were not successful" isn't going to be a reason that no is going to review this patch. |
|
Replaced by #18113 |
Many callsites don’t pass duration, relying on the default. The way the default was specified was wrong, resulting in an 'undefined' value if no duration is passed instead of 5000.
Passing
undefinedto setTimeout causes an immediate timeout (in practise a very shortly visible TUI toast UI.Issue for this PR
Closes #17191
Type of change
What does this PR do?
It fixes that the default of 5000 is actually used if nothing is passed, instead of getting
undefined.How did you verify your code works?
I run opencode in a container with a network namespace; everything is firewalled, so I got for every attempt to connect some https:// url the vague error "Unable to connect. Is the computer able to access the url?" which showed up so short that there was hardly time to read it.
I could reproduce this simply by testing "test" and hitting enter on a prompt.
After applying this patch that changed to a neat 5 seconds long visible error, as it should.
Checklist
If you do not follow this template your PR will be automatically rejected.