General -> Product URL property sometimes not saved
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
General -> Product URL property sometimes not saved
Word size of FreeCAD: 64-bit, Version: 0.18.15780 (Git)
Build type: Release
Branch: master
Hash: f94e76c1116ec3b818961ff65131b3d86fa5b95e
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
The material property General -> Product URL is not saved if the URL contains the character '=':
- add a material, then "use FreeCAD material editor"
- load a FCMat file
- use e.g. this link for the property General -> Product URL
https://www.testtest.ttt/properties.aspx?ArticleID=720
- Save it under a new FCMat file name
- press OK and again click on "use FreeCAD material editor"
- load the just saved FCMat file
result: the value for General -> Product URL is lost, the field is empty
This only happens if the URL contains an equal sign '='
Build type: Release
Branch: master
Hash: f94e76c1116ec3b818961ff65131b3d86fa5b95e
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
The material property General -> Product URL is not saved if the URL contains the character '=':
- add a material, then "use FreeCAD material editor"
- load a FCMat file
- use e.g. this link for the property General -> Product URL
https://www.testtest.ttt/properties.aspx?ArticleID=720
- Save it under a new FCMat file name
- press OK and again click on "use FreeCAD material editor"
- load the just saved FCMat file
result: the value for General -> Product URL is lost, the field is empty
This only happens if the URL contains an equal sign '='
Re: General -> Product URL property sometimes not saved
it is even worse ... for Python 3 builds saving material files is broken at all ...
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.15713 (Git)
Build type: Release
Branch: master
Hash: 93dd00cc3953416bf46fb0a5b7b3c6397df6e4d0
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Switzerland (de_CH)
Code: Select all
Traceback (most recent call last):
File "C:\0_BHA_privat\progr\FreeCAD_0.18.xxxxx_x64_dev_win_Py3Qt5\Mod\Material\MaterialEditor.py", line 451, in savefile
importFCMat.write(filename, d)
File "C:\0_BHA_privat\progr\FreeCAD_0.18.xxxxx_x64_dev_win_Py3Qt5\Mod\Material\importFCMat.py", line 122, in write
for k, i in dictionary.iteritems():
AttributeError: 'dict' object has no attribute 'iteritems'
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.15713 (Git)
Build type: Release
Branch: master
Hash: 93dd00cc3953416bf46fb0a5b7b3c6397df6e4d0
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Switzerland (de_CH)
Re: General -> Product URL property sometimes not saved
changing dict.iteritems() with dict.items() works for both py2 and py3
Re: General -> Product URL property sometimes not saved
Many thanks. I cannot test right now, so the question, if it also fixes the issue I originally reported in this thread:
"result: the value for General -> Product URL is lost, the field is empty
This only happens if the URL contains an equal sign '='"
If not, should I open a bug tracker issue that this won't be forgotten?
Re: General -> Product URL property sometimes not saved
no it does not fix the original one but this https://github.com/FreeCAD/FreeCAD/pull/1966 does See https://github.com/FreeCAD/FreeCAD/pull ... 84c8023711uwestoehr wrote: ↑Mon Feb 11, 2019 9:24 pmMany thanks. I cannot test right now, so the question, if it also fixes the issue I originally reported in this thread:
"result: the value for General -> Product URL is lost, the field is empty
This only happens if the URL contains an equal sign '='"
If not, should I open a bug tracker issue that this won't be forgotten?
Re: General -> Product URL property sometimes not saved
Many, many thanks Bernd for your outstanding work! I am very impressed how quick you fix things.bernd wrote: ↑Mon Feb 11, 2019 11:11 pm no it does not fix the original one but this https://github.com/FreeCAD/FreeCAD/pull/1966 does See https://github.com/FreeCAD/FreeCAD/pull ... 84c8023711
I will test as soon as possible and report back. I had a look at your commits and I think the material editor is now close to be ready for FC 0.18.
Re: General -> Product URL property sometimes not saved
That would be great. The material editor seams not yet used regularly by a lot user ATM. The unit support has been added recently. Before this the material editor was no fun at all in FEM ...
BTW: using the Py3 build is highly appreciated too!
Re: General -> Product URL property sometimes not saved
Here is a first quick feedback (using the conda build) with 4 issues (one mustfix in my opinion):
1. there are issues with the decimal separator. I use Locale: German/Germany (de_DE) on Windows 7. Therefore in all places FC uses the comma as decimal separator. In the material editor however, I see a mixture of dots and comma, see the attached screenshot.
This is the material card for Calculix-steel. So all existing properties use the dot while all new properties I set use the comma.
2. the preview is always empty. In the attached screenshot you see a preview filed but I never managed to see there anything, neither for the predefined materials not by setting up my own materials.
3. in the material property field "Specific Price" I cannot specify a currency unit. So maybe there should be an additional field where one can select a currency.
4. there is a nasty bug with the density:
- load the attached material card "PET.zip" I created today (using FC 0.18.15860)
result: the density is correctly 1380 kg/m³ in the editor
- now press OK
result: in the task panel you see now "1380 kg/mm³" (note the unit)
- now open the material editor
result: you see there now a senselessly high number. And when double-clicking on it you see "13800 kg/m³". So a factor of 10 was added to the original value in the material card.
- Attachments
-
- PET.zip
- (578 Bytes) Downloaded 239 times
-
- MatEditor-feedback.jpg (76.68 KiB) Viewed 23644 times