Register / Log in

Server Costs Aug

Ends in 8 days 0%
It is currently Fri Aug 23, 2019 7:23 pm

All times are UTC - 8 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Chrome bug
PostPosted: Sun Mar 18, 2012 12:55 am 
Min-Maxer

Joined: Sat Jan 19, 2008 5:24 am
Posts: 923
Location: PA.ODI-RFC
Faction: Azure League

Offline
So, yea, there's a bug in the Chrome version (and has been since Sep '11).

Spreadsheet servers aren't working. It may be a JSON issue, or an incompatibility in how chrome treats ajax now. I'm sorry, but I don't have the time to look into it and fix it. The code is open, though, and I do think the problem is in bg.html, or possibly gm_compatibility.js; so if anyone else has the time and knowledge to fix it feel free to send me a patch!

Sorry, again.


Top
 Profile  
 
 Post subject: Re: Chrome bug
PostPosted: Sun Mar 18, 2012 5:10 pm 

Joined: Sun Jun 28, 2009 10:16 am
Posts: 103
Location: Illinois, USA
Faction: Flight School
Offline
Alright I think I've got this one figured out now after a few hours worth of tinkering and looking at other extensions.

The error that is thrown in the Javascript Console is a result of a function call to an invalid function from skycust.user.js around Line 38 approximately.

Code:
You Have:

var blacklist = GM_getValue('blacklist');
|
|
other code
|
|


But the function call asks for 3 parameters
Change it to:

var blacklist;

GM_getValue('blacklist', null, function(b) {
blacklist = b;
if (blacklist) { blacklist = JSON.parse(blacklist); } else { blacklist = {}; }
});


But that is all minor stuff that doesn't actually affect anything.

To just make it work, all you have to do is change manifest.json. Somewhere along the line of the request something doesn't get access. I assume that is because it is trying to go through https: instead of just http:. So if you change the permissions in the manifest to include "https://*/" everything appears to work again.


Top
 Profile  
 
 Post subject: Re: Chrome bug
PostPosted: Sun Mar 18, 2012 9:10 pm 
Min-Maxer

Joined: Sat Jan 19, 2008 5:24 am
Posts: 923
Location: PA.ODI-RFC
Faction: Azure League

Offline
Where were you in September? :remywicked:

Apparently I missed that call when continuifying the greasemonkey compatibility layer. Apparently no one noticed because no one uses blacklists >_>

So the issue was just the https xhr request being denied, huh. Chrome must have updated at some point to distinguish between those two permissions... cheers for figuring that out, and may I ask: how did you figure that out?

In any case, fixed and uploaded now. Your chrome skycust should update automagically soon. (The biggest problem was adhering to Google's new "guidelines" for screenshots, urgh :razz: )

_________________
One of the "arrogant scientists and wind-addled nomads."

Manager of Post Aviation. "We don't make planes. We make planes better."


Top
 Profile  
 
 Post subject: Re: Chrome bug
PostPosted: Sun Mar 18, 2012 9:19 pm 

Joined: Sun Jun 28, 2009 10:16 am
Posts: 103
Location: Illinois, USA
Faction: Flight School
Offline
How I figured it out was quite the adventure. I tinkered with the Extension until the Console quit throwing an error and I realized that it wasn't the problem in the first place. After that I started researching extensions and how to convert scripts. After converting the original script on my own and arriving at the same problem I had no idea.

I looked at some of the other extensions I had and realized that StumbleUpon used several other permissions including "Tabs" and "Https". I decided what the heck and threw them in to skycust and it was magic! StumbleUpon really helped me to stumble upon the answer :grin: .


TL; DR = It was trial and error.


Top
 Profile  
 
 Post subject: Re: Chrome bug
PostPosted: Sun Mar 18, 2012 9:29 pm 
Min-Maxer

Joined: Sat Jan 19, 2008 5:24 am
Posts: 923
Location: PA.ODI-RFC
Faction: Azure League

Offline
Heh. In retrospect, "examine a working example" really should have been higher on my list. Thanks again!

_________________
One of the "arrogant scientists and wind-addled nomads."

Manager of Post Aviation. "We don't make planes. We make planes better."


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group