SYSTEM NOTICE, Error Description

Post about your customizations to share with others.

Moderators: Developer, Contributor

somethingwrong
Posts: 2
Joined: 29 Apr 2013, 14:59

SYSTEM NOTICE, Error Description

Post by somethingwrong »

Hello,

We use mantisconnect.php?wsdl to consume the service to post a bug.
mc_issue_add works fine..however, right after adding, server generates this error..

<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body><SOAP-ENV:Fault><faultcode xsi:type="xsd:string">Server</faultcode><faultactor xsi:type="xsd:string"></faultactor><faultstring xsi:type="xsd:string">Error Type: SYSTEM NOTICE,
Error Description: Undefined offset: 5</faultstring><detail xsi:type="xsd:string"></detail></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>

Not sure what this causes this issue..
We use customization fields (we have 4 customization fields)....it looks like somehow these customization fields are causing some issue..however, not sure why and how can be fixed..

Anybody have idea to share?

Thanks,
rombert
Posts: 66
Joined: 05 Nov 2009, 08:43

Re: SYSTEM NOTICE, Error Description

Post by rombert »

What version of Mantis do you use? Can you post the XML request?
somethingwrong
Posts: 2
Joined: 29 Apr 2013, 14:59

Re: SYSTEM NOTICE, Error Description

Post by somethingwrong »

Hello,
...
<q2:IssueData id="id1" xsi:type="q2:IssueData" xmlns:q2="http://futureware.biz/mantisconnect">
....
....
<custom_fields href="#id4"/>
</q2:IssueData>
.....
<q5:Array id="id4" q5:arrayType="q6:CustomFieldValueForIssueData[1]" xmlns:q5="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:q6="http://futureware.biz/mantisconnect">
<Item href="#id5" />
</q5:Array>
<q6:CustomFieldValueForIssueData id="id5" xsi:type="q6:CustomFieldValueForIssueData"
xmlns:q6="http://futureware.biz/mantisconnect">
<field href="#id6"/><value xsi:type="xsd:string">Test</value>
</q6:CustomFieldValueForIssueData>
<q8:ObjectRef id="id6" xsi:type="q8:ObjectRef" xmlns:q8="http://futureware.biz/mantisconnect">
<id xsi:type="xsd:integer">6</id><name xsi:type="xsd:string">MyCustomField1</name>
</q8:ObjectRef>
....
....

It looks to me OK....
I believe the version is the latest one.
rombert
Posts: 66
Joined: 05 Nov 2009, 08:43

Re: SYSTEM NOTICE, Error Description

Post by rombert »

Can you please post the full request, with sensitive data eliminated?

How do you generate this XML?
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

Hi
i get this message too.

Code: Select all

Error Type: SYSTEM NOTICE,

Error Description: Undefined offset: 5
i do connect from .net program using MantisConnectPortTypeClient.

MantisBT Version 1.2.19
Schema Version 183

how to debug this ?

my code:

Code: Select all

using ConsoleApplication1.ServiceReference2;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;


namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {


            MantisConnectPortTypeClient cc = new MantisConnectPortTypeClient(  );
            
            IssueData idata = cc.mc_issue_get("administrator", "root", "11");
            idata.notes=new IssueNoteData[1];
            
            idata.custom_fields[0].value = "test2";
            idata.notes[0] = new IssueNoteData() { text="wer2" , id="11" };
        
            cc.mc_issue_update("administrator", "root", "11", idata);
        }

    }
}
issue 11 are exists.
i can open.
when i reach

Code: Select all

cc.mc_issue_update("administrator", "root", "11", idata);
i get error message.

if i reload issue in browser i see that note were added, custom field not.
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

when i unlink custom field from project and rem idata.custom_fields[0].value = "test2";
my code starts work fine.

so
the error is about custom fields operations.
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

i have debug info from php.

Code: Select all

