Page MenuHomePhabricator

SRF - Exhibit queries no longer work with SMW 1.6
Closed, DeclinedPublic

Description

Author: mitchell_neill

Description:
Hi.

I've just updated to SMW 1.6RC1 to perform some regression testing. This meant I had to update SRF to version 1.6RC1 r93379.

Exhibit queries no longer work and it seems to be making external calls now to simile.org. Something major has obviously changed, but I cannot see any reference on the MW SRF page.

e.g.

{{#ask:
[[Category:Articles]]
[[Headline::+]]

?Headline
?Body Text
?Day
?Month
?Year
facets=Year,Month
format=exhibit

}}

now returns nothing.

This will break all the SMW websites I have deployed as I use exhibit a lot.

Thanks.


Version: unspecified
Severity: normal

Details

Reference
bz30096

Event Timeline

bzimport raised the priority of this task from to High.Nov 21 2014, 11:54 PM
bzimport set Reference to bz30096.
bzimport added a subscriber: Unknown Object (MLST).

it seems to be making external calls now to simile.org.

I hope you mean that svn is pulling from that site, and not that resources are getting loaded from there when actually using Exhibit? I recently replaced the copy of Exhbit in SRF with an svn externals to trunk of the exhibit repo.

I also attempted to fix Exhibit compat with MW 1.17, but apparently broke things. I will revert these changes soonish, as I don't have time to debug and fix this.

mitchell_neill wrote:

Hi Jeroen.

No, when an exhibit query now runs you can see it making calls out to simile.org.
Perhaps svn is pulling the new Exhibit V3?

I guess the simple short term resolution is to make SRF 1.4.3 compatible with SMW 1.6. It throws an error at present, but I would think it would be easier to fix this than try to sort out exhibit itself. This way a compatibility path will be maintained.

Cheers
Neill.

mitchell_neill wrote:

FYI. SRF 1.5.3 error when running with SMW 1.6 is:
PHP Fatal error: Declaration of SRFExhibit::getResultText() must be compatible with that of SMWResultPrinter::getResultText() in /var/www/webapps/iow/extensions/SemanticResultFormats/Exhibit/SRF_Exhibit.php on line 452

Sorry in comment 2 above 1.4.3 should read 1.5.3 :)

Cheers
Neill.

Modifying SRF 1.5.x to work with SMW 1.6.x or above is not practical. The easiest way to fix this is just revert the changes I made a few days ago.

No, when an exhibit query now runs you can see it making calls out to

simile.org.

That's not very nice...

Perhaps svn is pulling the new Exhibit V3?

It's pulling Exhibit trunk. I was hoping this would get rid of previously reported JS issues, but if this causes problems, I'll also just revert. I really don't have time ATM to do anything more.

mitchell_neill wrote:

Hi Jeroen.

I understand the time pressures you are no doubt under. The revert should hopefully sort it for now.

I guess it will have to be got working somehow before SMW 1.6 goes live though or a lot of people will have broken sites. It is one of the most useful query formats. It's a shame it is such a nasty tangle of javascript!

I would suggest that version of the exhibit js used by SRF 1.5.3 be used. The exhibit trunk is indeed V3 which is a radical departure from V2 and is only in early alpha stage. I doubt it will even produce any output with SRF.

One day soon we'll kick off that re-write we spoke about a while back :)

Cheers
Neill.

Thanks for figuring out the Exhibit version difference; I actually concluded it was pretty much the same when I put in the svn externals, but apparently not.

It is one of the most useful query formats.

To bad no one is maintaining it though; if some dev would step up to do that, it'd be awesome.

One day soon we'll kick off that re-write we spoke about a while back :)

Right; do give me a heads up in advance if possible, so I can make time for it.

mitchell_neill wrote:

To bad no one is maintaining it though; if some dev would step up to do that,

it'd be awesome.

Well, they seem to be writing version 3 :) I wonder if they will sort out the mess or just add to it ;)

