Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

412 Precondition failed doesn't help #1783

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 6 comments
Closed

412 Precondition failed doesn't help #1783

openstreetmap-trac opened this issue Jul 23, 2021 · 6 comments

Comments

@openstreetmap-trac
Copy link

Reporter: frawe
[Submitted to the original trac issue database at 10.02am, Saturday, 2nd May 2009]

Currently I'm stuck having quite a few changes but can't upload them (as diff with JOSM) since the server replies with "Precondition failed" - that doesn't help me even a bit.

Please please make the error message more verbose containing which precondition on which element. That would be a huge help to fix such a problem.

@openstreetmap-trac
Copy link
Author

Author: tom[at]compton.nu
[Added to the original trac issue at 4.12pm, Saturday, 2nd May 2009]

One of the new features of API 0.6 is that it does indeed return details of what it wrong in the body of the HTTP response. If your client isn't showing that to you then you need to complain to the authors of that client.

@openstreetmap-trac
Copy link
Author

Author: frawe
[Added to the original trac issue at 6.04pm, Saturday, 2nd May 2009]

Err sorry, I tried hard to find any hints help me saving my edits but there simply isn't any.
Sniffing the wire with Wireshark showed me:

HTTP/1.1 412 Precondition Failed
Content-Type: text/plain; charset=utf-8
X-Runtime: 0.11828
Cache-Control: no-cache
Content-Length: 0
Date: Sat, 02 May 2009 14:15:17 GMT
Server: lighttpd/1.4.19

and the body is really empty. I don't know if JOSM would show me any content, but at least in this case it isn't the clients fault.

@openstreetmap-trac
Copy link
Author

Author: smsm1
[Added to the original trac issue at 10.19pm, Saturday, 2nd May 2009]

Can you please attach the osm file, so that I can look into this futher and find the bit of code, which isn't producing the error message?

@openstreetmap-trac
Copy link
Author

Author: frawe
[Added to the original trac issue at 9.16am, Sunday, 3rd May 2009]

Replying to [comment:4 smsm1]:

Can you please attach the osm file, so that I can look into this futher and find the bit of code, which isn't producing the error message?

Attached one. This isn't the originally problematic file as I finally somehow worked around the problem by investing quite some time and fiddling with it in an editor and don't have it anymore. Also I know what the problem in this file is and that this shouldn't happen by using an editor. But it somehow happened and got me in trouble.

Note that this not only occurs if a node gets action=delete though still being in a way but also a way gets action=delete though being in a relation.

@openstreetmap-trac
Copy link
Author

Author: grand.edgemaster[at]gmail.com
[Added to the original trac issue at 7.26pm, Wednesday, 6th May 2009]

[*] I can confirm that the 412 works as expected with error message on local WebBrick testing servers.

[*] I can confirm that the 412 works as expected with error message on api06.dev.openstreetmap.org.

[*] I can confirm that the 412 without specific error exists on the production server.

@openstreetmap-trac
Copy link
Author

Author: tom[at]compton.nu
[Added to the original trac issue at 10.24pm, Thursday, 7th May 2009]

This is caused by a lighttpd bug (http://redmine.lighttpd.net/issues/show/1055) and has been fixed by upgraded lighttpd to 1.4.22 on the live site.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant