<div dir="ltr">Hi,<div><br></div><div>For reference, <a href="https://github.com/qgis/QGIS/pull/6050">https://github.com/qgis/QGIS/pull/6050</a></div><div><br></div><div>As pointed out, Feature freeze != API freeze.</div><div><br></div><div>Many issues are still open here</div><div><a href="https://github.com/qgis/qgis3.0_api/issues">https://github.com/qgis/qgis3.0_api/issues</a></div><div><br></div><div>Best,</div><div><br></div><div>Denis<br><br><div class="gmail_quote"><div dir="ltr">Le lun. 15 janv. 2018 à 13:18, Andreas Neumann <<a href="mailto:a.neumann@carto.net">a.neumann@carto.net</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>Hi,</p>
<p>oh - thanks, Etienne and Alessandro. If this change is that recent, than it explains why the API doc and the API break document doesn't mention it: <a href="https://qgis.org/api/api_break.html" target="_blank">https://qgis.org/api/api_break.html</a></p>
<p>But - aren't we in hard freeze (no more API changes) now since a few days already?</p>
<p>Being confused ....</p></div><div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>Andreas</p></div><div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>On 2018-01-15 18:14, Etienne Trimaille wrote:</p>
<blockquote type="cite" style="padding:0 0.4em;border-left:#1010ff 2px solid;margin:0">
<div dir="ltr">pendingFields is gone this morning: <a href="https://github.com/qgis/QGIS/pull/6050" rel="noopener noreferrer" target="_blank">https://github.com/qgis/QGIS/pull/6050</a>
<div>Maybe just use `fields()` ?</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2018-01-15 20:10 GMT+03:00 Andreas Neumann <span><<a href="mailto:a.neumann@carto.net" target="_blank">a.neumann@carto.net</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="font-size:10pt;font-family:Verdana,Geneva,sans-serif">
<p>Hi,</p>
<p>I am trying to fix some Python code that worked before, but not anymore due to API changes in master meanwhile.</p>
<p>I am getting a reference to a layer by name and then want to query the 'pendingFields'. Here is the code I use:</p>
<p>---------------------</p>
<p>LayerParcels= QgsProject.instance().layerStore().mapLayersByName('Parcels')[0]</p>
<p>newParcel = QgsFeature()</p>
<p><span>newParcel </span>.setFields(<span>LayerParcels</span>.pendingFields())</p>
<p>-------------------------</p>
<p>The first two lines seem to work, but the third line triggers an error:</p>
<p>AttributeError: 'QgsVectorLayer' object has no attribute 'pendingFields'</p>
<p>Why is that?</p>
<p>This code worked a few weeks before and the 'pendingFields' - according to <a href="https://qgis.org/api/classQgsVectorLayer.html" rel="noopener noreferrer" target="_blank">https://qgis.org/api/classQgsVectorLayer.html</a> still exists?</p>
<p>What is wrong with my code?</p>
<p>Thanks for any hints!</p>
<p>Andreas</p>
<p><br></p>
</div>
<br>_______________________________________________<br> QGIS-Developer mailing list<br> <a href="mailto:QGIS-Developer@lists.osgeo.org" target="_blank">QGIS-Developer@lists.osgeo.org</a><br> List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noopener noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br> Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noopener noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></blockquote>
</div>
</div>
</blockquote>
<p><br></p>

</div>
_______________________________________________<br>
QGIS-Developer mailing list<br>
<a href="mailto:QGIS-Developer@lists.osgeo.org" target="_blank">QGIS-Developer@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></blockquote></div></div></div>