Modify

Opened 5 years ago

Last modified 4 years ago

#18463 new enhancement

changeset download: only download modified members of relations

Reported by: skyper Owned by: team
Priority: normal Milestone:
Component: Core Version: latest
Keywords: template_report changeset content relation download Cc:

Description

What steps will reproduce the problem?

  1. Have a changeset which includes a least one relation with many members
  2. start JOSM with a changeset as argument or "download current version of changed objects" of a changeset through changeset manager


What is the expected result?

Only object which where modified in the changeset are downloaded

What happens instead?

Modified relations are completely downloaded including all members.

Please provide any additional information below. Attach a screenshot if possible.

If there are some bigger relations included, you do not find the real content anymore as it is hidden by all the other unmodified relations` members.
Getting rid of the unwanted members though filtering/purging is much more difficult than downloading incomplete members later on.

In my case I had ten relations with over 2000 members and did download thousands kilometre of unneeded ways.

Think the behaviour changed a while ago (last two years) but I am not sure and snapshot r14760 is the oldest one I checked which shows the same behaviour.

Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2019-12-25 22:08:48 +0100 (Wed, 25 Dec 2019)
Revision:15616
Build-Date:2019-12-26 02:30:54
URL:https://josm.openstreetmap.de/svn/trunk

Attachments (2)

18463.patch (8.2 KB ) - added by GerdP 4 years ago.
18463.2.patch (12.3 KB ) - added by GerdP 4 years ago.

Download all attachments as: .zip

Change History (17)

comment:1 by GerdP, 5 years ago

I would expect that JOSM downloads the complete relation if a member was added or removed or the role was changed or the tags of the relation were changed.

in reply to:  1 comment:2 by skyper, 5 years ago

Replying to GerdP:

I would expect that JOSM downloads the complete relation if a member was added or removed or the role was changed or the tags of the relation were changed.

How about an option or another button ?

For my use cases I would expect to keep the bbox of the changeset. Changes of members and roles are visible in the relation's history and if needed I still can download incomplete members or even all members manually.

Think about a changeset where only one way is split but ten or more big route relations are involved.

comment:3 by GerdP, 5 years ago

The changeset manager dialog allows to download the content of the changeset. This shows a list of the changed objects and you can select one and download it. Not sure what you are missing.
You focus on the case that a way was split in cs xyz. You should be able to find that with a search for

type:way changeset:xyz

But keep in mind that a user might also remove a way from several relations.

comment:4 by GerdP, 5 years ago

Another hint that might help: You may use the reverter plugin to revert the changeset first and undo that revert. I think the result is what you are looking for?

in reply to:  4 ; comment:5 by skyper, 5 years ago

Replying to GerdP:

The changeset manager dialog allows to download the content of the changeset. This shows a list of the changed objects and you can select one and download it. Not sure what you are missing.

Here again, I can only download the complete relation with all members but I only want to download the relation without members.

You focus on the case that a way was split in cs xyz. You should be able to find that with a search for

type:way changeset:xyz

changeset: covers only the last changeset but not all changesets an object was involved in. Not helpful if the object was changed meanwhile and I am talking about changesets a few month ago.

But keep in mind that a user might also remove a way from several relations.

Sure, all relations would be downloaded (incomplete) and the deleting of members is still visible in history viewer either directly from changeset manager or later with the incomplete relations.

Replying to GerdP:

Another hint that might help: You may use the reverter plugin to revert the changeset first and undo that revert. I think the result is what you are looking for?

Nice, did not know the trick. Indeed, this seems to be the result I was looking for and which should be working without the plugin.

Last edited 5 years ago by skyper (previous) (diff)

in reply to:  5 ; comment:6 by GerdP, 5 years ago

Replying to skyper:

Replying to GerdP:

The changeset manager dialog allows to download the content of the changeset. This shows a list of the changed objects and you can select one and download it. Not sure what you are missing.

Here again, I can only download the complete relation with all members but I only want to download the relation without members.

I thought about your sentence "you do not find the real content anymore". For your example with a split way there would be just one modified way and one created way in the list. Those would be the objects you are looking for.

in reply to:  6 comment:7 by skyper, 5 years ago

Replying to GerdP:

Replying to skyper:

Replying to GerdP:

The changeset manager dialog allows to download the content of the changeset. This shows a list of the changed objects and you can select one and download it. Not sure what you are missing.

Here again, I can only download the complete relation with all members but I only want to download the relation without members.

I thought about your sentence "you do not find the real content anymore". For your example with a split way there would be just one modified way and one created way in the list. Those would be the objects you are looking for.

I see, yes, for this extreme example it is easy that way. Have to update the wiki docs.
I was looking at it in a more general way, as I was hoping to find a way to download incomplete relations direct in changeset manager. I do not want to cherry pick every changed way in a bigger cs, download them and then loading their parents. Yes, that might work but is cumbersome.

comment:8 by GerdP, 5 years ago

My problem is that I don't understand what you are trying to do and why the suggested methods don't help.

comment:9 by skyper, 5 years ago

Primary goal was/is to save resources (osmapi, internet/network, local hardware and everywhere energy) though I forgot the human resources and I probably should stop now.


The story:
I quickly wanted to download two changesets. First a young one with command line option and within the application an old one to new layer. I intended to revue the young one and compare it to the old one. I have to mention that the younger one is the revert of the old one.

In order to check changes in relations I was only interested in the changed members and their direct neighbors in the relation`s order.
I would like to use validator but only on the bbox of the cs and not have it run over the whole relations.


You showed me a nice trick with reverter plugin that works in this case, thanks, but I still think it should be user's choice whether to download the full relation or just the incomplete relation.

comment:10 by GerdP, 4 years ago

I just stumbled again over this issue while testing #12303. The current code in the Changeset Manager calls the download task with both "download refererrers" and "download members" options enabled.
I assume the intention is that the downloaded data contains all objects which were possibly changed by the changeset.
Can be a lot more data than expected.
An alternative could be to show the same dialog as with download object and let the user decide regarding referrers.

in reply to:  10 comment:11 by skyper, 4 years ago

Replying to GerdP:

I just stumbled again over this issue while testing #12303. The current code in the Changeset Manager calls the download task with both "download referrers" and "download members" options enabled.
I assume the intention is that the downloaded data contains all objects which were possibly changed by the changeset.

Not exactly. It gives a complete overview and complete data is needed for rendering (e.g. unmodified way where its children did only change position; turn-restriction) and validator (e.g. unconnected node, route relation).

Can be a lot more data than expected.
An alternative could be to show the same dialog as with download object and let the user decide regarding referrers.

+1

by GerdP, 4 years ago

Attachment: 18463.patch added

comment:12 by GerdP, 4 years ago

With the patch the standard dialog for "Download object ..." (Ctrl+Shift+O) is presented, pre-filled with the ids extracted from the changeset manager dialog.
Drawback (or feature?): The history for this dialog is also updated.

in reply to:  12 ; comment:13 by skyper, 4 years ago

Replying to GerdP:

With the patch the standard dialog for "Download object ..." (Ctrl+Shift+O) is presented, pre-filled with the ids extracted from the changeset manager dialog.

Nice.

Drawback (or feature?): The history for this dialog is also updated.

More a drawback. I remember there was a similar problem with search, see #18146. Or, maybe, individual preferences for "Download object" and "Download object from changeset manager" can be used?

in reply to:  13 comment:14 by GerdP, 4 years ago

Replying to skyper:

Drawback (or feature?): The history for this dialog is also updated.

More a drawback. I remember there was a similar problem with search, see #18146. Or, maybe, individual preferences for "Download object" and "Download object from changeset manager" can be used?

I also think that this is not good. I think I know how to avoid this.

by GerdP, 4 years ago

Attachment: 18463.2.patch added

comment:15 by GerdP, 4 years ago

18463.2.patch implements:

  • standard dialog for "Download object ..." (Ctrl+Shift+O) is presented, pre-filled with the ids extracted from the changeset manager dialog.
  • dialog stores preferences with its own prefix changesets
  • common code moved to new class DownloadChangesetObjectsAction

I am not yet sure if it makes sense to store the primitive ids in history. Those lists can be very long.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from team to the specified user.
Next status will be 'needinfo'. The owner will be changed from team to skyper.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from team to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.