It would seem by that time the remote application is already gone from the tracking state, so we don't have a value to give.
Earlier in that file we do have a list of locally known app names in the relation, it might be possible for us to look there. I'm not positive, since we have been doing things like 'relation-departed' and having things cleaning up from there. I'm not positive if localState.ApplicationMembers only holds a value if the application has set a value in the app data bag. But it might be a potential solution.
Looking at the Juju side of the code, it is trying to set it:
github. com/juju/ juju/worker/ uniter/ relation/ resolver. go 235:
return hook.Info{
Kind: hooks.RelationB roken,
RelationId: relationId,
RemoteApplic ation: r.stateTracker. RemoteApplicati on(relationId) ,
}, nil
It would seem by that time the remote application is already gone from the tracking state, so we don't have a value to give. ApplicationMemb ers only holds a value if the application has set a value in the app data bag. But it might be a potential solution.
Earlier in that file we do have a list of locally known app names in the relation, it might be possible for us to look there. I'm not positive, since we have been doing things like 'relation-departed' and having things cleaning up from there. I'm not positive if localState.