Last modified: 2012-07-31 21:51:50 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T40482, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 38482 - Queries with latest SMW 1.8-alpha and Vector skin cause a weird gap below tabs
Queries with latest SMW 1.8-alpha and Vector skin cause a weird gap below tabs
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
unspecified
All All
: Unprioritized major with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 38616 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-19 02:16 UTC by Yaron Koren
Modified: 2012-07-31 21:51 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Yaron Koren 2012-07-19 02:16:46 UTC
You can see the issue here:

http://scratchpad.referata.com/wiki/SMW_1.8_query_test?useskin=vector

There's just a single query in the page - if you remove it, the gap goes away.

This seems to be due to something that was added in the SMW code sometime in the last few weeks. It happens for various MW versions. I really don't know what's causing it - it doesn't appear to be anything in the HTML, so I'm guessing that it's some sort of strange CSS or JS issue.
Comment 1 Yaron Koren 2012-07-19 02:18:42 UTC
Added kgh to recipients list, since he originally discovered the issue.
Comment 2 Yaron Koren 2012-07-30 13:37:45 UTC
*** Bug 38616 has been marked as a duplicate of this bug. ***
Comment 3 Jeroen De Dauw 2012-07-30 15:48:56 UTC
I can confirm this. And somehow suspect I caused it. I'm not getting any error though, so am not sure where this is coming from.
Comment 4 MWJames 2012-07-30 16:06:40 UTC
When testing with MW 1.20 the same thing happens but after a page refresh the gap is gone, so I'm also a buffed. 

It just a guess but since all the navigation list items are are ul/li items that somewhere the ul/li css is overridden.
Comment 5 MWJames 2012-07-30 16:30:38 UTC
I looked at Special:Ask and within the Html source (looking with chrome inspector, not just the plain source) after the <body class="mediawiki ltr sitedir-ltr ns--1 ns-special mw-special-Ask page-Special_Ask skin-vector action-view vector-animateLayout"> and before the <title> element their is suddenly a whitespace generated  which causes the distraction in different heights.
Comment 6 MWJames 2012-07-30 17:01:51 UTC
Looking into it a bit further, it involves both printers from SMW (such as SMW_QP_List.php) and those delivered by SRF as well as queries executed in Special:Ask and within normal pages.

Since no one has recently worked (to the best of my knowledge) on SMW_QP_List.php and assuming that the symptoms appear in Special:ask and normal page queries, and recently untouched printers show the same symptoms my assumptions would be that something happens after getResultText() either in SMW_QueryProcessor.php or SMW_QueryPrinter.php that causes the added whitespace at the top.

I think we also can eliminate JS/CSS as cause because SMW_QP_List.php does not use any specific CSS elements nor does it load any JavaScript or CSS specific files via the ResourceLoader and still shows the same behaviour as other printers that use JS or CSS.
Comment 7 DaSch 2012-07-30 18:48:43 UTC
On Internet Explorer looking on the HTML-Code is saw that there also where spaces in front of <!DOCTYPE html>
after setting $wgHtml5 = false; it looks like the problem disappeared. Can somebody test and confirm this?
Comment 8 Yaron Koren 2012-07-30 18:57:42 UTC
Yes, indeed - "$wgHtml5 = false;" makes the problem go away! I just added it to Referata, and now even on pages where the gap is still there, hitting shift-refresh makes it disappear.

(I can remove that line again, though, if that would be helpful for testing purposes.)
Comment 9 MWJames 2012-07-30 19:16:07 UTC
I tried $wgHtml5 = false; with MW 1.20 and it won't work.

Yaron just to be curious does the  SMW/SRF version on scratchpad come from a recent git repo or the old SVN repo (both had the label 1.8 alpha) ? (Can't see the svn nor git version on scratchpad)?
Comment 10 Yaron Koren 2012-07-30 19:17:41 UTC
It uses SMW code from Git, from I think 2-3 weeks ago. (I can update if that would help.)

The difference might be that Referata is using MW 1.18, instead of 1.20.
Comment 11 MWJames 2012-07-30 19:20:01 UTC
Better not make an update right now. Do you have the git number to see which possible changes have been committed before that git version, might help pin-pointing changes that appear then ...
Comment 12 Yaron Koren 2012-07-30 19:24:51 UTC
I'm not sure what the git number is, but it looks like the code was last updated July 9.

The whole $wgHtml5 thing shouldn't really matter though... I mean, presumably if the bug is fixed, it will work fine regardless of the setting of that variable.
Comment 13 MWJames 2012-07-30 19:32:35 UTC
Could you do me a favour (don't wont create a patch) and test one minor thing for me in /includes/storage/SMW_QueryResult.php, could you comment out those three lines and revert and any $wgHtml5 settings to its original to see if the change does the trick.

Line 147:

- public function getQuery() {
-               return $this->mQuery;
-       }


I know it's a long shot ...
Comment 14 Yaron Koren 2012-07-30 19:36:13 UTC
Always glad to help - that doesn't seem to work though. I removed the wgHtml5 line too, and now the problem is back.
Comment 15 DaSch 2012-07-30 19:37:42 UTC
The HTML5 think seams to only partly help
Commenting out the lines mentioned above does not change anything
Comment 16 MWJames 2012-07-30 19:42:12 UTC
Well now I'm also at the end with my Latin. Since it was the closest to 9 Jul change that had something to do with queries which means that any change before 9 Jul is causing the trouble, I just don't know which one.

Someone else any ideas?
Comment 17 DaSch 2012-07-30 19:44:31 UTC
I have many pages with queries that can be found here
http://www.wecowi.de/wiki/Kategorie:Liste

I somehow have the impression, that it more often happens when there are more then one dates queried
Comment 18 MWJames 2012-07-30 20:11:39 UTC
OK, here is my last guess.

I saw in the hex editor that SMW_QueryResult.php comes with BOM (Byte order mark) (which shouldn't be but right now it does) in front of the <?php, could you try to delete this because as soon as the BOM is gone, the problem disappears.
Comment 19 DaSch 2012-07-30 20:17:25 UTC
JACKPOT
thanks, that really seams to help
Comment 20 Yaron Koren 2012-07-30 20:27:44 UTC
Nice!
Comment 21 MWJames 2012-07-30 21:33:54 UTC
https://gerrit.wikimedia.org/r/#/c/17007/
Comment 22 Jeroen De Dauw 2012-07-31 21:51:50 UTC
Oh, that was caused by a BOM?! No idea it could have that effect. Thanks for fixing! :)

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links