Opened 11 years ago

Closed 7 years ago

Last modified 5 years ago

#2501 closed defect (wontfix)

potlatch creates invalid ways having only one node or multiple consecutive identical nodes

Reported by: xylome Owned by: richard@…
Priority: major Milestone:
Component: potlatch (flash editor) Version:
Keywords: Cc: leighghunt@…


  • a way can have identical nodes (e.g. circular ways), but there is no reason for having an identical node succeeding itself within a way.

please refer to the history of the ways in changeset in almost all cases potlatch was the editor in question generating those errors, before xybot repaired the errors.

Change History (44)

comment:1 Changed 11 years ago by Richard

Steps to reproduce please or I'll close this.

comment:2 Changed 10 years ago by xylome

Priority: minormajor

this is a serious issue, please investigate this further!

i don't have the slightest idea how this could be reproduced (i'm using JOSM as editor), but there are hundreds of those ways produced each day. see the changesset of xybot "removing multiple consecutive identical nodes in ways/delete one node ways" as a reference!

comment:3 in reply to:  2 Changed 10 years ago by Richard

Replying to xylome:

i don't have the slightest idea how this could be reproduced (i'm using JOSM as editor)

Then I would ask you to open Potlatch for once in your life, and try. I have a million and one people asking me to do things; if you want your particular itch scratched then you'll need to at least do a bit of the work yourself.

comment:4 Changed 10 years ago by xylome

let me first say, that i appreciate your work very much and that potlatch does a very good jobs in giving people a jumpstart into osm.

but it's not an itch of mine and yes i have no idea how this erroneous behaviour can be reproduced. i'm only seeing the results. it's a data integrity problem potlatch is producing here.

maybe you could do a validation of the ways potlatch produces before they get uploaded.

comment:5 Changed 10 years ago by Richard

That's kind of the problem, though - as far as I know (I haven't looked at that code for a while) Potlatch _does_ validate this. There's a method in called removeDuplicates that makes sure that if, for example, you have a way ABCB and C is removed, one of the Bs will be removed too. This is why I'm keen to get a reproducible test case.

comment:6 Changed 10 years ago by xylome

for me it seems as if it happens, when people try to doubleclick to end drawing a way. most of the multiple identical nodes are on the end of a way and do not seem to be the result of a deletion of a node in the middle of a way.

comment:7 Changed 10 years ago by xylome

some of the ways are one-node-ways. it seems as if the user deletes one node of a two-node-way. the result should be, that also the affected way should be deleted then. the last remaing node should also be deleted if it is no member of another way or relation.

comment:8 Changed 10 years ago by Richard

The hint about it being the end of a way is really helpful - thank you. I'll have a look next week once I've got a bit more free time.

comment:9 Changed 10 years ago by Ilis

I have such errors using Potlatch. I dont no steps to reproduce, but it often happens when I have add point on crossing ways with Shift+Click.

comment:10 Changed 10 years ago by katzlbt

I would bet it can be done by linking the way to itself and deleting the node before.

comment:11 Changed 10 years ago by NE2

Is this possibly related to ?

comment:12 in reply to:  1 Changed 10 years ago by koenigl@…

Replying to Richard:

Steps to reproduce please or I'll close this.

I’m not sure whether this is related to the problem discussed here (This is my second night with OSM ... ;-) but I just made the following observation in Potlatch:

After heavy load due to zooming out to far (during which the OS and Flash plugin raised message boxes concering non-reacting applications and Flash scripts, respectively) apparently keyboard input to Potlatch stopped working. At least, Potlatch did not seem to react to neither ESC, nor DEL, nor R. As a consequence, the only possibility (I knew about) to cancel the drawing of a new way that was started unintentionally was to click the first endpoint again, resulting in a single point (black-lined green circle in Potlatch) and maybe a way containing that point (that would have to be invisible). I left one of these near lat=48.06028, lon=11.47237, tagged “fixme”.

