Skip to main content



      Home
Home » Eclipse Projects » Mylyn » CoreException from BugzillaClient#parseHtmlError
CoreException from BugzillaClient#parseHtmlError [message #65445] Sun, 15 February 2009 17:42 Go to next message
Eclipse UserFriend
Hi

I want to add an attachment to an existing Bug with
BugzillaClient#postAttachment. It works but I get a CoreException from
#parseHtmlError.

org.eclipse.core.runtime.CoreException: A repository error has occurred.
at
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaClient.java:1351)
at
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaClient.java:1260)
at
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.post Attachment(BugzillaClient.java:700)


Seems #parseHtmlError expects to find a String within the returned HTML page
title (like "changes submitted") - instead the returned title is "attachment 6
added to bug 1".

I'm using Bugzilla 3.2.2

Is it a compatibility issue? Should I simply ignore those CoreExceptions?

Regards
Alex
Re: CoreException from BugzillaClient#parseHtmlError [message #65698 is a reply to message #65445] Thu, 19 February 2009 14:53 Go to previous messageGo to next message
Eclipse UserFriend
Alexander Karnstedt <alex.karnstedt@gmx.de> wrote:

> Hi
>
> I want to add an attachment to an existing Bug with
> BugzillaClient#postAttachment. It works but I get a CoreException from
> #parseHtmlError.
>
> org.eclipse.core.runtime.CoreException: A repository error has occurred.
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaC
lient.java:1351)
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaC
lient.java:1260)
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.post Attachment(BugzillaC
lient.java:700)
>
>
> Seems #parseHtmlError expects to find a String within the returned HTML page
> title (like "changes submitted") - instead the returned title is "attachment 6
> added to bug 1".
>
> I'm using Bugzilla 3.2.2
>
> Is it a compatibility issue? Should I simply ignore those CoreExceptions?
>
> Regards
> Alex
>

Hi Alex,

what version of Mylyn did you use?
and what languagesettings are in your bugzilla version?

BugzillaRepositoryConector has support for language en with the following lines:
enSetting.addLanguageAttribute("changes_submitted", "Changes
submitted"); //$NON-NLS-1$ //$NON-NLS-2$
enSetting.addLanguageAttribute("changes_submitted", "added to
Bug"); //$NON-NLS-1$ //$NON-NLS-2$

In my enviroment with Mylyn weekly build and Bugzilla 3.2.2 [en] I can an an
attachment without error.

Regards

Frank
Re: CoreException from BugzillaClient#parseHtmlError [message #66253 is a reply to message #65698] Sun, 08 March 2009 17:48 Go to previous message
Eclipse UserFriend
Frank Becker schrieb am 19.02.2009 20:53:

> what version of Mylyn did you use?
> and what languagesettings are in your bugzilla version?
>
> BugzillaRepositoryConector has support for language en with the following lines:
> enSetting.addLanguageAttribute("changes_submitted", "Changes
> submitted"); //$NON-NLS-1$ //$NON-NLS-2$
> enSetting.addLanguageAttribute("changes_submitted", "added to
> Bug"); //$NON-NLS-1$ //$NON-NLS-2$
>
>

Yep, that was the problem: in my Mylyn-Build (3.0.4) there is no such language
attribute ("added to Bug"). I was able to fix that simply by adding the missing
language attribute to the BugzillaRepositoryConnector.

BugzillaLanguageSettings enSetting =
connector.getLanguageSetting(IBugzillaConstants.DEFAULT_LANG );
enSetting.addLanguageAttribute("changes_submitted", "added to Bug");

Thanks
Alex
Re: CoreException from BugzillaClient#parseHtmlError [message #596374 is a reply to message #65445] Thu, 19 February 2009 14:53 Go to previous message
Eclipse UserFriend
Alexander Karnstedt <alex.karnstedt@gmx.de> wrote:

> Hi
>
> I want to add an attachment to an existing Bug with
> BugzillaClient#postAttachment. It works but I get a CoreException from
> #parseHtmlError.
>
> org.eclipse.core.runtime.CoreException: A repository error has occurred.
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaC
lient.java:1351)
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.pars eHtmlError(BugzillaC
lient.java:1260)
> at
>
org.eclipse.mylyn.internal.bugzilla.core.BugzillaClient.post Attachment(BugzillaC
lient.java:700)
>
>
> Seems #parseHtmlError expects to find a String within the returned HTML page
> title (like "changes submitted") - instead the returned title is "attachment 6
> added to bug 1".
>
> I'm using Bugzilla 3.2.2
>
> Is it a compatibility issue? Should I simply ignore those CoreExceptions?
>
> Regards
> Alex
>

Hi Alex,

what version of Mylyn did you use?
and what languagesettings are in your bugzilla version?

BugzillaRepositoryConector has support for language en with the following lines:
enSetting.addLanguageAttribute("changes_submitted", "Changes
submitted"); //$NON-NLS-1$ //$NON-NLS-2$
enSetting.addLanguageAttribute("changes_submitted", "added to
Bug"); //$NON-NLS-1$ //$NON-NLS-2$

In my enviroment with Mylyn weekly build and Bugzilla 3.2.2 [en] I can an an
attachment without error.

Regards

Frank
Re: CoreException from BugzillaClient#parseHtmlError [message #596592 is a reply to message #65698] Sun, 08 March 2009 17:48 Go to previous message
Eclipse UserFriend
Frank Becker schrieb am 19.02.2009 20:53:

> what version of Mylyn did you use?
> and what languagesettings are in your bugzilla version?
>
> BugzillaRepositoryConector has support for language en with the following lines:
> enSetting.addLanguageAttribute("changes_submitted", "Changes
> submitted"); //$NON-NLS-1$ //$NON-NLS-2$
> enSetting.addLanguageAttribute("changes_submitted", "added to
> Bug"); //$NON-NLS-1$ //$NON-NLS-2$
>
>

Yep, that was the problem: in my Mylyn-Build (3.0.4) there is no such language
attribute ("added to Bug"). I was able to fix that simply by adding the missing
language attribute to the BugzillaRepositoryConnector.

BugzillaLanguageSettings enSetting =
connector.getLanguageSetting(IBugzillaConstants.DEFAULT_LANG );
enSetting.addLanguageAttribute("changes_submitted", "added to Bug");

Thanks
Alex
Previous Topic:"Bugzilla – Suspicious Action" error encountered after Bugzilla 3.2.2 upgrade
Next Topic:parseHtmlError when I call postTaskData() on Bugzilla Connector
Goto Forum:
  


Current Time: Thu May 29 11:59:10 EDT 2025

Powered by FUDForum. Page generated in 0.03723 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top