There was a similar thread for D7 - #2808789: Fix "An AJAX HTTP request terminated abnormally" alert after user has navigated away from the page.

The problem we are experiencing is mostly in JS functional tests having the autosave_form module enabled where ajax request are triggered at a specific interval but the form is submitted before an ajax request has finished, in which case the ajax request is terminated and drupal is throwing a JS error, at which point phantomjs will interrupt the test and exit with an error.

Proposed resolution

Do not throw the error if the response has the status code 0 and the unbeforeunload event has been triggered.

Remaining tasks

User interface changes

API changes

Data model changes

Members fund testing for the Drupal project. Drupal Association Learn more


hchonov created an issue. See original summary.

hchonov’s picture

nod_’s picture

Issue tags: +JavaScript

Version: 8.4.x-dev » 8.5.x-dev

Drupal 8.4.0-alpha1 will be released the week of July 31, 2017, which means new developments and disruptive changes should now be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.