Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upError message patterns prevent Firefox from improving messages #55
Comments
miketaylr
changed the title
Erorr message patterns prevent Firefox from improving messages
Error message patterns prevent Firefox from improving messages
Oct 19, 2018
This comment has been minimized.
This comment has been minimized.
In retrospect, I should never have implemented a runtime counterpart to I'm sorry that this has prevented you from making progress. For now, the fastest path forward will probably be to add support for your new error messages here: https://github.com/facebookincubator/idx/blob/master/packages/idx/src/idx.js#L62 But if you have someone who you're working with at Flipkart, we should strongly encourage them to adopt |
This comment has been minimized.
This comment has been minimized.
davidben
commented
Oct 19, 2018
Perhaps You may need to feature-detect support and fallback to error regexes, but it should leave newer browsers unconstrained. |
This comment has been minimized.
This comment has been minimized.
Either suggestion seems fine to me. I would even be fine with changing But I probably won't be able to improve the polyfill anytime soon. I can help review pull requests, though. |
This comment has been minimized.
This comment has been minimized.
@miketaylr, were you able to resolve the matter with Flipkart by using |
This comment has been minimized.
This comment has been minimized.
Closing this out due to inactivity. Feel free to open a new issue if you or anyone would like to revive the discussion about doing away with the runtime implementation. |
miketaylr commentedOct 19, 2018
Over in Bug 1498257, we've had to back out some DX improvements to error messages from Firefox's JS engine because it broke Flipkart (the number 6 site in India, top 150 globally).
It turns out the reason is idx, see https://bugzilla.mozilla.org/show_bug.cgi?id=1498257#c7 for more details.
https://github.com/facebookincubator/idx/blob/master/packages/idx/src/idx.js#L73-L84
I'm not sure how widely this lib is used, but fixing here would allow us to attempt error message improvements again.
https://hg.mozilla.org/integration/mozilla-inbound/rev/f0c6e521429c is the changeset that was backed out. Some example improved error messages are:
TypeError: win.browser.runtime is undefined, can't access property "getManifest" of it
TypeError: [...][Symbol.iterator](...).next(...).value is null, can't access property Symbol.iterator of it