Possible solution for "TypeError: coercing to Unicode: .. in halcompile"
20 Apr 2018 15:40 #109343
by CorK
Hi there,
I had some problems with compiling my own HAL-component. Besides finding that 'comp' was renamed to 'halcompile', I stepped through the halcompile-script (i.e. added output messages), because I did not have any unicode-thing in my code.
I found that the Error ("TypeError: coercing to Unicode: need string or buffer, NoneType found") hides all resonable Errormessages from halcompile in case that no outfile is opened under this variable' name.
It can be fixed:
add "if outfile != None:" between "try:" and "os.unlink(outfile)" in halcompile: line 1410
regards
CorK
I had some problems with compiling my own HAL-component. Besides finding that 'comp' was renamed to 'halcompile', I stepped through the halcompile-script (i.e. added output messages), because I did not have any unicode-thing in my code.
I found that the Error ("TypeError: coercing to Unicode: need string or buffer, NoneType found") hides all resonable Errormessages from halcompile in case that no outfile is opened under this variable' name.
It can be fixed:
add "if outfile != None:" between "try:" and "os.unlink(outfile)" in halcompile: line 1410
regards
CorK
Please Log in or Create an account to join the conversation.
26 Apr 2018 12:47 #109650
by andypugh
Replied by andypugh on topic Possible solution for "TypeError: coercing to Unicode: .. in halcompile"
Could you put this info in the bug-tracker?
github.com/LinuxCNC/linuxcnc/issues
github.com/LinuxCNC/linuxcnc/issues
Please Log in or Create an account to join the conversation.
Time to create page: 0.066 seconds