Closed
Bug 585748
Opened 16 years ago
Closed 15 years ago
Make Mozmill extension a CommonJS package that uses the Jetpack SDK
Categories
(Testing Graveyard :: Mozmill, defect)
Testing Graveyard
Mozmill
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: harth, Unassigned)
Details
(Whiteboard: [mozmill-2.0-])
The fast path to Mozmill using CommonJS modules (both internally and for tests with shared modules) is to turn the Mozmill extension into a package that uses the Jetpack SDK.
Using CommonJS modules internally would make the code base more sane and additionally, the Jetpack SDK exposes the module loader *as* a module itself. This means we can load test files as modules and those test files can require shared modules.
I personally haven't worked through all the details, we could hit some walls here, but it's looking like a very desirable option.
The big problem with this however is that we would depend on Jetpack SDK. This means that every time we want to turn our package into an xpi that Firefox can load, we have to have the code for the entire Jetpack SDK on hand and call 'cfx xpi' on our CommonJS package. The command-line Mozmill currently gives Firefox a path to the directory that holds the code for the extension part of the Mozmill code.
If we were to go this route, the Mozmill Python package would probably have to ship with a pre-"compiled" xpi of Mozmill. Anyone hacking on the extension code would have to download the Jetpack SDK (or we could download for them) and tell Mozmill to re-compile the package into an xpi.
| Reporter | ||
Updated•16 years ago
|
Summary: make Mozmill extension using the Jetpack SDK → Make Mozmill extension a CommonJS package that uses the Jetpack SDK
| Reporter | ||
Updated•16 years ago
|
Whiteboard: [mozmill-2.0?]
Comment 1•16 years ago
|
||
Does that mean we will be forced to build the extension before we can use it after code has been changed? Right now we have simple folder we just copy to enable the extension in Firefox. What are the differences to the Jetpack SDK? Would something like the above not be possible anymore without a compilation process?
| Reporter | ||
Comment 2•16 years ago
|
||
(In reply to comment #1)
> Does that mean we will be forced to build the extension before we can use it
> after code has been changed?
Yes, the code for the extension would be a plain CommonJS package (e.g http://github.com/harthur/showsearch), we would need the Jetpack SDK to compile it into an extension.
| Reporter | ||
Comment 3•16 years ago
|
||
The compiling could be automated. Maybe pass a --build-extension command line arg and our Python could download the SDK if it hadn't already, link in the extension to the packages dir of the sdk and call 'cfx xpi', exporting to the directory where we load the extension from. It's not ideal, I'm open to criticism about this compiling part.
If we don't make the extension using the Jetpack SDK, we could try to take out the module loader (or use another module loader) and only make things like the controller and shared modules be CommonJS. It's just a lot nicer with Jetpack, from a development standpoint.
Comment 4•16 years ago
|
||
Does that mean Mozmill would only be available as Jetpack? What's with older versions of Firefox where we do not directly support Jetpacks? Do we have a list of enhancements or pro/cons in using the Jetpack API? Does the Jetpack API support components (also binary ones)?
Now that we have the commonJS loading of shared modules, shouldn't we close this bug?
--> WONTFIX?
I don't see any real benefit to do this.
--> WONTFIX.
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → WONTFIX
Whiteboard: [mozmill-2.0?] → [mozmill-2.0-]
| Assignee | ||
Updated•10 years ago
|
Product: Testing → Testing Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•