Closed
Bug 615752
Opened 15 years ago
Closed 15 years ago
self module does not return correct path to the data files
Categories
(Add-on SDK Graveyard :: General, defect)
Add-on SDK Graveyard
General
Tracking
(Not tracked)
RESOLVED
WORKSFORME
1.0b1
People
(Reporter: konstantin.novichikhin, Unassigned)
References
()
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.12) Gecko/20101026 Firefox/3.6.12
Build Identifier: Minefield 4.08pre
According to documentation for self module, self.data refers to addon-root\data folder. It works that way in FF3.6.12, but it doesn't in Minefield 4.08pre.
It seems to think that data must be under jetpack-core:
Error: path does not exist: C:\jetpack-sdk-0.9\packages\jetpack-core\data\test.html
Reproducible: Always
Steps to Reproduce:
1. the attached link is lib\main.js, create a dummy test.html (i just type in some text) and any icon under data (i used google from the examples)
2. launch in minefield: cfx run -a firefox -b minefield path
3. the icon will be missing from the first widget, and the second widget's panel will be empty.
4. launch in firefox: cfx run -a firefox -b firefox path
5. the icon will be there, as well as, the content of the panel
Also, uncomment the last line to see the error.
Actual Results:
Files are missing, returned path seems to be incorrect.
Expected Results:
It should behave the same way in minefield as in firefox.
From docs:
data is an object
The data object is used to access data that was bundled with the add-on. This data lives in the main package's data/ directory, immediately below the package.json file. All files in this directory will be copied into the XPI and made available through the data object.
Comment 1•15 years ago
|
||
I see this problem with Jetpack 0.9 but not with the current Jetpack tree. I'm not sure what fixed it, but there's been a lot of work since 0.9. Could you download the latest Jetpack tree and try to reproduce?
http://hg.mozilla.org/labs/jetpack-sdk/archive/tip.zip
Status: UNCONFIRMED → NEW
Ever confirmed: true
| Reporter | ||
Comment 2•15 years ago
|
||
Yes, works with trunk. I guess, I should pull code everyday, since it's still beta. Sorry.
Comment 3•15 years ago
|
||
No no, no problem! Thanks for reporting these bugs. I'll mark this one works-for-me since it's fixed in the tree.
Status: NEW → RESOLVED
Closed: 15 years ago
OS: Windows 7 → All
Hardware: x86 → All
Resolution: --- → WORKSFORME
Target Milestone: -- → 0.10
Updated•14 years ago
|
Target Milestone: 0.10 → 1.0b1
You need to log in
before you can comment on or make changes to this bug.
Description
•