Last modified: 2013-06-04 14:45:53 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 T44691, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 42691 - [SMW 1.8] Notice: Array to string conversion in ... SMW_SQLStore3_Writers.php on line 383
[SMW 1.8] Notice: Array to string conversion in ... SMW_SQLStore3_Writers.php...
Status: RESOLVED DUPLICATE of bug 44027
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
REL1_18-branch
PC Windows Server 2008
: Unprioritized critical with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 49025 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-12-04 17:32 UTC by d3mon
Modified: 2013-06-04 14:45 UTC (History)
6 users (show)

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


Attachments

Description d3mon 2012-12-04 17:32:39 UTC
I get 

"Notice: Array to string conversion in C:\folder\extensions\SemanticMediaWiki\includes\storage\SQLStore\SMW_SQLStore3_Writers.php on line 383" 

when saving pages (displays at bottom of page), and occasionally also getting 

"Warning: Cannot modify header information - headers already sent by (output started at C:\folder\extensions\SemanticMediaWiki\includes\storage\SQLStore\SMW_SQLStore3_Writers.php:384) in C:\folder\includes\WebResponse.php on line 38"

which breaks the page.
On some pages I also get 

"Warning: json_encode(): recursion detected in C:\inetpub\wikiwhereis.com\live\includes\json\FormatJson.php on line 48"

at the top of the page.

I can't remember if I started the wiki with 1.8b2 or 1.7, but I know I didn't have the error in 1.8b2.  I've tried php SMW_setup.php --delete, and refreshing the data with no use.  I think the error may have to do with Semantic forms arrays being saved onto page templates, but that's just a guess.
Comment 1 d3mon 2012-12-14 14:44:15 UTC
I believe the FormatJson error may have been in SemanticMaps and fixed with 2.0.1.  I will update the bug if I see it again.

Other errors are still there, and still breaking page saves.
Comment 2 Markus Krötzsch 2012-12-14 17:58:02 UTC
Please use different bug reports for different bugs. This makes it much easier to keep track of things.

The first problem is a duplicate of Bug 42321. You may want to disable PHP notices on the site if you are not using it for PHP development. This bug is also related to the PHP version you are using (older versions don't show this notice).

The second problem is a new problem. It might relate to the PHP version, too, but needs investigation.

The third problem is triggered in code that belongs to MediaWiki. It needs to be investigated if the cause is in SMW at all. SMW uses objects with "recursive" dependencies (two-way pointers between a parent object and its children). Maybe this could make such issues visible, but I do not know why/when the object in question (SQLStore3) would need to be serialized in JSON. Maybe it is a bug in some other extension, as you suggest.
Comment 3 d3mon 2012-12-14 19:27:29 UTC
Sorry, first bug submit, and didn't know if they were all related since they all happened with the change to SMW 1.8 final sqlstore3.

I'm currently running Mediawiki 1.20.0, PHP 5.4.0, MySQL 5.1.66-community on a Server 2008r2 IIS box.  If any of that helps.

Not really worried about the array to string error since I'll turn off debugging when the site goes live.  

The formatjson error was also mentioned by someone else in the mailing list in the thread about the new Maps 2.0.1, so I wouldn't doubt it was related to that.  Still haven't seen the error since the update.

The header error on page saves with changes is a show stopper though, since it returns a blank page with errors.  One good thing is that the changes are committed even though the submit page breaks.

Let me know if there is anything I can do to help.
Comment 4 d3mon 2013-01-16 20:45:58 UTC
You can view this error by making a change to the page at http://www.wikiocity.com/Texas/San_Antonio/Post_Offices/Thousand_Oaks_Post_Office .

This is a test page, so feel free to edit it however you wish to test the error.  Hoping this will be fixed in 1.8.1
Comment 5 d3mon 2013-02-11 16:44:34 UTC
Just wanted to update that the errors are still occurring in 1.8.0.2

Notices are no big problem, but the warning below still breaks the page.

Warning: Cannot modify header information - headers already sent by (output started at C:\inetpub\wikiocity.com\live\extensions\SemanticMediaWiki\includes\storage\SQLStore\SMW_SQLStore3_Writers.php:383) in C:\inetpub\wikiocity.com\live\includes\WebResponse.php on line 38

Any news someone can give on this?  Thanks!
Comment 6 Jeroen De Dauw 2013-02-12 05:58:03 UTC
Just turn off the warnings. Put this at the top of your localsettings file:

error_reporting(0);
ini_set("display_errors", 0);

The issue has been fixed on master and will thus be fixed in the 1.9 release.
Comment 7 d3mon 2013-02-12 16:26:29 UTC
(In reply to comment #6)
> Just turn off the warnings. Put this at the top of your localsettings file:
> 
> error_reporting(0);
> ini_set("display_errors", 0);
> 
> The issue has been fixed on master and will thus be fixed in the 1.9 release.

Works for me!  Thanks!
Comment 8 MWJames 2013-06-01 18:10:56 UTC
*** Bug 49025 has been marked as a duplicate of this bug. ***
Comment 9 Mark A. Hershberger 2013-06-04 14:19:21 UTC
It would be good if you could tell us where this has been fixed in master so we can use the fix if we're willing to patch our own system.
Comment 10 Mark A. Hershberger 2013-06-04 14:45:53 UTC
patch on bug #44027 fixed this for me.

*** This bug has been marked as a duplicate of bug 44027 ***

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


Navigation
Links