In fact, I never wrote a real extension. I made one that was just a drop down list of links, but actually it is not. In any case, instead of diving primarily into the massive collection of guides for writing Chrome extensions, I decided that I would first make sure that my idea would be possible.
My plan is this: I want to take the currently playing track in the Pandora player and send the track information to a source outside the browser (in my case, a Python script).
Getting the information itself should not be difficult; their new HTML5 interface makes this part super easy. The problem is to report this information as soon as I receive it. I would like you not to upload data to the web server, and Python pulled it from there.
Obviously, Chrome won't make it easier for extensions to send DBus messages or anything else, but is it possible to write the file to the Chrome system directory somewhere and get Python? Am I completely ridiculous even asking such a question?
EDIT: I thought I would report on what I actually did for everyone who happens in the future in this matter. Since I only needed this extension to work on one computer (mine), I just installed mod_python for Apache, and my extension sent its data directly to my Python script, waiting on localhost. This has the advantage that you do not need to try out the URL or the Python file, as I assumed I needed. It also avoids the potential security risks associated with NPAPI.
source share