[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830935#comment-17830935 ] Hudson commented on TIKA-4223: -- SUCCESS: Integrated in Jenkins build Tika » tika-main-jdk11 #1575 (See [https://ci-builds.apache.org/job/Tika/job/tika-main-jdk11/1575/]) TIKA-4223 -- add detection of stl (#1691) (github: [https://github.com/apache/tika/commit/9d45b69dab2016342e44ee2b8bf5ed508676b38b]) * (edit) tika-core/src/test/java/org/apache/tika/TikaDetectionTest.java * (edit) tika-parsers/tika-parsers-standard/tika-parsers-standard-package/src/test/java/org/apache/tika/mime/TestMimeTypes.java * (edit) tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml * (add) tika-parsers/tika-parsers-standard/tika-parsers-standard-package/src/test/resources/test-documents/testSTL-binary.stl * (add) tika-parsers/tika-parsers-standard/tika-parsers-standard-package/src/test/resources/test-documents/testSTL-ascii.stl > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Fix For: 2.9.2, 3.0.0 > > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830911#comment-17830911 ] ASF GitHub Bot commented on TIKA-4223: -- tballison merged PR #1691: URL: https://github.com/apache/tika/pull/1691 > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830910#comment-17830910 ] Tim Allison commented on TIKA-4223: --- Thank you [~nick]! I was hoping you'd have a chance to review. > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830867#comment-17830867 ] Nick Burch commented on TIKA-4223: -- A lot of the early file extension allocations were taken from the HTTPD mime magics, which for obscure formats is unlikely to be representative of use today. So, for something like this, I'm +1 to moving the glob to a more common/popular format that also shares the same extension > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830860#comment-17830860 ] Tim Allison commented on TIKA-4223: --- So, the one microsoft stl that I can find online: http://ctldl.windowsupdate.com/msdownload/update/v3/static/trustedr/en/authrootstl.cab is the wrapper. The stl file is actually a {{application/pkcs7-signature}}. Further, when I google or duckduckgo "stl" and file format, the answer is far and away this shape format, not the vnd.ms-pki.stl. So, I propose, moving the glob for ".stl" from vnd.ms-pki.stl to {{model/x.stl-binary}}. > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830723#comment-17830723 ] Tim Allison commented on TIKA-4223: --- Maybe? This suggests one of the ms pki cert family? https://help.sap.com/docs/CX_NG_SALES/ea5ff8b9460a43cb8765a3c07d3421fe/7b2aeb2b2a9446259246e0ff15a823c4.html > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830707#comment-17830707 ] Robin Schimpf commented on TIKA-4223: - application/vnd.ms-pki.stl might just be an alias (or older mime type) for the binary STL format. Found this site ([https://www.westaflex.com/support/dokumente/Dichtung)] where the file is listed with the mime type. Downloading and inspecting it it is the binary STL format. > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830700#comment-17830700 ] ASF GitHub Bot commented on TIKA-4223: -- tballison opened a new pull request, #1691: URL: https://github.com/apache/tika/pull/1691 Thanks for your contribution to [Apache Tika](https://tika.apache.org/)! Your help is appreciated! Before opening the pull request, please verify that * there is an open issue on the [Tika issue tracker](https://issues.apache.org/jira/projects/TIKA) which describes the problem or the improvement. We cannot accept pull requests without an issue because the change wouldn't be listed in the release notes. * the issue ID (`TIKA-`) - is referenced in the title of the pull request - and placed in front of your commit messages surrounded by square brackets (`[TIKA-] Issue or pull request title`) * commits are squashed into a single one (or few commits for larger changes) * Tika is successfully built and unit tests pass by running `mvn clean test` * there should be no conflicts when merging the pull request branch into the *recent* `main` branch. If there are conflicts, please try to rebase the pull request branch on top of a freshly pulled `main` branch * if you add new module that downstream users will depend upon add it to relevant group in `tika-bom/pom.xml`. We will be able to faster integrate your pull request if these conditions are met. If you have any questions how to fix your problem or about using Tika in general, please sign up for the [Tika mailing list](http://tika.apache.org/mail-lists.html). Thanks! > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830675#comment-17830675 ] Tim Allison commented on TIKA-4223: --- Even worse, there are two other file formats that can use *.stl. And Tika does not allow for more than one file type per glob. :( :( application/x-ebu-stl (this at least has magic) application/vnd.ms-pki.stl (we don't currently have magic for this one...don't know if it exists). > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830671#comment-17830671 ] Tim Allison commented on TIKA-4223: --- Yikes, y, no magic for the binary. :( https://www.loc.gov/preservation/digital/formats/fdd/fdd000505.shtml http://formats.kaitai.io/stl/index.html > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830607#comment-17830607 ] Robin Schimpf commented on TIKA-4223: - If I understand the Wikipedia article correct the ASCII file has to start with "solid". The text afterwards is the model name. So this would be flexible. Also the "OpenSCAD Model" in the binary file seems to be the model name. Wikipedia mentions a header of 80 bytes but there seems to be no magic bytes present for detection. So maybe the only way would be the file ending? > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Improvement >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)
[jira] [Commented] (TIKA-4223) STL file exported with OpenSCAD not detected correctly
[ https://issues.apache.org/jira/browse/TIKA-4223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17830577#comment-17830577 ] Tim Allison commented on TIKA-4223: --- I'm guessing we can rely on the magic in these examples? "OpenSCAD Model" for the binary and "solid OpenSCAD_Model" for the text? Or is there some flexibility? > STL file exported with OpenSCAD not detected correctly > -- > > Key: TIKA-4223 > URL: https://issues.apache.org/jira/browse/TIKA-4223 > Project: Tika > Issue Type: Bug >Affects Versions: 2.9.1 >Reporter: Robin Schimpf >Priority: Major > Attachments: linear_extrude_ascii.stl, linear_extrude_binary.stl > > > STL files can be in ASCII or in binary format. Exporting this file > ([https://github.com/openscad/openscad/blob/master/examples/Basics/linear_extrude.scad)] > with OpenSCAD into STL the ASCII result file is detected as text/plain. > Also the binary STL is detected with application/vnd.ms-pki.stl which differs > from the model/stl mime-type Wikipedia lists for those files. > > Used commands for attached files > {code:java} > openscad.exe --export-format asciistl -o result\linear_extrude_ascii.stl > examples\Basics\linear_extrude.scad {code} > {code:java} > openscad.exe --export-format binstl -o result\linear_extrude_binary.stl > examples\Basics\linear_extrude.scad > {code} > Refs: > https://en.wikipedia.org/wiki/STL_(file_format) -- This message was sent by Atlassian Jira (v8.20.10#820010)