Uncaught (in promise) after adding layer the 2nd time to map

764
3
Jump to solution
01-17-2023 02:08 AM
Björn
by
New Contributor II

Hello,

I get an unspecified error message if I add an layer (in this case an geojson layer created from a blob) to the map, after I added & removed the same layer. Except for the error message, no visible malfunction occurs, but I would like to understand what the cause is. What could be the reason and how could I avoid the error message?

Error message in browser console (FYI: not in the internal codepen console): "Uncaught (in promise) k {name: 'AbortError', details: undefined, message: 'Aborted'}"

Example: https://codepen.io/hjmd/pen/OJwjaKJ?editors=1000

FYI: Sometimes it does not happen on the first run of the codepen, but after a reload of the page (F5).

Thank you in advance!
Björn

 

Tags (3)
0 Kudos
1 Solution

Accepted Solutions
UndralBatsukh
Esri Regular Contributor

Hi there, 

Sounds like you are running into a behavior described here: https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/aborterror-when-deleting-a-layer-... This issue will be fixed at version 4.26. In meantime, you can test the fix on our next release by the end of this week by pointing your app to:  <script src="https://js.arcgis.com/next/"></script> 

I was not able to reproduce the issue in 4.25. But I did test your codepen using next and did not see the abortError.

View solution in original post

3 Replies
UndralBatsukh
Esri Regular Contributor

Hi there, 

Sounds like you are running into a behavior described here: https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/aborterror-when-deleting-a-layer-... This issue will be fixed at version 4.26. In meantime, you can test the fix on our next release by the end of this week by pointing your app to:  <script src="https://js.arcgis.com/next/"></script> 

I was not able to reproduce the issue in 4.25. But I did test your codepen using next and did not see the abortError.

Björn
by
New Contributor II

Yes, it seems that the error message doesn't appear with the "next" release version. Thank you for your feedback!

0 Kudos
Taras
by
New Contributor

Hello,

I am faced with the same type of error on the 4.29 version. 

I was able to reproduce the issue in the example pointed out above after a few refreshes, and I really can't reproduce it on the 4.26 version example 

But here is 4.29 version example where it reproduces sporadically and mostly always after a page hard reload. 

Thanks in advance, Taras

0 Kudos