When I was using Potlatch 2, I attempted to save the changes and a dialog box popped up saying:

Error    
A server error occurred. Do you want to retry? (The server said: Precondition failed: Cannot create way: data is invalid.)

This has happened twice so far. How should I fix this problem and/or stop this from happening?

[EDIT] Would it be possible to enter the output data into OSM, and how?

(Since apparently the output code can't be copied into here, I have saved it at https://www.dropbox.com/s/ui0u5vnzsw8szly/osm%20file%2028%20dec%202013.xml.)

asked 28 Dec '13, 06:36

jc86035's gravatar image

jc86035
191111221
accept rate: 0%

edited 29 Dec '13, 16:52

aseerel4c26's gravatar image

aseerel4c26 ♦
30.7k15232520

1

for your side-question: please see upload-potlatch2-xml-raw-data-using-josm for how to upload a osmChange file (in short: not that easy).

(29 Dec '13, 05:09) aseerel4c26 ♦

I've read it, thanks. I've also deleted all the references to the changeset (19697275).

(29 Dec '13, 14:38) jc86035

Changeset (19708834) uploaded using JOSM.

(30 Dec '13, 04:59) jc86035

That's clearly a bug in Potlatch 2; two zero-length ways are present in the XML, which can't be saved. If you can provide a "test case" for this - i.e. a set of instructions which, when carried out, result in this bug happening - then we can fix it.

permanent link

answered 28 Dec '13, 15:26

Richard's gravatar image

Richard ♦
26.7k38236353
accept rate: 20%

1

I think the problem may have resulted from duplicating ways that have already been deleted. (ways -267, -268, and -269)

(29 Dec '13, 04:37) jc86035

I have deleted the three lines from the file:

<way id="-267" version="0" changeset="19674031"/>
<way id="-269" version="0" changeset="19674031"/>
<way id="-268" version="0" changeset="19674031"/>
(29 Dec '13, 04:52) jc86035

Is there anything else wrong with it?

(29 Dec '13, 05:42) jc86035

Test case:

  1. Create a way.
  2. Delete the way.
  3. Press the "Create parallel way (P)" button in the toolbox (or press P).
  4. There will now be a way that has no nodes.
(29 Dec '13, 15:06) jc86035
1

@jc86035: hmm, for me the create way button is inactive after deleting the way from step 1.

(29 Dec '13, 16:24) aseerel4c26 ♦
1

Corrected test case:

  1. Create a way/click on an existing way.
  2. Press the "Create parallel way (P)" button in the toolbox (or press P) as many times as you want to.
  3. Click anywhere on the map.
  4. There will now be a large amount of ways with no nodes.
  5. Press the Save button, and the dialog box will pop up.

Tested and works.

(30 Dec '13, 07:41) jc86035
1

@jc86035: thanks. I guess it is important to click several times on the button (in step 2). I (first created a new two-node way) clicked 5 times on it and had 5 ways without any node.

Reported in trac.

(30 Dec '13, 20:12) aseerel4c26 ♦

@aseerel4c26 Thanks!

(31 Dec '13, 05:30) jc86035
1

Ditto, thanks for the report.

(31 Dec '13, 10:21) Richard ♦
showing 5 of 9 show 4 more comments
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×204
×67
×50
×41

question asked: 28 Dec '13, 06:36

question was seen: 10,042 times

last updated: 31 Dec '13, 10:21

powered by OSQA