I moved the trunk version of the format out of the way in r93461 and put in an older version of the format in r93462. Can you confirm it works now as it did before? I'd like to release SRF 1.6 this weekend :)

mitchell_neill wrote:

Hi Jeroen.

The actual SRF_Exhibit.php file seems to be missing?

Cheers
Neill.

Oh wtf, something went wrong w/ copying the files... Will fix now

I guess I ran svn add before my copy was done. Should be fixed by r93470

mitchell_neill wrote:

Okay, got revision 93470.

Exhibit queries still don't return anything :(

That issue is not related to the changes I made. Looks like a MediaWiki compat issue. Exhibit won't work with MW 1.17 or above, so if you are running that version, forget about getting it to work. My changes attempted to fix the incompat, but need more work.

Yeah, the $wgServer global was removed in MW 1.17. That one's easy to fix, but I bet there are a bunch of other compatibility problems that need to be addressed for MW 1.17, due to the ResourceLoader...

mitchell_neill wrote:

Hi Jeroen.

But isn't it the SRF exhibit wrapper that needs changing? The actual exhibit js is stand alone and is not the bit that is broken no?

Cheers
Neill

Exhbit itself might not be broken, but the wrapper definitely is. For one thing, the loading of the library is not done in such a way that it'll work with MW 1.17 and later.

Need to find someone who wants to maintain this format, and the timeline/eventline one for that matter...

mitchell_neill wrote:

Hi Jeroen.

Originally the one of the most exciting features of SRF was the Simile query formats. So not having them now is bad news as they are out there and being actively used by existing projects and sites. These will all now be stuck at SMW 1.5.6 and SRF 1.5.3 and not be able to leverage the new functionality.

I think you'll have a lot of very upset people if these formats are effectively dropped!

Cheers
Neill.

Sure. That doesn't change the fact that I simply cannot maintain them on top of all the other stuff I'm already maintaining, hence my note that a maintainer needs to be found.

mitchell_neill wrote:

I completely understand, but it seems kinda pointless releasing a new version of SRF with half the query types broken. The MW extension page needs to at least say that timeline, eventline and exhibit are not working with version 1.6 to avoid a lot of posts and questions.

Perhaps drop a note on the mailing list to see if we can find someone to patch up the wrappers?

Cheers
Neill.

Timeline and eventline are working. Also, this release contains many fixes and new features the old one does not have. And compatibility with SMW 1.6... Doesn't seem pointless to me.

mitchell_neill wrote:

Oh, timelines and event lines weren't working for me on Friday. I'll try again :)

This should have been fixed. If this is not the case, and it's still broken on trunk, please re-open or create a new bug report.

mitchell_neill wrote:

Great. Thanks for that. I will test it Jeroen.

:)

mitchell_neill wrote:

Just tried r103819 and it still doesn't work. Same as before - nothing gets returned :(

That's incompatibility with MediwWiki 1.17 and later... Should be not to hard to load the compatibility modules, if they still exist on trunk that is :)

Will have a look at this soonish.

mitchell_neill wrote:

Hi. Just tried it. Still not working I'm afraid. Errors are:

"NetworkError: 404 Not Found - http://localhost/iow/common/wikibits.js"
wikibits.js
wgBreakFrames is not defined
[Break On This Error] if ( wgBreakFrames ) {
wikibits.js?301 (line 124)

"NetworkError: 404 Not Found - http://localhost/iow/common/wikibits.js"
wikibits.js

wgServer is not defined
[Break On This Error] wgServer + wgScriptPath + ...ax/simile-ajax-api.js?bundle=false" :
exhibi...e=false (line 254)

onloadFuncts is undefined
error source line: [Break On This Error] message);}else{messageDiv.innerHTML=me...r);}}function addClickHandler(element

Cheers
Neill.

Ok - then it does not work with 1.17. Need to find someone who wants to maintain the Exhibit format...

mitchell_neill wrote:

HI.

This all looks MW side? Do you know why is the interface so different to the other Simile formats that work?

Cheers
Neill.

mitchell_neill wrote:

Superseded by the new Filtered format.