? ? Pending

User tests: Successful: Unsuccessful:

avatar laoneo
laoneo
3 Feb 2017

Pull Request for Issue #13867.

Summary of Changes

The SQL form field should handle SQL errors and not crash the page. Actually it enqueus the error message to the application, don't know if there is a better way to handle exceptions in form fields. @mbabker and @Bakual any clue?

Testing Instructions

  • Create a SQL form field with an invalid query like "An invalid query". image
  • Adit an article.

Expected result

An error message should be shown on the top of the page.

Actual result

The site crashes.

Documentation Changes Required

avatar laoneo laoneo - open - 3 Feb 2017
avatar laoneo laoneo - change - 3 Feb 2017
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 3 Feb 2017
Category Libraries
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 3 Feb 2017

I have tested this item successfully on 394f474


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/13882.

avatar franz-wohlkoenig franz-wohlkoenig - test_item - 3 Feb 2017 - Tested successfully
avatar Bakual
Bakual - comment - 3 Feb 2017

I'd say your proposal looks perfect. Catching the exception and converting to a message is the right thing here since we don't want to throw a full error page just because a single field doesn't work.

avatar zero-24 zero-24 - change - 4 Feb 2017
Labels Added: ?
avatar zero-24
zero-24 - comment - 4 Feb 2017

I have tested this item successfully on ea407b3


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/13882.

avatar zero-24 zero-24 - change - 4 Feb 2017
Milestone Added:
Status Pending Ready to Commit
Labels Added: ?
avatar zero-24
zero-24 - comment - 4 Feb 2017

RTC #jc17de


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/13882.

avatar zero-24 zero-24 - test_item - 4 Feb 2017 - Tested successfully
avatar zero-24 zero-24 - alter_testresult - 4 Feb 2017 - franz-wohlkoenig: Tested successfully
avatar rdeutz rdeutz - change - 4 Feb 2017
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-02-04 21:45:25
Closed_By rdeutz
Labels
avatar rdeutz rdeutz - close - 4 Feb 2017
avatar rdeutz rdeutz - merge - 4 Feb 2017
avatar PhilETaylor
PhilETaylor - comment - 23 Feb 2017

This doesnt work - currently at 3.7b3

avatar mbabker
mbabker - comment - 23 Feb 2017

It works just fine. It just doesn't work the way you think it should.

avatar PhilETaylor
PhilETaylor - comment - 23 Feb 2017

Im sorry - but the leaking of mysql column names to front end users is NOT acceptable to me.

avatar mbabker
mbabker - comment - 23 Feb 2017

Read my other rant. You're saying this PR doesn't work. I'm saying it does. It is indeed catching exceptions. But the handling of it is crap.

Add a Comment

Login with GitHub to post a comment