<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FR-CA" link="#0563C1" vlink="#954F72">
<img alt="Intranet logo" src="https://mffp.gouv.qc.ca/documents/ministere/piv/mffp.png">
<div>
<div class="WordSection1">
<p class="MsoNormal">Hi Devs,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I had a surprising issue with a specific vector layer and a clip operation. Validity check of the geometries seem to be done differently if native:clip is used inside a processing script or manually through the GUI as a vector layer containing
a linestring with duplicate node like <span style="font-size:10.0pt;font-family:"Courier New"">
LINESTRING ((0 0, 1 0, 1 0))</span> won't cause an issue when the clip is done with the GUI but will halt if done inside a processing script (on QGIS 3.22.6).<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Also, if I run <b><i>qgis:checkvalidity</i></b> with the <b>
GEOS</b> method, no error is found, but if I run it with the <b>QGIS</b> method, it finds one error (<i>line 1 contains 2 duplicate nodes starting at vertex 2</i>). So here are my questions: what exactly is checked when using the GEOS method and what is checked
using the QGIS method? Also, do all processing tools (qgis: and native: ones) use the same kind of check?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I didn't find anywhere the details of what would be considered an error according to the "QGIS spec". Is it documented somewhere or do I need to look for hints inside the source code? As for the GEOS method, I only found some error examples
in the PostGIS documentation and in a FME page (<a href="https://community.safe.com/s/article/invalid-ogc-geometry-examples">https://community.safe.com/s/article/invalid-ogc-geometry-examples</a>). Is there an official documentation of what geometries are
invalid regarding GEOS?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks a lot for any pointer<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto"><span style="color:black;mso-fareast-language:FR-CA"><o:p> </o:p></span></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto"><b><span style="font-size:12.0pt;font-family:"Arial",sans-serif;color:black;mso-fareast-language:FR-CA">Jean-François Bourdon, ing.f.</span></b><span style="font-size:9.0pt;font-family:"Arial",sans-serif;color:black;mso-fareast-language:FR-CA"><o:p></o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#2E74B5;mso-fareast-language:FR-CA">Analyste en télédétection</span></b><span style="font-size:10.0pt;font-family:"Arial",sans-serif;mso-fareast-language:FR-CA"><br>
<b><span style="color:#2E74B5">Direction des inventaires forestiers</span></b><br>
<b><span style="color:#2E74B5">Ministère des Forêts, de la Faune et des Parcs</span></b><br>
<span style="color:#2E74B5">5700, 4<sup>e</sup> Avenue Ouest, local A-108</span><br>
<span style="color:#2E74B5">Québec (Québec) G1H 6R1</span><br>
<span style="color:#2E74B5">Téléphone : 418 627-8669, poste 704304</span><br>
<b><u><span style="color:#2E74B5">jean-francois.bourdon@mffp.gouv.qc.ca</span></u></b>
<br>
</span><span style="mso-fareast-language:FR-CA"><a href="http://www.mffp.gouv.qc.ca/accueil.jsp"><b><span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:#2E74B5">mffp.gouv.qc.ca</span></b></a></span><span style="mso-fareast-language:FR-CA"><o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</div>
</body>
</html>