Multipolygon Roles
Description
Trying to create a multipolygon relation (as in changeset 155800266), the Rapid editor would not let me assign roles to lines in the multipolygon. I had to switch editors to complete the change.
Screenshots
No response
Version
2.3.2
What browser are you seeing the problem on? What version are you running?
Chrome v127.0
The OS you're using
win
Steps to reproduce
These were existing features that I was grouping into a multipolygon in order to name them. I added them to the relation, but I could not assign roles from within the pop-up warnings.
The browser URL at the time you encountered the bug
https://rapideditor.org/edit#map=15.16/45.6165/-113.2014&background=Bing&datasets=fbRoads,msBuildings&disable_features=boundaries&overlays=US_Forest_Service_roads_overlay,StravaHeatmapAll
The auto-detected useragent string for your browser (leave blank if you're manually filling this form out)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36
Referencing the changeset here. What kind of relations and roles were you trying to add to each way @jwtrull?
I was creating a multipolygon relation for these lakes. https://www.openstreetmap.org/relation/17977499
Editor will not let me select inner / outer roles from dropdown or prompted link selection. I have to manually type them in the roles box.
I am also having this problem on every multipolygon relation I've created for some time now on 2.5.5 in Firefox. The culprit is line 96 of missing_role.js. Here's the error that gets thrown in the browser console:
Uncaught TypeError: can't access property "data", this.issue is undefined
onClick missing_role.js:96
buttons entity_issues.js:189
contextListener on.js:3
For convenience's sake, this is the function in question, with const oldMember... being the line causing the error:
function makeAddRoleFix(role) {
return new ValidationFix({
title: l10n.t(`issues.fix.set_as_${role}.title`),
onClick: () => {
const oldMember = this.issue.data.member;
const member = { id: this.issue.entityIds[1], type: oldMember.type, role: role };
editor.perform(actionChangeMember(this.issue.entityIds[0], member, oldMember.index));
editor.commit({
annotation: l10n.t('operations.change_role.annotation', { n: 1 }),
selectedIDs: [member.id]
});
}
});
}
It's not apparent to me what could be causing this error, since it's presumably specific to some kind of system configuration, but I still encounter it in a browser session with all potentially-interfering addons (e.g., adblockers) disabled.