I’ve been developing an add-on for jira and it’s been working rather well until I published, removed my manually added add (manually specified, self-hosted atlassian-connect.json) and added a private listing of my add-on (I’m testing the market place works as expected before pushing it public).
However I’m now getting odd issues. If I don’t have a debugging console active, when I call for AP.context.getContext nothing happens. No exceptions, the callback method isn’t called and nothign in the console other than the normal noise about “‘triggerPrivacyPolicySafeEvent’ has been deprecated” and [Simple-XDM] Failed to validate origin"… however if I turn on a debugging console I’ll get a null reference exception logged in the console:
TypeError: a is null batch.js
getContext batch.js
vb</a.prototype._handleRequest batch.js
vb</b.prototype._receiveMessage batch.js
<anonymous>
decompiling the batch.js file I found the very first line of getContext is failing:
getContext: function (a) {
var b = d(a._context.extension);
Inspecting all arguments sent to the method I get an array with
0: null
1:d()
callee:getContext()
length: 2
Symbol(Symbol.iterator):values()
Inspecting d(), the second argument, I get an object with _context with the obvious extension property that matches my add-on.
So the question I have is why would this add-on fail simply because I’ve listed it in the Atlassian Marketplace and installed it as a private listed add-on?
What have I miss-configured in the listing?