I am trying to add a point by using the pyqgis code below:
layer = iface.activeLayer() # point layer layer.startEditing() iface.actionAddFeature().trigger()
Then the marker becomes add feature symbology to add a point. When I click the canvas it gives me the error which says
"Add Feature: Wrong editing tool, cannot apply the 'capture polygon' tool on this vector layer in picture" in the picture.
If I close and re-open QGIS it works. I guess the reason is making editing processes on polygon type vector layers. After adding point again by using the code it gives that error. It seems like editing polygon stays open. But I close that by using
layer.commitChanges(). How can I solve that problem?