Kaart: Conflicts and Resolution Guide/sandbox

From OpenStreetMap Wiki
Jump to navigation Jump to search

Introduction

The goal of this training is to provide editors ways in which to resolve these conflicts as well as ways to prevent this from happing. Knowing how to prevent conflicts will help reduce the amount of repeated work you need oto do, which allows you more time to accomplish your tasks for the day, and it'll reduce the amount of stress of not knowing what to do when you find yourself in this situation.

Prerequisites

You need to know:

  • How to make edits in OSM.
  • How to communicate with other editors.

Skill Instruction

Conflicts occur when OSM has a more up to date version of the data you are attempting to upload. OSM servers typically update as soon as someone uploads their edits. Occasionally, OSM servers won't automatically update the data you are working on and when you attempt to upload your edits, a conflict will occur.

What is a Conflict

A conflict is when two or more editors download the same objects within the same area, edit or interact with the same object and upload their edits. JOSM may not know which version of the objects it should retain so it creates a conflict to try and resolve the issue(s).

Common Reasons Why Conflicts Occur

Your data set is out of date.
(doesn't match what's currently on the OSM server)
  • This can occur when you don't upload your edits very often and when you do, a newer more updated version already exists for the objects you had edited.
  • The Tasking Manager does not grab the most recent version of the object you want to work with. This may occur if you uploaded, deleted the layers and then downloaded the task from the Tasking Manager again.
Other editors are working nearby.
  • Be aware of who is working nearby. Especially in dense areas.
Edits aren't fully uploaded to OSM servers.
  • Sometimes the servers take longer to update depending on the size of the edit. If you download data before the server can update, it will end up causing conflicts once you try to upload because you have an old version of the data.
You and another editor both touched a feature that shares a relation.
  • This often happens with bus routes or large multi-polygons.

How to Prevent a Conflict

The best way to resolve a conflict is to avoid getting one in the first place. This takes some practice to get good at.

Here are some tips on how to prevent a conflict:
Know where other editors are working.
  • Utilize the Tasking Manager to see where active editors are.
  • Communicate with editors you are close to.
  • Use available tools to see active editors in your areas.(list some)
Communicate
  • Let others know where you're working, especially towards the end of project when there are only a few tasks left that are close together.
  • Coordinate with other editors(when possible) to have some move to a different project.
  • Reach out to active editors in your area to let them know you are working nearby.
Download a small portion outside of your area.
  • This will cause OSM to grab the most up to date data for you.
    • This is especially helpful when working on TM projects as it can download additional features that aren't currently visible.
Download entire features/areas.
  • This makes it easier to work on the feature since all of it is visible.
Save often
  • Save often and in small, condensed areas.
    • Keeping your changeset size and area small greatly reduces the risk of getting a conflict.

How to Resolve a Conflict

Resolving conflicts is simple in theory, but each conflict is unique so some may not be as simple to resolve as others. We'll cover general tips and guidelines for each type of conflict you may encounter.

ID/Rapid

(add later)

JOSM

Finding Conflicts

You'll know you have a conflict(s) when ou go to upload and a popup window appears during the upload like the one pictured below.

insert image

This window will tell you:

  • That JOSM has two different versions of the data; your version and the version on the server which caused your upload to fail.
  • What feature caused the conflict; nodes, ways, or relations.
  • What you do to find the conflict so it can be resolved.
    • Synchronize entire dataset.
    • Synchronize feature only.

Always try synchronizing the entire dataset first. This usually finds all of the conflicts.

  • Note: If synchronizing the entire dataset doesn't work, try just synchronizing the "feature".
  • In rare cases you'll have to get creative to get the conflict to appear. Try updating your data, updating modified, etc. to force the conflict to appear.

Another popup should appear asking if you would like to check on the server for updates.

  • Click Ok.

One last popup should appear with the number of conflicts that were found.

insert image

Investigate

Once you've found all of the conflicts you'll want to do a quick investigation of the conflict(s) before you try to resolve them.

Some key things to look for are:
The data
  • What is physically wrong?
Who?
  • Who is the conflict with?
When?
  • When were the edits made by each person?
What kind of conflict is it?
  • Tags, relations, nodes, etc.

Do this for every conflict. This will help you better understand how to resolve each conflict and what you should keep an eye on as you resolve it.

  • Note: This can be done as you begin resolving each conflict.

There are two ways to investigate a conflict and you will use both ways to resolve most conflicts.

For investigating physical issues: For investigating the conflict itself:
  • Go to the conflict window on the dialogues panel.
  • Right click on the conflict and select zoom to conflict.
    • This won't work for every conflict.
    • Very useful for seeing current issues and how the data will look once the conflict has been resolved.
  • Go to the conflict window on the dialogues panel.
  • Click on the conflict then click Resolve.
    • This will open the conflict window with details about the conflict.
    • This is where you will resolve the conflict.

insert image

What Kind of Conflict is it

Each conflict is unique and will require a different approach to resolve it. Knowing about the different types of conflicts and how they can be resolved is key to doing it correctly.

There are four different types of conflicts:

  • Properties with conflicts
  • Tags
  • Nodes
  • Members
Properties

Property conflicts typically have to do with a deleted node.

There are three fields in these conflicts, but only two that need to be modified.

  • Coordinates: Where the node is located.
  • Deleted State: Whether or not the node was deleted.
  • Referenced by: The feature the node is/was on.

How to resolve:

  • Zoom to the location.
    • This allows you to see an changes to the data when you resolve the conflict to see if it's correct.
  • Resolve the conflict.
    • Try resolving to the version that is currently on the server first and see what the data looks like.
      • You should be able to see visual changes as you resolve the conflict.
      • Does the data look better? Does it look worse?
      • Try the other option if it looks worse.
  • Upload and run the validator.

insert images

Tags

Resolving tag related conflicts is simple. The conflicting tags will all be listed and you decide which value is correct.

There are typically two scenarios you'll encounter with tag conflicts:

  • There are two different values: You decide which one is correct.
  • One value is undefined: This means that one of the features doesn't have that tag. First, check if the object needs that tag, then accept the value that best applies.

insert image

Nodes

Node conflicts usually have something to do with geometry changes.

There are three types of nodes you'll encounter in these conflicts:

  • Nodes that are the same 🟢
  • Nodes that have been modified 🟡
  • Nodes that have been deleted 🔴
How to resolve:
Zoom to the location.
  • This allows you to see any changes to the data when you resolve the conflict to see if it's correct.
Pull over the data that's on the server.
  • This is the most up-to-date data.
  • Use the buttons next to the data set to do this.
Use the node IDs to compare the two data sets and merge your changes as needed.
  • You have to select a feature(s) in both data sets and use the buttons to add yours in the correct spot.
Click Freeze to freeze the combined data set to accept the resolution.
  • Freeze prevents you from making additional changes.
Click Ok and review the data to see if there are any noticeable issues.
  • Does it look better?
  • Does it look worse?
Upload
  • Once everything has been resolved and the data looks correct.
Note: In some cases you don't need to merge the two data sets to resolve the conflict. If nothing needs to be merged, then you should be able to resolve the conflict without merging.

insert image

Members

Member conflicts are changes to relations. This doesn't always mean the relation itself was modified, but more likely that the ways with the members were modified in some way.

There are three types of members you'll encounter in these conflicts:

  • Members that are the same 🟢
  • Members that have been modified 🟡
  • Members that have been deleted 🔴
How to resolve:
Zoom to the location
  • This allows you to see any changes to the data when you resolve the conflict to see if it's correct.
  • Depending on the type of relation this may not be useful.
Pull over the data that's on the server.
  • This the most up-to-date data.
  • Use the buttons next to the data set to do this.
use the member IDs to compare the two data sets and merge your changes as needed.
  • You have to select a feature(s) in both data sets and use the buttons to add yours in the correct spot.
Click Freeze to freeze the combined data set to accept the resolution.
  • Freeze prevents you from making additional changes. You will have to un-freeze the data to continue making modifications.
Click Ok and review the data to see if there are any noticeable issues.
  • Does it look better?
  • Does it look worse?
  • Are there any gaps in the data?
Upload
  • Once everything has been resolved and the data looks correct.
Note: In some cases you don't need to merge the two data sets to resolve the conflict. If nothing needs to be merged, then you should be able to resolve the conflict without merging.

insert images

Precondition Failures

A precondition failure is a special type of conflict. Basically, what happens is you interacted with a feature that is deleted on the server which created a conflict...except it doesn't.

There are a few ways to resolve this type of conflict:
Try updating your data to force a conflict to appear.
  • Resolve the conflict if this works.
Run the validator and look for a warning/error about precondition failures.
  • This is a newer update to the validator which should have an auto fix option.
Purge the object.
  • This can be found under Edit on the JOSM main toolbar.
  • You must have the ID of the deleted object so you can purge it from your data layer.
Delete your data layer.
  • This should be your last resort.
  • This allows you to start with fresh data, but you'll have to re-make your changes.

insert image

Other Tips/Notes

Here are some additional tips and notes when working with conflicts.

  • Ask for help resolving conflicts if you need it.
    • We want to make sure it is resolved correctly to aoid creating other potential issues.
  • Always coordinate with the person you're conflicting with.
    • If they're not on our team, look into how recent their edits are, resolve the conflict and move to another area as needed when necessary.
  • Always run the validator once you've resolved the conflict and uploaded your changes.
    • Look for any potential issues that may have been created by the conflict like duplicate ways and geometry issues.
  • Sometimes, you can't resolve the conflict and need to delete your layer.
    • You can modify your upload settings so you can upload most of your changes up to the conflict.
      • Select Settings in the upload window.
        • You can upload everything in one request.
        • You can upload in chunks of a specified amount. (You decide the amount)
        • Upload each object individually.

insert image

  • When dealing with a large amount of conflicts it's best to delete your layer rather than waste time trying to resolve each one.
  • Some conflicts can be resolved just by updating your data.

Practical Application

Suggested Bookmarks