Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"No importable file found" on URL returning an OBJ file #432

Open
EGI-ILM opened this issue Nov 2, 2023 · 3 comments
Open

"No importable file found" on URL returning an OBJ file #432

EGI-ILM opened this issue Nov 2, 2023 · 3 comments
Labels

Comments

@EGI-ILM
Copy link

EGI-ILM commented Nov 2, 2023

I am getting a "No importable file found." error and I believe that it is because the URL of the file has no extension (which is a common thing to do).

So my URL looks like:

https://data.com/models/92178219/download

Which returns

HTTP/2 200 OK
Content-Disposition: attachment; filename="statue.obj"
Content-Length: 105907
Content-Type: application/octet-stream
...

I believe the error comes from the fact that the library attempts to get the extension of the file from the URL instead of from the filename indicated when downloading the actual data.

@EGI-ILM EGI-ILM added the engine label Nov 2, 2023
@kovacsv
Copy link
Owner

kovacsv commented Nov 15, 2023

Yes, the file name must be in the url.

@EGI-ILM
Copy link
Author

EGI-ILM commented Nov 15, 2023

In the case of URLs, the current behaviour may not always work, as it is common that URLs do not include filenames, and some systems simply do not let you manipulate or provide the filename in the URL.

Maybe anchors provide a workaround to the issue, but would it be desirable to contemplate the filename attribute of Content-Disposition to identify the file format and, if this does not exist, then use the URL as a last resource? Maybe this can stay in the TO-DO list of improvements.

@ubemacapuno
Copy link

I'm very glad I found this issue as I was running into the same thing. I ended up using anchors as mentioned above and it's working fine now.

This library is awesome @kovacsv !!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants