Re: JSON and Firefox sessionstore.js

2009-04-24 Thread Matt Nordhoff
Steven D'Aprano wrote: > On Thu, 23 Apr 2009 05:08:35 +0100, I V wrote: > >> For something with at least a vague air of credibility to it, somebody >> who appears to be a Mozilla developer comments on their bug tracker, >> that sessionstore.js isn't "pure JSON" (though he only identifies the >> pa

Re: JSON and Firefox sessionstore.js

2009-04-24 Thread Дамјан Георгиевски
> Unless I'm badly mistaken, the Firefox sessionstore.js file is > supposed to be JSON. ... > If it matters, I'm using Firefox 2.0.0.5 under Linux. maybe it can be parsed with PyYAML? -- дамјан ( http://softver.org.mk/damjan/ ) Well when _I_ was in school, I had to run Netscape on HP/UX, displ

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread John Machin
On Apr 23, 12:16 pm, Steven D'Aprano wrote: > > The Mozilla knowledge base claims that sessionstore.js is JSON: > > http://kb.mozillazine.org/Sessionstore.js The claim is incorrect. > So does this tutorial: > > https://developer.mozilla.org/En/Firefox_addons_developer_guide/ > Let's_build_a_Fire

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread Steven D'Aprano
On Thu, 23 Apr 2009 05:08:35 +0100, I V wrote: > For something with at least a vague air of credibility to it, somebody > who appears to be a Mozilla developer comments on their bug tracker, > that sessionstore.js isn't "pure JSON" (though he only identifies the > parantheses, which are much easie

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread I V
On Thu, 23 Apr 2009 02:16:07 +, Steven D'Aprano wrote: > I'm leaning towards this being a bug in the json module. Unless somebody > can point me at a credible source that sessionstore.js isn't JSON, I > will report this as a bug. I'm just another random guy on the internet, but I'm pretty sure

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread Steven D'Aprano
On Wed, 22 Apr 2009 21:07:46 -0400, TommW wrote: > The json files are used for bookmark backups in FF 3.0 series. That's nice to know, but I'm afraid it's irrelevant to my question. There are lots of things which are JSON. Just because *something else* is JSON does not imply that sessionstore.j

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread TommW
Steven D'Aprano wrote: Unless I'm badly mistaken, the Firefox sessionstore.js file is supposed to be JSON. In Python 3.0, I do this: import json filename = '.mozilla/firefox/2z5po7dx.default/sessionstore.js' json.load(open(filename)) Traceback (most recent call last): File "/usr/local/lib/

Re: JSON and Firefox sessionstore.js

2009-04-22 Thread MRAB
Steven D'Aprano wrote: Unless I'm badly mistaken, the Firefox sessionstore.js file is supposed to be JSON. In Python 3.0, I do this: import json filename = '.mozilla/firefox/2z5po7dx.default/sessionstore.js' json.load(open(filename)) Traceback (most recent call last): File "/usr/local/lib/

JSON and Firefox sessionstore.js

2009-04-22 Thread Steven D'Aprano
Unless I'm badly mistaken, the Firefox sessionstore.js file is supposed to be JSON. In Python 3.0, I do this: >>> import json >>> filename = '.mozilla/firefox/2z5po7dx.default/sessionstore.js' >>> json.load(open(filename)) Traceback (most recent call last): File "/usr/local/lib/python3.0/json/