[Greasemonkey] New patched greasemonkey for Firefox 1.5 beta 2

Gareth Andrew freega at freegarethandrew.org
Sat Oct 15 03:18:39 EDT 2005


Hi Matthew,

I doubt the file not found, is coming from the user script you are
trying to install.  The other possibilities are it can't find the
gm_scripts directory, the config.xml file, or a previous user script its
trying to remove.  To narrow it down further, the following questions
spring to mind:
Did you have any other version of greasemonkey installed before you
installed 0.6.2.1? Do you have a gm_scripts directory in your firefox
profile directory and is there a config.xml in that directory?  Do the
files referenced in config.xml exist?  Any other information you think
might be helpful?

Gareth.

On Fri, 2005-10-14 at 20:39 -0400, Matthew Weymar wrote:
> On 10/13/05, Jeremy Dunck <jdunck at gmail.com> wrote:
> >
> > On 10/13/05, Matthew Weymar <matthew.weymar at gmail.com> wrote:
> > >
> > > When I try to install a user script, I get the following "Alert:"
> > >
> > > Error installing user script:
> > >
> > > [Exception... "Component returned failure code: 0x80520012
> > > (NS_ERROR_FILE_NOT_FOUND) [nsIChannel.open]" nsresult: "0x80520012
> > > (NS_ERROR_FILE_NOT_FOUND)" location: "JS frame ::
> > > chrome://greasemonkey/content/utils.js :: getContents :: line 196" data:
> > no]
> > >
> > > Any suggestions?...
> >
> > This sounds like Taral's reported issue. He suggested switching to
> > nsIURI, but didn't supply a patch. I'll try to fix this today.
> 
> 
> FYI - I applied Taral's patch - albeit by hand, very carefully - but still
> receive the same error when trying to install a user script.
> 
> Any other suggestions?...
> 
> Taral's patch does the following to utils.js:
> diff -ruN gm/chrome/greasemonkey/content/utils.js gm.new
> /chrome/greasemonkey/content/utils.js
> --- gm/chrome/greasemonkey/content/utils.js Thu Oct 13 11:41:08 2005
> +++ gm.new/chrome/greasemonkey/content/utils.js Thu Oct 13 11:38:34 2005
> @@ -177,7 +177,7 @@
> return file;
> }
> 
> -function getContents(aURL, charset){
> +function getContents(aURI, charset){
> if( !charset ) {
> charset = "UTF-8"
> }
> @@ -192,7 +192,7 @@
> .createInstance(Components.interfaces.nsIScriptableUnicodeConverter);
> unicodeConverter.charset = charset;
> 
> - var channel=ioService.newChannel(aURL,null,null);
> + var channel=ioService.newChannelFromURI(aURI);
> var input=channel.open();
> scriptableStream.init(input);
> var str=scriptableStream.read(input.available());
> 
> This is line 196:
> var input=channel.open();
> 
> With apologies for my inability to figure this out on my own: Does this mean
> var channel=ioService.newChannelFromURI(aURI);
> isn't quite working as intended - still, post-patch?...
> 
> Tks,
> Matthew
> 
> FYI, I'm putting together a release with all the patches.
> >
> > Included items:
> >
> > taral
> > getContents dies on Beta2 (no patch)
> >
> > Ori
> > remove prefs on script uninstall
> > needs tweak to ask whether user wants to remove values (possible
> > re-install)
> > Gareth
> > loggify wrapper tweak
> > GM_import - if testing goes well
> >
> > This will almost double the GM contributor's list. :)
> >
> _______________________________________________
> Greasemonkey mailing list
> Greasemonkey at mozdev.org
> http://mozdev.org/mailman/listinfo/greasemonkey



More information about the Greasemonkey mailing list