Closed Bug 596573 Opened 14 years ago Closed 14 years ago

manifest enforcement logs warning for all the modules in sub-directories

Categories

(Add-on SDK Graveyard :: General, defect)

defect
Not set
blocker

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: irakli, Assigned: avarma)

References

Details

Attachments

(2 files)

all tho modules in the modules in the content tree:
https://hg.mozilla.org/labs/jetpack-sdk/file/8b13707b865c/packages/jetpack-core/lib/content

report warnings durung the tests:

$ cfx test -F content-loader
Using binary at '/Applications/Firefox.app/Contents/MacOS/firefox-bin'.
Using profile at '/var/folders/-y/-yjxO9IXGGSRN-hSaip1Qk+++TM/-Tmp-/tmpibxMz8.mozrunner'.
warning: undeclared require(events) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(events) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(api-utils) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(api-utils) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(url) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(url) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
warning: undeclared require(file) called from resource://jetpack-core-jetpack-core-lib/content/loader.js
..................................error: warnings and/or errors were logged.

34 of 35 tests passed.
FAIL
Looks like the reason for this is because the python function cuddlefish.manifest.scan_package() is just doing an os.listdir() of a package's contents and not using something like os.walk() to recursively bust through its subdirectories.

As a result, no manifest information is created for modules in subdirectories.

Working on a fix for this now unless warner tells me not to...
Attached patch patchSplinter Review
Assignee: nobody → avarma
Status: NEW → ASSIGNED
Attachment #475572 - Flags: review?(warner-bugzilla)
Attached patch added unit testSplinter Review
Attachment #475572 - Flags: review?(warner-bugzilla)
Attachment #475575 - Flags: review?(warner-bugzilla)
Comment on attachment 475575 [details] [diff] [review]
added unit test

looks great! I don't believe the rest of the manifest-handling code will have any problems with slashes in the module names, but I'll keep it in mind while working on that side.
Attachment #475575 - Flags: review?(warner-bugzilla) → review+
Thanks! Pushed:

Bug 596573 - manifest enforcement logs warning for all the modules in sub-directories
Atul Varma [:atul]
http://hg.mozilla.org/labs/jetpack-sdk/rev/d1dc9a0c37bf
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
The Add-on SDK is no longer a Mozilla Labs experiment and has become a big enough project to warrant its own Bugzilla product, so the "Add-on SDK" product has been created for it, and I am moving its bugs to that product.

To filter bugmail related to this change, filter on the word "looptid".
Component: Jetpack SDK → General
Product: Mozilla Labs → Add-on SDK
QA Contact: jetpack-sdk → general
Version: Trunk → unspecified
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: