improved diagnostics patch v2

Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike

Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike

HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike

Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike

Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Mike, forget the part reg. changed img files, I made a mistake while testing. Differences where caused by the svn version string in mkgmap (mkgmap-r4593M vs mkgmap-r4593) Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 10:58 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Mike, not sure if this is intended: (way followed by link to relation without a "generated from" FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\work.osm: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/relation/1518688 at http://www.openstreetmap.org/?mlat=53.892259&mlon=8.684634&zoom=17 Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Mittwoch, 13. Januar 2021 21:53 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Gerd, the toBrowseURL function just returns an OSM URL currently, unless the element is not derived from an OSM object, so that is the expected result. Do you want to me change this so that is does include "generated from"? I think that actually most of the calls to toBrowseURL would be better calling getBasicLogInformation instead, which would make the log files smaller and more readable. I do find the coordinate URLs useful, but never use the ones for ways/nodes/relations. Does anyone else use them? Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 14 January 2021 07:33 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, not sure if this is intended: (way followed by link to relation without a "generated from" FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\work.osm: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/relation/1518688 at http://www.openstreetmap.org/?mlat=53.892259&mlon=8.684634&zoom=17 Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Mittwoch, 13. Januar 2021 21:53 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

HI Gerd, I spotted a problem in Element.getBasicLogInformation if it is called on an element that does not have an OSM Id. The attached patch fixes that. The previous version only fixed it in Element.toBrowseURL. Cheers, Mike -----Original Message----- From: Mike Baggaley [mailto:mike@tvage.co.uk] Sent: 13 January 2021 20:53 To: 'Development list for mkgmap' <mkgmap-dev@lists.mkgmap.org.uk> Subject: RE: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Mike, didn't help for my case where way.toBrowseURL() is called for a way which was generated from a multipolygon. (WrongAngleFixer line 688) I think I can replace toBrowseURL() with getBasicLogInformation() there and in all other debug.log() messages. I think the urls are not helping anyway when debugging. There are also some duplicated blanks in log messages. My current version of toBrowseURL() looks like this: public String toBrowseURL() { if (FakeIdGenerator.isFakeId(id)) return "generated from " + getOrigElement() + " " + originalId; return "http://www.openstreetmap.org/" + kind() + "/" + id; } Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Donnerstag, 14. Januar 2021 12:59 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, I spotted a problem in Element.getBasicLogInformation if it is called on an element that does not have an OSM Id. The attached patch fixes that. The previous version only fixed it in Element.toBrowseURL. Cheers, Mike -----Original Message----- From: Mike Baggaley [mailto:mike@tvage.co.uk] Sent: 13 January 2021 20:53 To: 'Development list for mkgmap' <mkgmap-dev@lists.mkgmap.org.uk> Subject: RE: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Mike, here's the result of my additional changes. Please double check. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Freitag, 15. Januar 2021 08:07 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, didn't help for my case where way.toBrowseURL() is called for a way which was generated from a multipolygon. (WrongAngleFixer line 688) I think I can replace toBrowseURL() with getBasicLogInformation() there and in all other debug.log() messages. I think the urls are not helping anyway when debugging. There are also some duplicated blanks in log messages. My current version of toBrowseURL() looks like this: public String toBrowseURL() { if (FakeIdGenerator.isFakeId(id)) return "generated from " + getOrigElement() + " " + originalId; return "http://www.openstreetmap.org/" + kind() + "/" + id; } Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Donnerstag, 14. Januar 2021 12:59 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, I spotted a problem in Element.getBasicLogInformation if it is called on an element that does not have an OSM Id. The attached patch fixes that. The previous version only fixed it in Element.toBrowseURL. Cheers, Mike -----Original Message----- From: Mike Baggaley [mailto:mike@tvage.co.uk] Sent: 13 January 2021 20:53 To: 'Development list for mkgmap' <mkgmap-dev@lists.mkgmap.org.uk> Subject: RE: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Mittwoch, 13. Januar 2021 09:22 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, thanks, I'll have a closer look today. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Montag, 11. Januar 2021 10:20 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, Thanks for the updated patch. I have got rid of the repeated definitions of "generated from" by using getBasicLogInformation as the basis of toString. This makes them all consistent (although it is not capitalised or have a colon). It would be more logical for the toString function to contain just the basic information, the information currently in toString to be in a new getExtendedLogInformation function and getBasicLoginInformation deleted. However, this would need a lot of changes elsewhere. Does RoadDef.toString really need to output a URL? It would improve the reading of my log files if it was just "(way" + id + ")". For consistency with above, this should really be "RoadDef + id" / "RoadDef generated", which would suit me fine. What do you think? Please find attached an updated version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 10 January 2021 08:04 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, sorry, I looked at your first patch but forgot to answer. I always hesitate to change those debug messages because some users parse them with scripts. I think Way.toString() should work similar to Node.toString and Relation.toString and thus return a string starting with "WAY:". See my modified version. I don't like the repeated code producing the "generated from" messages. Isn't it possible to implement that once in classElement? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 9. Januar 2021 17:18 An: 'Development list for mkgmap' Betreff: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, My previous diagnostic improvements patch seems to have got lost, but since then I have noticed another couple of items to include, so attached is an updated version. Cheers, Mike _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Gerd, I have made a couple of small changes in the attached version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 15 January 2021 08:26 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, here's the result of my additional changes. Please double check. Gerd

Hi Mike, thanks again. I've committed this patch with r4594. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Samstag, 16. Januar 2021 01:50 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Gerd, I have made a couple of small changes in the attached version. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 15 January 2021 08:26 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, here's the result of my additional changes. Please double check. Gerd

HI Gerd, That implementation of toBrowseURL doesn't handle the case where originalId is also a generated Id (e.g. the background areas generated in SeaGenerator which do not relate to any OSM way). How about: if (FakeIdGenerator.isFakeId(id)) return getBasicLogInformation(); Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 15 January 2021 07:07 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, didn't help for my case where way.toBrowseURL() is called for a way which was generated from a multipolygon. (WrongAngleFixer line 688) I think I can replace toBrowseURL() with getBasicLogInformation() there and in all other debug.log() messages. I think the urls are not helping anyway when debugging. There are also some duplicated blanks in log messages. My current version of toBrowseURL() looks like this: public String toBrowseURL() { if (FakeIdGenerator.isFakeId(id)) return "generated from " + getOrigElement() + " " + originalId; return "http://www.openstreetmap.org/" + kind() + "/" + id; } Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Mike Baggaley <mike@tvage.co.uk> Gesendet: Donnerstag, 14. Januar 2021 12:59 An: 'Development list for mkgmap' Betreff: Re: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, I spotted a problem in Element.getBasicLogInformation if it is called on an element that does not have an OSM Id. The attached patch fixes that. The previous version only fixed it in Element.toBrowseURL. Cheers, Mike -----Original Message----- From: Mike Baggaley [mailto:mike@tvage.co.uk] Sent: 13 January 2021 20:53 To: 'Development list for mkgmap' <mkgmap-dev@lists.mkgmap.org.uk> Subject: RE: [mkgmap-dev] improved diagnostics patch v2 HI Gerd, The attached updated patch fixes the problem of a URL for a way having a relation id rather than an way id. It also handles the case where a way is generated without an original OSM id (as happens in the sea generator), so there is no valid URL. Cheers, Mike -----Original Message----- From: Gerd Petermann [mailto:gpetermann_muenchen@hotmail.com] Sent: 13 January 2021 09:58 To: Development list for mkgmap <mkgmap-dev@lists.mkgmap.org.uk> Subject: Re: [mkgmap-dev] improved diagnostics patch v2 Hi Mike, I get some messages which are wrong: FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/1187315 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 instead of FEIN: uk.me.parabola.mkgmap.osmstyle.WrongAngleFixer f:\osm\wildeshausen.o5m: removing obsolete point on almost straight segment in way http://www.openstreetmap.org/way/4611686018427387930 at http://www.openstreetmap.org/?mlat=52.940356&mlon=8.340912&zoom=17 The way in question is w78508173 which is a member of relation 1187315. So, the new code reports the relation id as way id. I also see unexpected changes in the img files. Don't know yet why. I assume toString() is used to identify objects somewhere. Gerd
participants (2)
-
Gerd Petermann
-
Mike Baggaley