HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

"Could not parse addon info array." posting update to addon

Posting an update to https://open.vanillaforums.com/addon/useragent-plugin with the code currently at https://github.com/JasonBarnabe/UserAgent. I get "Could not parse addon info array.". The addon seems to run fine.

Is there something wrong with my addon.json? Or maybe this is because this is an update from the old format to the new format?

Comments

  • LincLinc Detroit Admin

    Are you remembering to put it in a folder with a name that matches your key before zipping it?

  • JasonBarnabeJasonBarnabe Cynical Salamander ✭✭

    The zip file contains a folder matching my key, yes. Zip file attached.

  • LincLinc Detroit Admin

    I can reproduce this with your addon and don't see anything obviously wrong with it.

    The message 'Could not parse addon info array.' comes from UpdateModel::checkAddon() in core, which I assume is being invoked by analyzeAddon().

    It appears it's been a while since someone uploaded an addon with JSON-only meta, so lemme see if a dev can look at the uploader tomorrow and see if there's a bug.

  • edited January 2019

    It looks like the order of the parameters in the addon.json matter. I was able to do a test upload with the flowing

    {
        "name": "User Agent",
        "description": "Record user agent and display it and browser icon above posts.",
        "version": "2.2",
        "mobileFriendly": true,
        "icon": "",
        "key": "UserAgent",
        "type": "addon",
        "documentationUrl" : "",
        "license": "GNU GPL2",
        "authors": [
            {
                "name": "Jason Barnabe",
                "email": "[email protected]",
                "homepage": "https://github.com/JasonBarnabe/UserAgent"
            }
        ],
        "require": {
            "vanilla": ">=2.5"
        }
    }
    

    Please try this and let me know.

    Thanks,

  • JasonBarnabeJasonBarnabe Cynical Salamander ✭✭

    It doesn't seem to be the order, but adding "documentationUrl" : "", made it work. Thanks for the help.

  • LincLinc Detroit Admin

    We're going to file an issue to resolve this in the uploader, but that's a fine work around for now.

  • Adding "documentationUrl" : "" do not help for my case, can somebody check on this?

Sign In or Register to comment.