Community
Participate
Working Groups
The following error is printed to the console when launching a SWT.Mozilla style Browser with XULRunner 31. addons.manager ERROR startup failed: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIPrefBranch.setCharPref]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: resource://gre/modules/AddonManager.jsm :: AMI_startup :: line 645" data: no] Stack trace: AMI_startup()@resource://gre/modules/AddonManager.jsm:645 < AMP_startup()@resource://gre/modules/AddonManager.jsm:2318 < AMC_observe()@resource://gre/components/addonManager.js:55 < <file:unknown>
Hi Matt, Do you know why this error occurs? I've investigated this for a while. From the call trace in the error message, the error occurs at resource://gre/modules/AddonManager.jsm:645 which is Services.prefs.setCharPref(PREF_EM_LAST_APP_VERSION, Services.appinfo.version); I'm not sure what is the problem, as this doesn't occur in older versions.
(In reply to Lakshmi Shanmugam from comment #1) > Hi Matt, > Do you know why this error occurs? > I've investigated this for a while. From the call trace in the error > message, the error occurs at resource://gre/modules/AddonManager.jsm:645 > which is Services.prefs.setCharPref(PREF_EM_LAST_APP_VERSION, > Services.appinfo.version); > I'm not sure what is the problem, as this doesn't occur in older versions. Is Services.appinfo.version undefined? From the error it looks like it's either undefined or the wrong type. This bug would seem to concur: https://bugzilla.mozilla.org/show_bug.cgi?id=820818
(In reply to Matt Painter from comment #2) > (In reply to Lakshmi Shanmugam from comment #1) > > Hi Matt, > > Do you know why this error occurs? > > I've investigated this for a while. From the call trace in the error > > message, the error occurs at resource://gre/modules/AddonManager.jsm:645 > > which is Services.prefs.setCharPref(PREF_EM_LAST_APP_VERSION, > > Services.appinfo.version); > > I'm not sure what is the problem, as this doesn't occur in older versions. > > Is Services.appinfo.version undefined? From the error it looks like it's > either undefined or the wrong type. > > This bug would seem to concur: > https://bugzilla.mozilla.org/show_bug.cgi?id=820818 I don't think SWT sets the appinfo.version anywhere. It should be set in the application.ini, right? That's not used in SWT XULRunner support. Any other insights would be useful.
We are following the progress of XULRunner 31 support with much interest, since it would give us huge JavaScript-Performance improvements. Can you give an estimate, when this bug will be fixed?
(In reply to Josef Schachinger from comment #4) > We are following the progress of XULRunner 31 support with much interest, > since it would give us huge JavaScript-Performance improvements. > > Can you give an estimate, when this bug will be fixed? I'm still investigating how to get rid of this error. See earlier comments for details. Any insights on how to fix this would be helpful. Does it affect any feature or functionality for you? In my investigation/tests it is only a error printed to the console, but doesn't affect any feature of the browser.
(In reply to Lakshmi Shanmugam from comment #5) > I'm still investigating how to get rid of this error. See earlier comments > for details. Any insights on how to fix this would be helpful. > > Does it affect any feature or functionality for you? In my > investigation/tests it is only a error printed to the console, but doesn't > affect any feature of the browser. We use http://djproject.sourceforge.net/ns/index.html to integrate a browser in our Java-Swing-UI-based application. Now we would like to use XULRunner 31, but it only displays a gray screen. During analysis we noticed the error and found this bug. Since in your case it does not affect browser functionality, we are not sure whether this bug really is the cause of our problem - we have to investigate this further.
On which platform did you test? We have an issue with XULRunner 31 support on Linux (Bug 467646). It works fine on Windows and MacOSX.
(In reply to Lakshmi Shanmugam from comment #7) > On which platform did you test? We have an issue with XULRunner 31 support > on Linux (Bug 467646). It works fine on Windows and MacOSX. Our platform is Windows 7.
We are also using Windows 7 32 bit and XULRunner 31 does not work on an RCP application that worked fine with 21. This is the error printed. 1430748349755 addons.manager ERROR startup failed: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIPrefBranch.setCharPref]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: resource://gre/modules/AddonManager.jsm :: AMI_startup :: line 645" data: no] Stack trace: AMI_startup()@resource://gre/modules/AddonManager.jsm:645 < AMP_startup()@resource://gre/modules/AddonManager.jsm:2318 < AMC_observe()@resource://gre/components/addonManager.js:55 < <file:unknown> Then, the browser window is empty. Using XULRunner 31 is very important for us as the font rendering is much improved compared to version 21. Thanks.
(In reply to Daniel Stainhauser from comment #9) > We are also using Windows 7 32 bit and XULRunner 31 does not work on an RCP > application that worked fine with 21. > > This is the error printed. > > 1430748349755 addons.manager ERROR startup failed: [Exception... "Component > returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) > [nsIPrefBranch.setCharPref]" nsresult: "0x80070057 > (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: > resource://gre/modules/AddonManager.jsm :: AMI_startup :: line 645" data: > no] Stack trace: AMI_startup()@resource://gre/modules/AddonManager.jsm:645 < > AMP_startup()@resource://gre/modules/AddonManager.jsm:2318 < > AMC_observe()@resource://gre/components/addonManager.js:55 < <file:unknown> > > Then, the browser window is empty. > > Using XULRunner 31 is very important for us as the font rendering is much > improved compared to version 21. > > Thanks. XULRunner 31 works fine on Windows in-spite of the error message. Have you set the org.eclipse.swt.browser.XULRunnerPath to point to the XULRunner 31 runtime? Can you try any of the browser snippets from here with XULRunner 31 and see if it works for you? --> https://www.eclipse.org/swt/snippets/#browser You need to change the Browser style to SWT.MOZILLA and set the XULRunnerPath property for the snippets to use XULRunner 31.
I also tried setting the internal browser in eclipse to use XULRunner 31 runtime. The browser opens and works fine. I've tested this on both Windows 7 and Mac OSX. Can you try if this works for you? (I added the following lines to the end of eclipse.ini and started eclipse. -Dorg.eclipse.swt.browser.DefaultType=mozilla -Dorg.eclipse.swt.browser.XULRunnerPath=/Library/Frameworks/XUL/31/XUL.framework/Versions/Current )
When I setting this properties, I can run the snippets with style SWT.MOZILLA. It seems the XULRunner 31 and SWT integration works. Thanks for the hint! But we are also using the FlashPlayer and I only get a black screen. So is there any example (snippet) where I can test this scenario? Or has anybody a idea if we need another version of flashplayer plugin in xulrunner. For info we are adding a plugin folder to xulrunner with following files: flashplayer.xpt npnul32.dll NPSWF32.dll
I've finally managed to solve our problem. We had a directive in our html pages <meta http-equiv='Content-Type' content='application/xhtml+xml' /> That caused a very weird behaviour. When we added more than 4 includes with javascript into the head, the webpage was blank. It didn't even matter if the included javascript had any content. Finally with trial and error we found out that this directive solved the problem. <meta http-equiv='Content-Type' content='application/xhtml+xml charset=UTF-8' /> The first directive is working fine with XULRunner21 /eclipse Luna, also with Android, Safari and iOS. So if anybody has a similar problem with blank web pages, try to define a charset.
Moving to 4.6
XULRunner has been deprecated and removed from the source tree, see https://groups.google.com/d/msg/mozilla.dev.platform/_rFMunG2Bgw/C-4PcHj9IgAJ Closing this request since makes little sense to invest in a dead technology.