View Issue Details

IDProjectCategoryView StatusLast Update
0001795ArchBugpublic2015-01-19 15:53
Reportershoogen Assigned Toyorik  
PrioritynoneSeveritymajorReproducibilityhave not tried
Status closedResolutionfixed 
PlatformLinux 
Product Version0.15 
Target Version0.15Fixed in Version0.15 
Summary0001795: adapt IFC exporters to accept unicode filenames
Descriptionifcopenshell does not use the python open function. instead it processes the file name argument in C code.
Either ifcopenshell needs to be changed to accept unicode filenames or the Arch module needs to do the conversion.
The solution should work with both versions of IFC exporters and with python 2 and 3.
Steps To Reproducehttp://forum.freecadweb.org/viewtopic.php?f=23&t=7222&p=66507#p66488
Additional Informationto get the old behavior the filename could be converted to utf using
>>> if isinstance(filename,unicode): filename=filename.encode('utf8')
for filesystems that don't use utf8 the following workaround should provide better results
>>> if isinstance(filename,unicode):
... import sys #workaround since ifcopenshell currently can't handle unicode filenames
... filename=filename.encode(sys.getfilesystemencoding())
>>>
TagsNo tags attached.
FreeCAD Information

Relationships

related to 0001027 closedshoogen FreeCAD UTF-8 encoded PyString objects are used instead of unicode objects to pass unicode data to the python interpreter 
related to 0000995 closedyorik FreeCAD Python3 compatibility (Ongoing) 
child of 0001763 closedshoogen FreeCAD use UTF8 for filenames 

Activities

yorik

2014-10-22 12:17

administrator   ~0005246

I'll have a look with the ifcopenshell developer if he can do something about it, otherwise we can adopt this solution...

yorik

2015-01-19 15:53

administrator   ~0005672

Unicode support is part of a biggest issue in IfcOpenShell and probably won't be worked out anytime soon, so, since this is working now, I think we can close this report... Reopen if needed!

Related Changesets

FreeCAD: master 2836f4cb

2014-11-02 18:47:29

yorik

Details Diff
Arch: Provisorily implemented workaround for utf8 paths and ifcopenshell - issue 0001795 Affected Issues
0001795
mod - src/Mod/Arch/importIFC.py Diff File

Issue History

Date Modified Username Field Change
2014-10-22 07:30 shoogen New Issue
2014-10-22 07:30 shoogen Status new => assigned
2014-10-22 07:30 shoogen Assigned To => yorik
2014-10-22 07:31 shoogen Relationship added child of 0001763
2014-10-22 07:32 shoogen Relationship added related to 0001027
2014-10-22 08:17 shoogen Relationship added related to 0000995
2014-10-22 12:17 yorik Note Added: 0005246
2014-11-02 18:01 yorik Changeset attached => FreeCAD Master master 2836f4cb
2015-01-19 15:53 yorik Note Added: 0005672
2015-01-19 15:53 yorik Status assigned => closed
2015-01-19 15:53 yorik Resolution open => fixed
2015-01-19 15:53 yorik Fixed in Version => 0.15