'NoneType' object has no attribute 'select'

489 views
Skip to first unread message

Sepideh N

unread,
May 21, 2017, 12:21:42 AM5/21/17
to dxf2gcode-dev
when I run program on MAC by 
python3 dxf2gcode.py
 after selecting file menu and open a dxf file, I get below error every time:
'NoneType' object has no attribute 'select'

even If I do not open a file but click on the screen of program, I get below error:
AttributeError: 'NoneType' object has no attribute 'selectedItems'

when I run it on ubuntu 16.04 I got below error:
Segmentation fault (core dumped)

Can anyone help me with these problems?



Thanks

Chrisko

unread,
May 21, 2017, 3:18:47 PM5/21/17
to dxf2gcode-dev

Hi Sepideh,

first of all: Please open only one post for the same problem. This is producing extra work for us all if you open several ones. 

I do not own any MAC machine, therefore i am not able to test it here. I can't understand where this failure may come from and your not attached core dumped is not helping anything here ;-) ... 

Can you give us a bit more information. 

I tested under windows and development environment also. Did you try older versions also or which dxf2gcode versions do have this behavior?

regards
Christian 

Sepideh N

unread,
May 22, 2017, 2:32:59 PM5/22/17
to dxf2gcode-dev
hello 
this is the last version of dxf2gcode
 
I tested it under windows with "python dxf2gcode.py" command, and I got error again :( 

Traceback (most recent call last):
  File "C:\Users\Sepideh\Desktop\dxf to gcode\dxf2gcode-sourcecode-c5e511a2cc6ca
3ab84187056aeb3a1f85027d63e\source\gui\treeview.py", line 280, in selectionChang
ed
    self.selectionChangedcallback(self, selected, deselected)
  File "C:\Users\Sepideh\Desktop\dxf to gcode\dxf2gcode-sourcecode-c5e511a2cc6ca
3ab84187056aeb3a1f85027d63e\source\gui\treehandling.py", line 1104, in actionOnS
electionChange
    selectionLayer.select(itemLayerSelection, QItemSelectionModel.Deselect | QIt
emSelectionModel.Rows)
AttributeError: 'NoneType' object has no attribute 'select'






Christian Kohlöffel

unread,
May 22, 2017, 5:02:11 PM5/22/17
to dxf2gc...@googlegroups.com

Hi Sepideh,

 

This is really extreme strange. Just tested this again, but I do not see any issue with dxf2gcode and also cannot reproduce the error. Please test the windows exe file too if you see the same problems there. What is the common thing you did on your MAC and windows. Are you using the same python and pyQT versions there? Maybe its linked to a dedicated new python or pyQt version. Can you try another ones?

I can only guess where this failure is coming from and I think it’s linked to pyQt and the GUI. Does any one of the other developers see the same failure there?

 

Regards

Christian

Sepideh N

unread,
May 24, 2017, 1:26:26 PM5/24/17
to dxf2gcode-dev
hello

I tested the windows exe file and I did not get the same error. but I need to run python program because I want to debug it and extract some piece of code (just converting dxf to gcode)
I am using following versions:
python  3.5.3
sip-4.19.2
PyQt5_gpl-5.8.2

thanks

Sepideh N

unread,
May 24, 2017, 3:31:36 PM5/24/17
to dxf2gcode-dev
Hello again
I decided not to use gui and now I run below command:
>python dxf2gcode.py 12.dxf -e 12.ngc -q
and I change window.load() to window.load(plot=False)

I got bellow error :

Traceback (most recent call last):
  File "dxf2gcode.py", line 1228, in <module>
    window.myExportShapes(None, options.export_filename)
  File "dxf2gcode.py", line 1095, in myExportShapes
    self.TreeHandler.updateExportOrder()
  File "C:\Users\Sepideh\Desktop\dxf to gcode\dxf2gcode-sourcecode-c5e511a2cc6ca
3ab84187056aeb3a1f85027d63e\source\gui\treehandling.py", line 547, in updateExpo
rtOrder
    i = self.layer_item_model.rowCount(QtCore.QModelIndex())
AttributeError: 'NoneType' object has no attribute 'rowCount'


Thanks

Christian Kohlöffel

unread,
May 24, 2017, 4:07:43 PM5/24/17
to 'Timo Birnschein' via dxf2gcode-dev
I think this is an installation problem or not compatible pyQt version. Please try an other one.
Regards Christian

--
--
You received this message because you subscribed to the Google
Groups-group "dxf2gcode-dev".
To post a message, send mail to dxf2gc...@googlegroups.com
To unsubscribe, send mail to dxf2gcode-dev+unsubscribe@googlegroups.com
See http://groups.google.de/group/dxf2gcode-dev?hl=en for more options
and the dxf2gcode project page at http://code.google.com/p/dxf2gcode/
---
You received this message because you are subscribed to the Google Groups "dxf2gcode-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dxf2gcode-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Sepideh N

unread,
May 26, 2017, 2:21:24 AM5/26/17
to dxf2gcode-dev
I installed bellow packages and my problem solved
PyQt5-5.4.1-gpl-Py3.4-Qt5.4.1-x32
python-3.4.4

Thanks Christian for your help

Reply all
Reply to author
Forward
0 new messages