View Issue Details

IDProjectCategoryView StatusLast Update
0011563mantisbtplug-inspublic2013-04-29 08:16
Reporteragarcia Assigned Todhx  
PrioritynormalSeveritycrashReproducibilitysometimes
Status closedResolutionfixed 
Product Version1.2.0 
Target Version1.2.4Fixed in Version1.2.4 
Summary0011563: Fatal error importing issues
Description

Importing file, please wait... Done
Processing cross-references for 1 issues...

Fatal error: Call to undefined function bug_update() in /home/WwwRoot/mantisbt-1.2.0/plugins/XmlImportExport/ImportXml.php on line 114

Steps To Reproduce

Try importing this content:

<?xml version="1.0" encoding="UTF-8"?>
<mantis version="1.2.0rc2" urlbase="http://bugs.in.at4.net/" issuelink="#" notelink="~" format="1">
<issue>
<id>50</id>
<project id="26">Test</project>
<reporter id="3">amari</reporter>
<priority id="30">normal</priority>
<severity id="10">funcionalidad</severity>
<reproducibility id="10">siempre</reproducibility>
<status id="10">nueva</status>
<resolution id="10">abierta</resolution>
<projection id="10">ninguna</projection>
<category id="1">General</category>
<date_submitted>1267179575</date_submitted>
<last_updated>1267179575</last_updated>
<eta id="10">ninguno</eta>
<view_state id="10">público</view_state>
<summary>test summary</summary>
<due_date>1</due_date>
<profile_id>5</profile_id>
<description>test description</description>
</issue>
</mantis>

Tagspatch

Activities

wkarl

wkarl

2010-09-16 03:30

reporter   ~0026731

Last edited: 2010-09-17 03:45

I am hit by this bug, too. In fact, the file <mantis_root>/plugins/XmlImportExport/ImportXml.php has a call on line 114 to:

bug_update( $newId, $bugData, true, true );

The function bug_update() used to exist in core/bug_api.php in earlier versions of Mantis, but not in V1.2.x.
E. g. I found this function in version 1.0.7.

This is VERY strange, since the XmlImportExport plugin states "MantisBT Core 1.2.0" as dependency. Did the plugin developer test it at all?

wkarl

wkarl

2010-09-16 03:52

reporter   ~0026732

I changed the above mentioned line 114 to:

$bugData->update( true, true );

and it does work (i.e. the error does not occur). I am not sure if this is what the developer intended, though.

dhx

dhx

2010-09-17 21:36

reporter   ~0026752

Thanks Werner, I have committed your patch. This issue was already fixed in 1.3.x so I guess it was an oversight in backporting to the 1.2.x branch.

Related Changesets

MantisBT: master-1.2.x ea7af5eb

2010-09-17 21:24

wkarl

Committer: dhx


Details Diff
Fix 0012246: Incorrect call to bug_update in ImportXml

The XmlImportExport plugin (specifically ImportXml) makes an incorrect
call to the now non-existant bug_update(..) function. This should be
replaced with a call to the update() function on the BugData class.

Signed-off-by: David Hicks <hickseydr@optusnet.com.au>
Affected Issues
0011563
mod - plugins/XmlImportExport/ImportXml.php Diff File