[12-Jan-2016 09:23:28 Asia/Kuwait] PHP Deprecated:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in Unknown on line 0
[12-Jan-2016 09:23:31 Asia/Kuwait] PHP Deprecated:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in Unknown on line 0
[12-Jan-2016 09:23:31 Asia/Kuwait] [mantisconnect.php] Error Type: SYSTEM NOTICE,
Error Description: Undefined offset: 5
Stack Trace:
adodb.inc.php L1357 FetchField(<integer>5)
adodb.inc.php L1061 _rs2rs(<Object><ADORecordset_mssqlnative> ( [databaseType] => 'mssqlnative', [canSeek] => false, [fieldOffset] => 5, [dataProvider] => 'native', [fields] => <Array> { ['name'] => 'ExternalEmail', ['type'] => 0, ['access_level_r'] => 10, ['default_value'] => 'defaultvalue', ['value'] => 'test2' }, [blobSize] => 100, [sql] => '
			SELECT f.name, f.type, f.access_level_r, f.default_value, f.type, s.value
			FROM mantis_custom_field_project_table p
				INNER JOIN mantis_custom_field_table f ON f.id = p.field_id
				LEFT JOIN mantis_custom_field_string_table s
					ON s.field_id = p.field_id AND s.bug_id = ?
			WHERE p.project_id = ?
			ORDER BY p.sequence ASC, f.name ASC', [EOF] => false, [emptyTimeStamp] => '&nbsp;', [emptyDate] => '&nbsp;', [debug] => false, [timeCreated] => 0, [bind] => false, [fetchMode] => 2, [connection] => <Object><ADODB_mssqlnative> ( [databaseType] => 'mssqlnative', [dataProvider] => 'mssqlnative', [replaceQuote] => '\'\'', [fmtDate] => '\'Y-m-d\'', [fmtTimeStamp] => '\'Y-m-d H:i:s\'', [hasInsertID] => true, [substr] => 'substring', [length] => 'len', [hasAffectedRows] => true, [poorAffectedRows] => false, [metaDatabasesSQL] => 'select name from sys.sysdatabases where name <> \'master\'', [metaTablesSQL] => 'select name,case when type=\'U\' then \'T\' else \'V\' end from sysobjects where (type=\'U\' or type=\'V\') and (name not in (\'sysallocations\',\'syscolumns\',\'syscomments\',\'sysdepends\',\'sysfilegroups\',\'sysfiles\',\'sysfiles1\',\'sysforeignkeys\',\'sysfulltextcatalogs\',\'sysindexes\',\'sysindexkeys\',\'sysmembers\',\'sysobjects\',\'syspermissions\',\'sysprotects\',\'sysreferences\',\'systypes\',\'sysusers\',\'sysalternates\',\'sysconstraints\',\'syssegments\',\'REFERENTIAL_CONSTRAINTS\',\'CHECK_CONSTRAINTS\',\'CONSTRAINT_TABLE_USAGE\',\'CONSTRAINT_COLUMN_USAGE\',\'VIEWS\',\'VIEW_TABLE_USAGE\',\'VIEW_COLUMN_USAGE\',\'SCHEMATA\',\'TABLES\',\'TABLE_CONSTRAINTS\',\'TABLE_PRIVILEGES\',\'COLUMNS\',\'COLUMN_DOMAIN_USAGE\',\'COLUMN_PRIVILEGES\',\'DOMAINS\',\'DOMAIN_CONSTRAINTS\',\'KEY_COLUMN_USAGE\',\'dtproperties\'))', [metaColumnsSQL] => 'select c.name,t.name,c.length,
	    (case when c.xusertype=61 then 0 else c.xprec end),
	    (case when c.xusertype=61 then 0 else c.xscale end) 
	    from syscolumns c join systypes t on t.xusertype=c.xusertype join sysobjects o on o.id=c.id where o.name=\'%s\'', [hasTop] => 'top', [hasGenID] => true, [sysDate] => 'convert(datetime,convert(char,GetDate(),102),102)', [sysTimeStamp] => 'GetDate()', [maxParameterLen] => 4000, [arrayClass] => 'ADORecordSet_array_mssqlnative', [uniqueSort] => true, [leftOuter] => '*=', [rightOuter] => '=*', [ansiOuter] => true, [identitySQL] => 'select SCOPE_IDENTITY()', [uniqueOrderBy] => true, [_bindInputArray] => true, [_dropSeqSQL] => 'drop table %s', [database] => 'mantis', [host] => '(local)\\old', [user] => 'mantisdb', [password] => '123', [debug] => false, [maxblobsize] => 262144, [concat_operator] => '+', [random] => 'rand()', [upperCase] => 'upper', [true] => '1', [false] => '0', [nameQuote] => '"', [charSet] => false, [emptyDate] => '&nbsp;', [emptyTimeStamp] => '&nbsp;', [lastInsID] => false, [hasLimit] => false, [readOnly] => false, [hasMoveFirst] => false, [hasTransactions] => true, [genID] => 0, [raiseErrorFn] => false, [isoDates] => false, [cacheSecs] => 3600, [memCache] => false, [memCacheHost] => NULL, [memCachePort] => 11211, [memCacheCompress] => false, [sysUTimeStamp] => false, [noNullStrings] => false, [numCacheHits] => 0, [numCacheMisses] => 0, [pageExecuteCountRows] => true, [autoRollback] => false, [fnExecute] => false, [fnCacheExecute] => false, [blobEncodeType] => false, [rsPrefix] => 'ADORecordSet_', [autoCommit] => true, [transOff] => 0, [transCnt] => 0, [fetchMode] => false, [null2null] => 'null', [_oldRaiseFn] => false, [_transOK] => NULL, [_connectionID] => NULL, [_errorMsg] => false, [_errorCode] => false, [_queryID] => NULL, [_isPersistentConnection] => false, [_evalAll] => false, [_affected] => false, [_logsql] => false, [_transmode] => '' ), [_numOfRows] => -1, [_numOfFields] => 6, [_queryID] => NULL, [_currentRow] => 0, [_closed] => false, [_inited] => true, [_obj] => NULL, [_names] => NULL, [_currentPage] => -1, [_atFirstPage] => false, [_atLastPage] => false, [_lastPageNo] => -1, [_maxRecordCount] => 0, [datetime] => false ), <integer>-1, <integer>-1, <boolean>true)
