-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Vega triggers override mistake when overriding O.p.hasOwnProperty by assignment #3075
Comments
I suspect the problem is in https://github.com/vega/vega/blob/master/packages/vega-util/src/hasOwnProperty.js. Do you have an idea how we can resolve the issue you are seeing? |
No, that's not the problem. There is nothing about that file that would trigger the override mistake. My first post above #3075 (comment) explains the problem well, but complains about the wrong file. The problem is in vega-util/build/vega-util.js . Aside from that, please ask about anything unclear in the explanation in that first post. Vega actually has three problems along these lines, for |
I just looked again at your sources rather than my patch. It looks like my patch is against, not a source file, but a file built from those sources. Is that correct? If so, then my first post was correct. The problem is in docs/vega-code.js and docs/vega.js . |
See #3109 |
Closed via #3109 |
At docs/vega-core.js line 32463 and at doc/vega.js line 45238 appears the line
This
exports
object inherits fromObject.prototype
which has a method namedhasOwnProperty
. Unfortunately, because of the EcmaScript Override Mistake (also here and here), in running in an environment (like SES, XS, or TC53 JavaScript for Embedded Systems) whereObject.prototype
is frozen, the Override Mistake will cause that assignment to fail.From the line numbers above, it is clear these two files are generated files. However I do not understand what the actual source lines are that are translated into these generated lines, so I'm not sure what the best fix is. Two immediate possibilities:
exports
not inherit fromObject.prototype
. Depending on the role ofexports
in the translation, I would not be surprised if that is not feasible.defineProperty
rather than assignment, such asSee Agoric/agoric-sdk#2373 for the consequences of this bug in the Agoric use of SES.
The text was updated successfully, but these errors were encountered: