Closed (cannot reproduce)
Project:
Drupal core
Version:
8.0.x-dev
Component:
base system
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
29 Dec 2010 at 12:52 UTC
Updated:
25 Sep 2018 at 18:52 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
Bence commentedI can confirm this error message.
Comment #2
bfroehle commentedSteps to reproduce: Do any batch operation, like going to admin/reports/updates/check. Wait for it to finish, hit the back button in your browser. Boom!
The issue stems from the generic use of
in _batch_page().
What we should be doing in this function is checking if op=do (which indicates an AJAX request) and returning an AJAX error message in that situation.
This leads to much prettier error messages as shown in the file attachments.
I did a cursory search for duplicates but didn't find any. Apologies if somebody else has already figured this out.
Patch attached.
Comment #3
bfroehle commentedRetitling -- there's not way to "fix" the error -- but what we can do is display a human readable error message "No active batch" rather than some html gobbeldygook.
Comment #4
bfroehle commentedAdding a usability tag, since that's what this issue is about.
Comment #5
bfroehle commentedComment #6
sphism commentedThis patch no longer applies since all core files are now in /core
I'll try to reroll the patch and post it back here
Comment #7
sphism commentedHmm... I think this patch is rerolled but now i'm getting a 500 error in drupal and have to go out... I'll check this later on... here's the patch anyway
Comment #8
sphism commentedOk I just tried to replicate this issue and apply that patch... The issue doesn't appear to be there any more and I've a funny feeling this commit fixed this issue:
#229825-89: backport "$_COOKIE['has_js'] must die" patch to 7.x
Which would mean this issue can be closed, and this patch discarded as unnecessary.
Comment #9
yesct commentedComment #10
yonailoHello,
This issue still exists in D7, and I can confirm that the proposed backport patch of #229825 (backport "$_COOKIE['has_js'] must die" patch to 7.x) does not solve this issue.
The patch "1009716-fix-batch-error-messages_rerolled.patch" applies cleanly to D7 (patch -p2) and it solves this issue. This should be scheduled for backporting IMHO.
Comment #11
suchdavid commentedHi
I think the previous patch doesn't work because it has wrong path for batch.inc. Otherwise the solution works. At least shows nicer error message. I corrected the patch for D7.