adodb.inc.php L1008 _Execute(<string>'
			SELECT f.name, f.type, f.access_level_r, f.default_value, f.type, s.value
			FROM mantis_custom_field_project_table p
				INNER JOIN mantis_custom_field_table f ON f.id = p.field_id
				LEFT JOIN mantis_custom_field_string_table s
					ON s.field_id = p.field_id AND s.bug_id = ?
			WHERE p.project_id = ?
			ORDER BY p.sequence ASC, f.name ASC', <Array> { [0] => 11, [1] => 1 })
database_api.php L347 Execute(<string>'
			SELECT f.name, f.type, f.access_level_r, f.default_value, f.type, s.value
			FROM mantis_custom_field_project_table p
				INNER JOIN mantis_custom_field_table f ON f.id = p.field_id
				LEFT JOIN mantis_custom_field_string_table s
					ON s.field_id = p.field_id AND s.bug_id = ?
			WHERE p.project_id = ?
			ORDER BY p.sequence ASC, f.name ASC', <Array> { [0] => 11, [1] => 1 })
custom_field_api.php L965 db_query_bound(<string>'
			SELECT f.name, f.type, f.access_level_r, f.default_value, f.type, s.value
			FROM mantis_custom_field_project_table p
				INNER JOIN mantis_custom_field_table f ON f.id = p.field_id
				LEFT JOIN mantis_custom_field_string_table s
					ON s.field_id = p.field_id AND s.bug_id = ?
			WHERE p.project_id = ?
			ORDER BY p.sequence ASC, f.name ASC', <Array> { [0] => 11, [1] => 1 })
custom_field_api.php L919 custom_field_get_all_linked_fields(<integer>11)
email_api.php L1502 custom_field_get_linked_fields(<integer>11, <integer>25)
email_api.php L592 email_build_visible_bug_data(<integer>10, <integer>11, <string>'email_notification_title_for_action_bug_updated')
email_api.php L559 email_generic_to_recipients(<integer>11, <string>'updated', <Array> { [10] => 'akozlov@ru' }, <string>'email_notification_title_for_action_bug_updated', <NULL>NULL, <Array> {  })
bug_api.php L548 email_generic(<integer>11, <string>'updated', <string>'email_notification_title_for_action_bug_updated')
mc_issue_api.php L1025 update(<boolean>true, <boolean>false)
UnknownFile L? mc_issue_update(<string>'administrator', <string>'root', <integer>11, <Object><stdClass> ( [id] => 11, [view_state] => <Object><stdClass> ( [id] => 10, [name] => 'public' ), [last_updated] => '2016-01-12T09:22:02+03:00', [project] => <Object><stdClass> ( [id] => 1, [name] => 'Проект1' ), [category] => 'General', [priority] => <Object><stdClass> ( [id] => 30, [name] => 'normal' ), [severity] => <Object><stdClass> ( [id] => 50, [name] => 'minor' ), [status] => <Object><stdClass> ( [id] => 50, [name] => 'assigned' ), [reporter] => <Object><stdClass> ( [id] => 10, [name] => 'akozlov__ru_98237', [real_name] => 'Козлов Алексей Александрович', [email] => 'akozlov@ru' ), [summary] => 'issue04', [reproducibility] => <Object><stdClass> ( [id] => 70, [name] => 'have not tried' ), [date_submitted] => '2015-09-03T14:02:43+03:00', [sponsorship_total] => 0, [handler] => <Object><stdClass> ( [id] => 1, [name] => 'administrator', [email] => 'root@localhost' ), [projection] => <Object><stdClass> ( [id] => 10, [name] => 'none' ), [eta] => <Object><stdClass> ( [id] => 10, [name] => 'none' ), [resolution] => <Object><stdClass> ( [id] => 10, [name] => 'open' ), [description] => 'Email from: Козлов Алексей Александрович <akozlov@ru>

issue04bo3dy', [attachments] => <Array> {  }, [notes] => <Array> { [0] => <Object><stdClass> ( [text] => 'wer22' ) }, [custom_fields] => <Array> { [0] => <Object><stdClass> ( [field] => <Object><stdClass> ( [id] => 1, [name] => 'ExternalEmail' ), [value] => 'test2' ) }, [due_date] => '0001-01-01T00:00:00', [monitors] => <Array> {  }, [sticky] => false, [tags] => <Array> {  } ))
mantisconnect.php L123 handle()


can you help me with logs.
i setup logs through php cgi in IIS.
when error happens info writes to this log.
my settings in config_inc.php:

Code: Select all

$g_log_level 	 = LOG_DATABASE;
$g_log_destination = 'file:c:/inetpub/wwwroot/mantis/mantisbt.log';
doesnt works. mantisbt.log always empty.
why?
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: SYSTEM NOTICE, Error Description

Post by atrol »

AlexeiK, which PHP version do you use?
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

php version 5.6.12
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: SYSTEM NOTICE, Error Description

Post by atrol »

Just noticed that you are using MSSQL

MantisBT currently supports MySQL and has support for other database engines.
The support for other databases is known to be problematic.
MSSQL support is currently known broken in version 1.2.x, I recommend to use MySQL.

To get rid of deprecated warning, just do what the warning says.

Code: Select all

To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini
This will not affect Mantis as we don't access $HTTP_RAW_POST_DATA.
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

this error happens because of that

Code: Select all

To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini
?


im interested in

Code: Select all

Error Type: SYSTEM NOTICE,

Error Description: Undefined offset: 5
is it the same thing?

i can present method to setup mantisbt 1.2 on MSSQL 2008
there is a small hit:
when we installing mantisBT we must use $g_db_type = 'odbc_mssql'
when we using mantisBT we must switch to $g_db_type ='mssqlnative'
the same thing with $g_hostname = 'Driver={SQL Server};SERVER=(local)\old;DATABASE=mantis;UID=mantisdb;PWD=123;'; (for ODBC)
$g_hostname ='(local)\old';(for MSSQL)

this hint let us work with mantis from browser.

but i get errors when work with mantis thourgh SOAP API.


and i cant understand how to debug.
im not a php programmer and i dont know error handling in php.
please advice .
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: SYSTEM NOTICE, Error Description

Post by atrol »

AlexeiK, I can just repeat what I wrote:

MSSQL support is currently known broken in version 1.2.x, I recommend to use MySQL.
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

ok.
does 1.3 version works well with MSSQL ?
i cant just switch to MySQL.
mantis is online and has many data.
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: SYSTEM NOTICE, Error Description

Post by atrol »

Version 1.3 is no ready yet, but there is a release candidate available.
This version should be better in terms of MSSQL compatibility, as some MSSQL changes have been included in Mantis and the underlying database abstraction layer (ADODB)
I can't tell more as I don't use MSSQL.

You could make a copy of your database and try to use the release candidate or a nightly build.
Enter bug reports at https://www.mantisbt.org/bugs if you encounter problems.
Please use Search before posting and read the Manual
AlexeiK
Posts: 31
Joined: 11 Jan 2016, 10:29

Re: SYSTEM NOTICE, Error Description

Post by AlexeiK »

version 1.3 cant understand odbc_mssql and that is why it cant be installed.

Code: Select all

Fatal error: 401 in C:\inetpub\wwwroot\mantis1.3\core\database_api.php on line 405
always get this error

my config_inc.php

Code: Select all

$g_hostname ='(local)\old';
$g_db_username   = 'mantisdb';
$g_db_password   = '123';
$g_database_name = 'mantis2new';
$g_db_type ='mssqlnative';
Post Reply