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

Uncaught Error: entity w7409928 not found #3973

Closed
tko opened this issue Apr 17, 2017 · 14 comments
Closed

Uncaught Error: entity w7409928 not found #3973

tko opened this issue Apr 17, 2017 · 14 comments
Labels
waitfor-upstream Waiting for something in an upstream project

Comments

@tko
Copy link

tko commented Apr 17, 2017

Starting the editor seems to sometimes throw an exception leaving it in a state where not all details are loaded and seemingly never will. Reloading the page sometimes works, sometimes throws the same exception with different entity id (I've seen w7409928 and w59195767)

id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:57 Uncaught Error: entity w7409928 not found
    at hd.entity (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:57)
    at hd.parentWays (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:57)
    at t (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:4)
    at Object.Rd.i.rebase (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:4)
    at Object.merge (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11)
    at n (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11)
    at o (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11)
    at id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59
    at t (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59)
    at l (id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59)
entity @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:57
parentWays @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:57
t @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:4
Rd.i.rebase @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:4
merge @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11
n @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11
o @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:11
(anonymous) @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59
t @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59
l @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59
i.onreadystatechange @ id-63ec25b478c2af431aa10a2e5a9b6d4416ec6423217d481dc9b6d9cc3ee0bc11.js:59

http://www.openstreetmap.org/edit?editor=id#map=18/52.33752/4.59592

Chrome 58.0.3029.41 beta (64-bit), OS X 10.11.6

@tyrasd tyrasd added the waitfor-upstream Waiting for something in an upstream project label Apr 17, 2017
@tyrasd
Copy link
Member

tyrasd commented Apr 17, 2017

I saw something very similar in Chrome 58.0.3029.54 (Official Build) beta (64-bit), V8 5.8.283.24 on Linux a few days ago:

screenshot from 2017-04-17 15-41-01

Note the debug commands I issued after hitting the breakpoint – very strange!

As far as I can see it's probably a race condition inside Chrome's V8 doing some overly optimistic optimization or something. Not sure how to best follow up on this… Wait and see if this even lands in Chrome 58?

@bhousel
Copy link
Member

bhousel commented Apr 17, 2017

Hmm @tyrasd yeah that makes no sense. It really does seem to be a V8 bug.

@oiva
Copy link

oiva commented May 29, 2017

I'm seeing this too. Chrome 60.0.3107.4 (Official Build) dev (64-bit) and iD 2.2.1. Repeats on almost every load and as a result some of details are missing.

@oiva
Copy link

oiva commented May 30, 2017

Not sure if this is related but bumped into an error in Firefox where entities were undefined in coreGraph rebase:

for (i = 0; i < entities.length; i++) {

I can make a separate issue of this if necessary.

Edit: created #4072

@tyrasd tyrasd added bug-browser-specific A bug that only appears in certain browsers and removed waitfor-upstream Waiting for something in an upstream project labels Jun 8, 2017
@tyrasd
Copy link
Member

tyrasd commented Jun 8, 2017

We see this now even in the latest stable Chrome build (59.0.3071.86 (Official Build) (64-bit) / V8 5.9.211.31) on Linux (on Windows it's fine apparently, see #4094 (comment)). 😒

@tyrasd
Copy link
Member

tyrasd commented Jun 8, 2017

This is soo strange. No idea why and what is happening. (It's also quite hard to search for this in Chrome's bug tracker.)

What I found is: If one adds if (!entity) entity = this.entities.__proto__[id]; after core/graph.js#L36, it seems to work again.

@bhousel
Copy link
Member

bhousel commented Jun 8, 2017

Looking into this now.. What I've learned is that this gets broken when in tree.js, updateParents() calls parentWays()

call stack:

screenshot 2017-06-08 10 46 32

caller:

screenshot 2017-06-08 10 48 54

screenshot 2017-06-08 10 49 24

callee:

screenshot 2017-06-08 10 50 27

screenshot 2017-06-08 10 53 34

which is weird because it still knows how to actually call this.entity() :

screenshot 2017-06-08 10 54 45

screenshot 2017-06-08 10 55 01

@bhousel
Copy link
Member

bhousel commented Jun 8, 2017

What I found is: If one adds if (!entity) entity = this.entities.proto[id]; after core/graph.js#L36, it seems to work again.

I spend most of the morning trying to understand what's going on, but got nowhere, so I added this code for now.. If we ever find what upstream bug in Chrome/V8 is causing this we can link to the ticket here and remove the line if it's ever fixed.

@bhousel bhousel added the waitfor-upstream Waiting for something in an upstream project label Jun 8, 2017
@tyrasd
Copy link
Member

tyrasd commented Jun 8, 2017

@bhousel
Copy link
Member

bhousel commented Jun 8, 2017

Nice, thanks @tyrasd!

@dkewley
Copy link

dkewley commented Jun 12, 2017

I see this on Chrome OS 59.0.3071.91 too.

A suggestion: Consider updating default iD to have this patch so that those of us using Chrome on Linux or Chrome OS have a usable default iD. I ended up using iD master at http://preview.ideditor.com/master/ in order to be able to do any editing on Chrome OS. Thank you for finding and implementing a workaround on master!

@bhousel
Copy link
Member

bhousel commented Jun 12, 2017

A suggestion: Consider updating default iD to have this patch so that those of us using Chrome on Linux or Chrome OS have a usable default iD.

Yes, I'm making a new release of iD tomorrow 👍

@bhousel bhousel removed the bug-browser-specific A bug that only appears in certain browsers label Jun 13, 2017
@tyrasd
Copy link
Member

tyrasd commented Jun 19, 2017

It's now fixed in chrome/v8: https://chromium-review.googlesource.com/c/539596/ 👍

@bhousel
Copy link
Member

bhousel commented Jun 20, 2017

Great! I'm going to close this issue but I'll leave those extra lines of workaround code in the entity() function. We can remove them someday when Chrome 58/59 is a distant memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waitfor-upstream Waiting for something in an upstream project
Projects
None yet
Development

No branches or pull requests

5 participants