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

Returning error as the last argument mangles '%s' and co. #388

Closed
mstoykov opened this issue May 16, 2022 · 0 comments
Closed

Returning error as the last argument mangles '%s' and co. #388

mstoykov opened this issue May 16, 2022 · 0 comments
Labels

Comments

@mstoykov
Copy link
Contributor

Returning error as the last argument mangles the final .Error() result as it goes through fmt.Sprintf with no arguments which makes all fmt verbs to become MISSING.

The fix seems to be to just not run through fmt when it's not needed 🤷

Originally reported in grafana/k6#2537

mstoykov added a commit to mstoykov/goja that referenced this issue May 16, 2022
mstoykov added a commit to mstoykov/goja that referenced this issue May 16, 2022
@dop251 dop251 closed this as completed in 4418d45 May 16, 2022
@dop251 dop251 added the bug label May 16, 2022
Gabri3l pushed a commit to mongodb-forks/goja that referenced this issue Sep 1, 2022
Gabri3l added a commit to mongodb-forks/goja that referenced this issue Mar 15, 2023
* Fixed panic in newArrayFromIter when the iterator is already closed. Fixes dop251#375
* Fixed panic when parsing invalid object property keys. Fixes dop251#376.
* Fixed accidental shadowing in the else branches of type assertion
* Fixed defineProperty("length") for arrays. Improved detection of non-standard array configurations. Upgraded tc39 tests.
* Return true values of struct fields or reflect slice elements, rather than pointers to them. Closes dop251#378.
* Upgraded dependencies. Closes dop251#380.
* Implemented exponentiation expressions. Closes dop251#381.
* Enabled tests that use ** operator. Some array fixes as a result.
* Implemented nullish coalescing operator (??). Closes dop251#382.
* Implemented `{Array,String,%TypedArray%}.prototype.at` (dop251#384)e7c2872c8)
* Fixed callee expressions in optional chains. Fixes dop251#385.
* Do not use fmt.Sprintf() for plain error strings. Fixes dop251#388.
* Implemented 'copy-on-change' mechanism for inner compound values. Fixes dop251#403.
* Fixed objectGoReflect equality. See dop251#403
* Don't clear interrupt until the stack is empty (dop251#405)
* test: skip Promise based tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants