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

image requests that used to be queued can't be aborted #7650

Closed
ansis opened this issue Nov 30, 2018 · 1 comment · Fixed by #7655
Closed

image requests that used to be queued can't be aborted #7650

ansis opened this issue Nov 30, 2018 · 1 comment · Fixed by #7655
Assignees
Labels

Comments

@ansis
Copy link
Contributor

ansis commented Nov 30, 2018

Image requests that are queued return a Cancelable object that only cancels the request if the request is still queued. Once the request has been unqueued it is not possible to abort the network request. Calling cancel at that point will do nothing.

return { cancel() { queued.cancelled = true; } };

@mourner I don't think this should block the beta because it is already in the previous version. should it block the final release?

mapbox-gl-js version: v0.50 and master

browser: all

Steps to Trigger Behavior

  1. open http://localhost:9966/debug/satellite.html#7.85/58.009/-113.643 in large viewport to queue up image requests
  2. wait a bit so that some requests complete and queue requests start
  3. zoom quickly to abort requests

Link to Demonstration

http://localhost:9966/debug/satellite.html#7.85/58.009/-113.643

Expected Behavior

Requests for previously queued images abort.

Actual Behavior

Requests for previously queued images do not abort.

@mourner
Copy link
Member

mourner commented Nov 30, 2018

It's not critical but may affect performance, so I'd cherry-pick the fix into beta if there's time. Submitted a potential fix in #7655.

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