If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

package.js option of integer type inside a string breaks inline options of type `radio`

(Needinfo from 2 people)


Add-on SDK
3 years ago
8 months ago


(Reporter: Alexufo, Unassigned, NeedInfo)


Firefox Tracking Flags

(Not tracked)




3 years ago
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:33.0) Gecko/20100101 Firefox/33.0 (Beta/Release)
Build ID: 20140720030203

Steps to reproduce:

    "name": "dpi",
    "type": "radio",
    "title": "Точек на дюйм у принтера",
    "value": "200dpi",  // "200" - only digits didnt work
    "options": [
            "value": "200dpi", // "200" - only digits didnt work
            "label": "200dpi"  
            "value": "300dpi",  // "300" - only digits didnt work
            "label": "300dpi"

Actual results:

If i want to set value as digit -this option didnt saved.

Expected results:

Value should be saved as digits too.


3 years ago
OS: All → Windows 7


3 years ago
Flags: needinfo?(tomica+amo)
(In reply to Alexufo from comment #0)
>     "value": "200dpi",  // "200" - only digits didnt work

you can use only digits, but _without_ quotes, and this should work.


that said, it looks like we indeed have a bug here, but it's probably in the inline options code, not in the SDK code.

with the package.json posted above, our code, correctly, creates a string pref, while the code on the addon options page tries to setIntPref, and naturally fails.
Flags: needinfo?(tomica+amo)
Ever confirmed: true
Summary: package.js option → package.js option of integer type inside a string breaks inline options of type `radio`
We should either try to fix about:addons page so it interprets types same as SDK does, or change how SDK understands types.

zombie or erikvold would one of you mind to take this bug ?

Flags: needinfo?(evold)
Priority: -- → P2
I'd like to take a look but I'm not sure I'll be able to, and I know I can't until the end of my pto on oct 13th
Flags: needinfo?(evold)
Blocks: 790323
Whiteboard: [good first bug]

Comment 4

a year ago
I'm a new contributor, I'd like to take this bug up, can I get some more direction? Since it doesn't have a mentor, I am not sure who to ask.
Flags: needinfo?(rFobic)
Flags: needinfo?(erikvvold)

Comment 5

8 months ago
Because of the difficulty finding mentors and the expected life span of the SDK, we are removing [good first bug] from remaining SDK bugs.


8 months ago
Whiteboard: [good first bug]
You need to log in before you can comment on or make changes to this bug.