Behavior of Potlatch returned to normal after navigating (via the Browser) to “map” and then back to “edit”.

... hope that helps ...

comment:13 Changed 10 years ago by Richard

It's not related afaik.

comment:14 Changed 10 years ago by Sanderd17

Sometimes, I see black dots. When you click on one, it always produces a street, even if you just want to select the dot. One of those dots are the traffic lights in . Hope that has something to do with the bug. If not, it's another bug.


comment:15 Changed 10 years ago by Sanderd17

OK, all black dots are traffic lights, but I still don't get why these dots are treated in an other way than normal nodes.

comment:16 Changed 10 years ago by skippern@…

I had this bug occur doing import from scripts, it might be that this bug is not related to Potlatch at all. In my case it was DXF files converted to OSM XML and than split in layers. I discovered the connection between the scripts and multiple node bug when installing Validator plugin in JOSM. I have not checked if there are other activities behind the other occurrences of this bug. I have done my best to clean out these multiple nodes.

There are no one-node ways in my import as far as I can tell.

comment:17 Changed 10 years ago by mcld

xybot is asking me to give you "hints about how the bug can be recreated" (from <>). I didn't know I was creating these problems (pretty new to osm) so I'm not sure what to say. I'm just manually adding paths on my mac laptop (firefox 3.6.3), although I'm using a graphics tablet to draw them so that may be the issue? e.g. some small movements while clicking? That's pretty much all I can say at the moment, but feel free to ask me questions.

comment:18 Changed 10 years ago by NE2

I created this node when joining two crossing ways (shift-click): It was in Arcade Place four times, but I fixed that. I kept the dupe in LaSalle? as evidence. My workflow was to start at the west end of Arcade, joining it to each cross street in succession.

No, I don't have directions to reproduce. But if you go to and join this way to each cross street in succession, you'll sometimes get this. It happens annoyingly infrequently.

comment:19 Changed 10 years ago by Mark Pulley

Here's another one that I inadvertently caused: Changeset: Way with multiple identical nodes:

When I created the offending node ( ), I was creating a new way ( ). I can't remember if I created the new way, aligned it, then created the junction node (then removing the ends), or if I just clicked on the pre-existing way to create the node. Either way, the duplicate nodes only existed (until fixed by Xybot) on the pre-existing way. I did not split the way and then join the two ends up, so there is no obvious way for me to create the multiple consecutive nodes.

I was using Potlatch 1.4, MacOS 10.5, using Firefox. Can't remember the Flash version (I'm at work at the moment). Hope this helps.

comment:20 Changed 10 years ago by Mark Pulley

I'm using Firefox 3.6.3, flash version 10.0 r45.

comment:21 Changed 10 years ago by Mark Pulley

I've just inadvertently added another one - multiple consecutive identical nodes.

Changeset: Node: - appeared 5 times in a row in this way:

I've just manually fixed it .

comment:22 in reply to:  1 Changed 10 years ago by phillipsjk

Replying to Richard:

Steps to reproduce please or I'll close this.

I noticed that when joining ways, the editor prompts you to click to join when the cursor is over the node of the old way. After clicking, the user is asked to repeat the process even if the ways are already joined at that node. After clicking a second time, the user is no longer prompted.

I tried to reproduce the problem with (save, rather than live edit.) I also tried to reproduce the problem with a live edit session It appears the correct number of nodes were generated in both cases.

Potlatch 1.4 (save en) While I doubt the flash version matters, I was using Flash installed as a plug-in for Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/2008092510 Ubuntu/8.04 (hardy) Firefox/3.0.3

comment:23 Changed 10 years ago by phillipsjk

By accident, if discovered that xybot cleaned up after me: Node in question:

I created that node by sift-clicking where the two ways joined. I may have used Ctrl-click first, but that appeared to have no effect.

Attempt to reproduce by joining ends appear to have failed:

Attempt to reproduce by joining nodes on a self-overlapping way failed (potlatch does not appear to support that.

Created two overlapping ways:

Success!: Created two redundant nodes on lower way; I dragged the connection around to ensure the two ways were connected (should check if bug is present without dragging, but I won't). In changeset:

Summary: reproduced the "potlatch creates invalid ways having ... multiple consecutive nodes" part of bug.

comment:24 Changed 10 years ago by Richard

Good news but I'm having awful trouble parsing any of those sentences! And I can't really see what those ways are because you've deleted them.

Could you provide simple instructions to reproduce, along the lines of "click to start a new way, draw some points, double-click to end" etc. etc.?

comment:25 Changed 10 years ago by phillipsjk

Steps to reproduce:

  1. Create two overlapping ways with no common nodes.
    • Save.
  2. Select one way, then shift-click the intersection to join the two ways.
  3. (needs further investigation) Move newly created point to check ways really are joined
    • Save.
  4. Examine history of the 'lower' way. You should see some duplicated nodes.

To view the Deleted way history:

  1. Follow link showing way history
  2. Click on changeset
  3. Select appropriate way
  4. select "view history" link at bottom of page
  5. Resulting link:

No, the deleted way is not rendered :P

comment:26 Changed 10 years ago by Richard

Very strange. I can't reproduce that at all, either on my test box or the live site. The ways always come out perfectly formed when I follow those instructions, whether in save or live mode, with thin ways or thick ways, whatever I try.

(And yes I do know how to view deleted ways, obviously, it's just that I find using the data browser a PITA. :) )

comment:27 Changed 10 years ago by phillipsjk

Did you turn on extra debugging? when trying to reproduce the error again, I got an error message I couldn't read completely due to a character set I don't understand.

Possible things to check:

B: Does moving the node have an effect?

  • Test without moving; use history to verify connection
  • Test with moving
    • Joined ways by selection 'top' way, then shift-clicking on intersection. Dragged new node around to confirm connection. Note: This time editor seemed to start a new way at intersection; I don't know what I did differently when creating new node.

Server said: (Copy&paste does not work with potlatch; UTF-8 would be so much easier)

An unusual error happened (in 'startchangeset').

The server said:(Chinese or Japanese characters follow)

{Stroke from center to lower left}{Short stroke from upper right to center;longer stroke from center to lower right}{vertical stroke on upper left; 'J' on opposing side}{medium horizontal stroke near top with uptick;long horizontal stroke slightly below first;Both preceding strokes top a 'J'}{long horizontal stroke}{two ticks in upper left; 'J' starting at right below half-way point}{Backward 'E'}{single tick in uper left; 'J' starting at right below half-way point}{Vertical stroke on left with tick at bottom; two short horizontal strokes on right}{Upside-down 'Y'; two medium horizontal strokes above center; short vertical stroke on left edge of horizontal strokes}{Man with ladder on left}{'L' with bottom portion up-turned}{Downstroke with clockwise curl at bottom; two medium horizontal strokes}{'L' with bottom portion up-turned}{Vertical stroke from left of center to bottom left; short horizontal stoke through downstroke; Short horizontal stoke center-right; medium horizontal stroke lower right}{small circle lower left}{white space}{'\'}{'/';Vertical stoke on right}{downstroke with clockwise curl at bottom; single medium horizontal stoke near top}


{'2';'5';'5'}{man}{'7' wearing flat, broad hat; long horizontal stoke at center}{downstroke with uptick on left; floating tick upper left; upside-down 'Y' on right}{small up-side-down 'Y', set inside upstroke-horizontal stroke-downstroke}{Short horizonatal stroke upper left;'C';tick just above center-right}{Lambda symbol}{'J' on left; horizontal stroke-downstroke with tick}{'L' with uptutned bottom}{top horizontal stoke-'C'}{'<'}{vertical stoke from top left of center to bottom left; short horizontal stroke through top of downstroke; 3 short horizontal strokes on right}{vertical stroke ending in small 'c'; medium horizontal stroke above-center}{meduim vertical stroke with uptick top-left;tick on right above center}{small circle lower left}


Please try again: Potlatch will start a new


Please e-mail richard@(...) with a bug

report, saying what you were doing at the time.

--- End server message ----

"Tainted" changeset:

A: does it matter which way is selected before adding a node?

  • Shift-click without selecting either way
  • Shift-click selecting the bottom way
  • Shift-click selecting the top way

C: Does the flash version have an effect?

  • I have a copy of flash 9 I can use
  • May be able to test with a more up-to date browser

D: Do time constraints have an effect?

  • Does this only affect older computers with the CPU time maxed out?

comment:28 Changed 10 years ago by phillipsjk

Oops: Forgot to mention: I am in the habit of [C]losing the changeset before saving. This is an attempt to force the comment dialog box to appear.

comment:29 Changed 10 years ago by Richard

No, I haven't changed anything.

comment:30 Changed 10 years ago by phillipsjk

I am going to have to echo 'NE2' and says I can no longer reliably reproduce the bug. My latest attempt to follow my reproduction steps yielded correct results as far as I can tell:

I have noticed that my mouse does not always debounce properly under load, but I was unable to induce errors by triple-clicking, or by running Prime95 in background with default blended test settings. Firefox was using hardly any CPU time at all, even with Prime95 +19 niced (maximum; lowest priority). I had to stop prime95 to get the editor to draw the map (maybe I wasn't patient enough; but interrupts (disk paging) were using 0% of the CPU at the time).

I have confirmed the CPU and memory appear to be working correctly. I ran Prime95 with blended test, but reduced memory footprint (230MB instead of 760MB) for over 24 hours. No errors were reported. Potlatch was able to edit normally without disk paging. Because the download page was not working, I had to get the windows version from a mirror (ran it under wine).

comment:31 Changed 10 years ago by phillipsjk

note: just checked the 'top' man page: what I was calling 'interrupts' was actually 'iowait'; "Amount of time the CPU has been waiting for I/O to complete." (probably DMA transfers). With DMA enabled, interrupts rarely use more than a few % of CPU time.

I suppose it is possible the 'niced' prime95 was using 90% of the CPU time because firefox was spending 90% of the time waiting on the disk :P Prime95 didn't have to wait because it was in memory already.

comment:32 Changed 10 years ago by phillipsjk

I again failed to reproduce the problem with my reproduction steps. (

The only thing I can think of that I changed was the deletion of Flash cookies. I am using a linux version of flash that allows you to drop it into the mozilla pluging directory of a single user without affecting the whole system. The files I deleted are stored in:




I may need to resort to white-box debugging to track this down. I have never coded in flash in part because I oppose it in principle. I am using Potlatch instead of JOSM because I am lazy (still don't have my workstation "just so"; don't want to lose track of 20GB.).

The original report says that Potlach was the editor most commonly implicated. Which editor is most popular? Could the problem be server-side, but Potlatch gets implicated because it interacts with the server more often?

comment:33 Changed 10 years ago by ghia

I analysed a changeset

on Zeezwaluwstraat Before it was a simple crossing with the Meeuwenstraat in line with the other part of Zeezwaluwstraat (See not yet updated map eg bicycle) The first part was moved to the right. This means that a new point has to be created. This did happen. Next this point should be reconnected and be part of the Meeuwenstraat. In stead the point got duplicated and added again to the Zeezwaluwenstraat, where it already belonged to. (see v3) Not sure which operations you would need in Potlach to do such an operation.

Other case is There a point is deleted It was between two streets Rue René Binet and Route de Sens The new midpoint became of Route de Sens, which became then doubly added to the other road Rue René Binet.

Weird is also that in this changeset several version of the same object are present.

comment:34 Changed 10 years ago by leighghunt@…

Cc: leighghunt@… added

Hi - in OSM changeset 6379862 for way 85321659 ( there was the following comment:

removing multiple consecutive identical nodes in ways/delete one node ways. please help by giving hints, about how this potlatch bug can be reproduced

I edited these polygons first in Potlatch as three polygons, and then merged them into one polygon in JOSM, so this was probably user error, rather than a bug in Potlatch.

Cheers, Leigh.

comment:35 Changed 10 years ago by nakor.wp@…

This is very easy to reproduce in Potlatch 2: select a node at the end of a way, then double-click on it -> the node is now duplicated in the way.

In Potlatch 1, use the same process but it only "works"if you double click on a node after it turned blue.

See changeset (P2) and (P1) where I was able to do it several times.

comment:36 Changed 9 years ago by sdoerr

So could a developer perhaps 'accept' this supposedly 'new' bug report and see if they can fix it?

comment:37 Changed 9 years ago by cucafera

Changeset: While splitting the train track branches down here: Done to create a public transport relation:

Hope it helps. Tkanks a lot for your efforts, guys.


comment:38 Changed 9 years ago by bwnz

Yes, using Potlatch. Just had a look at history on a portion of map I edited 3 Jan (#10278715). Pretty sure no other changes have been made anywhere near here since BUT multiple instances of xybot claiming to be removing multiple consecutive identical nodes. Either message is indicating checking for problem rather than fixing, or problem may be introduced in data storage or manipulation after changeset saved. Which?

comment:39 Changed 8 years ago by Nick Austin

I've actully seen this bug several times while editing. In all cases I was just editing normally - adding points to the end of a way. The same as I've done many times previously and many times since without the bug appearing. In order words I don't have a sequence that reproduces the bug because it's just something that happens randomly.

However on several occasions I was able to use Z to undo the problem and this has given clues as to what happened. I actually see two variants of this problem one of which xybot can catch and the other just results in a very odd shapped way. I'll explain both as best as I can in case either is of help.

Variant 1: Having added several points to a way I click on a blank area of the map. A new node appears at the cursor but instead of joining the new point to the previous point Potlatch joins it to a completely different point somewhere in middle of the current way. If I press Z (undo) the newly created node disappears but the line drawn from the cursor now goes to the node in the middle of the way. If I press Z again I'm back where I was before I the mouse click. The way I see it a single mouse-click has for some reason resulted in Potlatch attempting to add two points to the line, the first of which is a duplicate of a point already along the line and the second point at the cursor. Hope that makes sense.

Variant 2: Very similar. Having added several points to a way I click on a blank area of the map. A new node appears at the cursor but instead of joining the new point to the previous point Potlatch joins it to some random point several km away from the current cursor location. If I don't notice and continue editing it results in a way which has what I can only describe as a spike. As with variant 1 it takes two presses of Z to delete the spike and put things back to normal.

comment:40 Changed 8 years ago by bill42

I just noticed this on a way I edited yesterday:

I remember joining nodes that were consecutive on the street.

Steps to reproduce: Have 3 ways, lets call the A B and C. Make B a vertical way with 4 nodes. Make A a horizontal way connecting to the 2nd node of B. Make C a horizontal way connecting to the 3rd node of B. (Save) Select A Move 2nd node of B to over 3rd node of B. Use J to join. (Save) B still has 4 nodes, with the 2nd and 3rd nodes being duplicated.

Here is the Way "B" from my attempt to reproduce.

comment:41 Changed 8 years ago by stevage

Resolution: fixed
Status: newclosed

Fixed here:

What's going on: when you merge B2 with B3, you end up with one node, but it's repeated in the node list for the way. In other situations, this would be legitimate, say if there was another couple of nodes between them: you'd have a sort of loop half way through the way.

Anyway, I've explicitly added a check for this situation. That addresses the specific issue raised by bill42. The rest of this thread was TL;DR - please reopen if I missed something that is still pertinent.

comment:42 Changed 7 years ago by Oli-Wan

Resolution: fixed
Status: closedreopened

Sorry to disappoint you, but the bug has not been fixed, or at least not completely - Potlatch still creates ways with consecutive identical nodes.

Just one example out of many (created in April of 2013):
There are also ways consisting only of several incarnations of the same node, like this one: That's an example from Potlatch 1, though.

Last edited 7 years ago by Oli-Wan (previous) (diff)

comment:43 Changed 7 years ago by Oli-Wan

Some more material: v1 2013-04-05 Potlatch 2 v1 2013-03-27 Potlatch 2 v6 2013-03-30 Potlatch 2 v4 2013-03-22 Potlatch 2 v5 2013-03-22 Potlatch 2 v2 2013-03-28 Potlatch 2 v1 2013-03-19 Potlatch 2 v1 2013-03-19 Potlatch 2 v5 2013-03-30 Potlatch 2 v3 2013-03-04 Potlatch 2 v1 2013-02-12 Potlatch 2 v1 2013-02-12 Potlatch 2 v1 2013-02-03 Potlatch 2 v1 2013-02-03 Potlatch 2 v1 2013-02-03 Potlatch 2 v1 2013-01-25 Potlatch 2 v1 2013-01-06 Potlatch 2 v3 2013-01-12 Potlatch 2 v1 2012-12-01 Potlatch 2 v1 2012-11-21 Potlatch 2 v1 2012-10-23 Potlatch 2 v1 2012-10-06 Potlatch 2 v1 2012-10-05 Potlatch 2 v1 2012-10-05 Potlatch 2 v2 2013-03-07 Potlatch 2 v1 2012-10-04 Potlatch 2 v1 2012-10-04 Potlatch 2 v7 2013-03-02 Potlatch 2 v4 2013-03-15 Potlatch 2 v17 2013-03-25 Potlatch 2 v2 2012-10-05 Potlatch 2 v5 2013-02-16 Potlatch 2 v2 2013-02-21 Potlatch 2 v3 2013-03-26 Potlatch 2 v7 2013-03-26 Potlatch 2 v3 2012-10-04 Potlatch 2 v3 2013-01-24 Potlatch 2 v22 2013-02-24 Potlatch 2 v3 2013-02-28 Potlatch 2 v2 2013-04-07 Potlatch 1.4 (live de) v1 2013-04-03 Potlatch 1.4 (save en) v1 2013-03-15 Potlatch 1.4 (live en) v1 2013-03-15 Potlatch 1.4 (live en) v1 2013-03-11 Potlatch 1.4 (save fi) v1 2013-03-11 Potlatch 1.4 (save fi) v1 2013-02-19 Potlatch 1.4 (save de) v1 2013-01-19 Potlatch 1.4 (live de) v1 2013-01-18 Potlatch 1.4 (save fi) v1 2013-01-11 Potlatch 1.4 (save fi) v1 2012-12-25 Potlatch 1.4 (live de) v2 2012-12-21 Potlatch 1.4 (save ru) v1 2012-10-14 Potlatch 1.4 (save ru) v1 2012-10-13 Potlatch 1.4 (live de) v2 2013-01-20 Potlatch 1.4 (save en) v4 2013-02-18 Potlatch 1.4 (save de) v14 2013-03-01 Potlatch 1.4 (live de) v17 2013-01-03 Potlatch 1.4 (save ru) v9 2013-02-18 Potlatch 1.4 (save de) v5 2013-02-18 Potlatch 1.4 (save de) v6 2013-02-27 Potlatch 1.4 (save fi)

comment:44 Changed 7 years ago by iandees

Resolution: wontfix
Status: reopenedclosed

Cleaning aging tickets. If someone can nail down a reproducible problem feel free to reopen this in the potlatch2 component.

Note: See TracTickets for help on using tickets.