opensourceBIM / BIMserver

The open source BIMserver platform
GNU Affero General Public License v3.0
1.56k stars 610 forks source link

Error in Checkin #421

Closed bakongi closed 7 years ago

bakongi commented 8 years ago

Maybe the problem in using a 32-bit in a place where a to large value can be placed

bimvie ws 1

ARC.zip

rubendel commented 8 years ago

Thanks for sending the file, the problem is indeed that the number cannot be stored in an Integer (32bit). I have improved the error message a bit so that it is more clear on this.

phuck7 commented 8 years ago

Dear all, I got the same "problems". This type of problems comes with ifc files edited with Allplan...

rubendel commented 8 years ago

Just to be clear, these files are invalid, and we will not change BIMserver in a way that it will accept these files. If we do that we might just as well not use a standard. Please contact your CAD vendor to fix this issue.

bakongi commented 8 years ago

I think that the best way is to give it a chance to load but with showing a messages about errors or warnings. imho

bakongi commented 7 years ago

Hi Ruben! Another one...

bimvie ws - add project

VK.zip

rubendel commented 7 years ago

This, in my opinion is caused by an ambiguity in the IFC specifcation. I have described this a little bit more here: https://github.com/opensourceBIM/BIMserver/wiki/Problems-parsing-IFC

raindog commented 7 years ago

Just to be clear, these files are invalid, and we will not change BIMserver in a way that it will accept these files. If we do that we might just as well not use a standard. Please contact your CAD vendor to fix this issue.

Ruben can you point me to the part of the standard stating that this number must be a 32 bit integer? I'm in contact with the CAD vendor, trying to explain the issue.

I've found this page. Is that "Integer" green box pointed by the "RelatingPriorities"/"RelatedPriorities"? Tia

rubendel commented 7 years ago

http://www.buildingsmart-tech.org/ifc/IFC2x4/rc2/html/schema/ifcsharedbldgelements/lexical/ifcrelconnectspathelements.htm

Both RelatingPriorities and RelatedPriorities are defined to be a list of integer

I have looked into the ISO 10303-21-2002 specification and it actually also does not define what the meaning of Integer is. So I was wrong in saying that they are defined to be 32-bit. The document actually contains a question that asks what the limits of integer are, but it does not answer it...

I'll try and get a hold of the 2016 standard, maybe the definitions have been improved (doubt it). At the moment I think we should convert to 64-bit, which will have big implications so I'd rather do it before the final 1.5/2.0 release of BIMserver. Another option would be to store the values as Strings, so they are sort of without limit, but that's kind of ugly.

Thanks for pushing me to look into it more.

rubendel commented 7 years ago

Integer values Thanks both @bakongi and @raindog, I was wrong in my assumption of the meaning of the word integer in the IFC/STEP spec. This has been fixed now in git head (all integer fields are now implemented as java long, which is 64bit). Of cource you could still run into problems when using numbers that cannot be stored in a 64bit signed int. but I don't think there will be any IFC exporters doing that.

Order of parsing reverse solidus S and reverse solidus X/X2/X4 I have also gone ahead and made the other example (VK) work. Although the specs are still not clear on this in my opinon, the parser will now try 2 versions, the first one to not give an error will be used. The two diferent orders that are tried are: X, X2, X4, S and S, X, X2, X4

arc vk

bakongi commented 7 years ago

@rubendel Thank you too!

raindog commented 7 years ago

@rubendel Great! Thank you! ... I'm trying to figure out if it is feasible for me to backport the (huge) change into the stable release...

rubendel commented 7 years ago

The 64 to 32 bit thing I don't think will be worth the effort. For what it is worth we are planning a release of 1.5/2.0 (version numbering to be decided) in two weeks.

raindog commented 7 years ago

Great news Ruben! I'm trying to upgrade a 1.4 test db to the latest 1.5.64 bimserver version. Can you confirm me that they are not auto migratable? When I start the latest version pointing to a 1.4 db instance I get a java.lang.IllegalStateException: There is 1 existing transaction opened against the Environment. error.

rubendel commented 7 years ago

Yes 1.3 cannot upgrade automatically to 1.4 and 1.4 also not to 1.5 (which has not been released yet).