[Interest] I feel stupid: QStandardItem::insertRows: Ignoring duplicate insertion of item

Frank Rueter | OHUfx frank at ohufx.com
Wed Apr 26 09:50:54 CEST 2017


Hi,

I seem to run into this issue a lot and I don't get why:
I have a list of sub-classed QStandardItems that another processor 
generated, and I want to add them to a QStandardItemModel like this:

for item in myItemList:
     self.model.appendRow(item)

The model is empty and hasn't been used at this point. Yet I get none of 
my items but one of those errors for each item:
     QStandardItem::insertRows: Ignoring duplicate insertion of item

I know I should know this but I can't figure out why this is happening. 
Is there something special I need to do when subclassing QStandardItem?


Cheers,
frank

-- 
<http://www.nukepedia.com> 		

over 1,000 free tools for Nuke <http://www.nukepedia.com>

<https://vimeo.com/channels/nukepedia/165747936> 		

full access from within... coming soon 
<https://vimeo.com/channels/nukepedia/165747936>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170426/74267d5b/attachment.html>


More information about the Interest mailing list