rebane2001 / matterport-dl

A downloader for matterport virtual tours
The Unlicense
294 stars 75 forks source link

"Model is not available" #55

Open aekramer opened 2 years ago

aekramer commented 2 years ago

I attempted to download this matterport model: https://my.matterport.com/show/?m=BPgscPGiQd3

However, when running the script again afterwards with the webserver, I get the message: "Oops, model not available" (and a link to their troubleshooting page)

Looking at the server.log, I don't really see any 404s besides the favicon, which I doubt would be a big issue? (Btw - the favicon does show in the browser on the webserver)

2022-06-04 13:19:45 INFO     Server started up
2022-06-04 13:19:48 INFO     Redirecting /js/showcase.js => /js/showcase-internal.js as using our internal showcase.js file
2022-06-04 13:19:48 WARNING  404 error: /favicon.ico may not be downloading everything right

I just noticed, the web browser also had a 404 for "message File"

View in browser: http://127.0.0.1:8080
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET / HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /css/showcase.css HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /css/unsupported_browser.css HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /js/browser-check.js HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /js/showcase.js HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /?m=BPgscPGiQd3 HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET //api/v2/users/current HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] code 404, message File not found
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /favicon.ico HTTP/1.1" 404 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /js/136.js HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "POST /api/mp/models/graph HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /fonts/roboto-regular.woff2 HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /locale/messages/strings_nl.json HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:48] "GET /locale/strings.json HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:49] "GET /fonts/roboto-500.woff2 HTTP/1.1" 200 -
127.0.0.1 - - [04/Jun/2022 13:19:49] "GET /fonts/roboto-300.woff2 HTTP/1.1" 200 -

Any hints or tips? Or is this tool simply out of date?

impop commented 2 years ago

Exact same issue here

PaitoAnderson commented 2 years ago

This resolved it for me, thanks @mitchcapper!

impop commented 2 years ago

Likewise. Thanks @mitchcapper

PaitoAnderson commented 2 years ago

@aekramer - maybe just leave open for others to reference?

Mattio1990 commented 2 years ago

What do I need to do? I already downloaded latest tool and still getting same issue?

PaitoAnderson commented 2 years ago

@Mattio1990 - Just add this file graph_posts/GetModelDetails.json below and archive the virtual tour url again.

https://github.com/rebane2001/matterport-dl/blob/bc8c2db9898bfaa9aee700052b3deacaa36595a7/graph_posts/GetModelDetails.json

aekramer commented 2 years ago

Since the issue at hand here seems to be fixed with mitch's update (at least it was for me as well) I think it would be best to close it, and if new issues arrive with the same errors they should probably be addressed seperately. However I can understand if we should keep this open until this his branch is merged into master

mitchcapper commented 2 years ago

You are free to leave it open until the PR is merged in (which will actually automatically close it). Slightly more likely a user seeing this error will see this if its open than closed. If not hopefully they just search:)

As for using this before merge, Paito's method does likely work but we won't officially support this fix until we get everything merged in (I would assume within the next week or two).

DruggedBunny commented 2 years ago

mitchcapper's fix just worked for me -- many thanks!

SCtester commented 2 years ago

The tour I downloaded about a week ago, which I couldn't open due to this issue, was since deleted. So I still have the old file from before this patch, but I can't download it again. I suppose there's nothing that can be done in my situation?

mitchcapper commented 2 years ago

I have not spent the time to debug exactly how matterport reads and uses the data from this file now. I can say it contains several different asset path data parameters that might be hard to recreate otherwise. If the tour is of extreme importance please feel free to contact me per my GH page, but it would would have to be paid work (and you would need to send all the model files you do have).

SCtester commented 2 years ago

Good to know that it might be possible - it's only of mild importance, but I'll keep you in mind for commission in the future if it becomes more important.

mitchcapper commented 2 years ago

In case anyone else goes down this route:

aekramer commented 2 years ago

Reopened until the patch is merged into main

jgreth0 commented 2 years ago

Is it just me, or did the website change again? Even with the PR applied, I'm getting the same error today.

mu-ramadan commented 2 years ago

i'm getting the same error too but if i rerun the download command again without deleting the virtual tour files it's working for like 5 minutes and stopped again

mu-ramadan commented 2 years ago

with this error

GET https://cdn-2.matterport.com/models/f3f89ed41a924b2ab6fb781b0e06911c/assets/dbe5c6e73d5a4e51a1b2f35dae9a70b4_50k.dam?t=2-a6bd55231d4dd32c3de677d47b1a174c1011ddcc-1656672730-1&k= 401

patricknelson commented 2 years ago

Try my branch in the PR here: #65.

I noticed that the main reason why things weren't loading wasn't because of the announced error, but because Matterport's latest code is now issuing additional requests to their graph API server which weren't being fetched/cached in the download, resulting in it just bugging out. So, I've added those + I found new assets were needed (trims), so it's fetching those too.

If you checkout my branch (support-new-graph-posts) it'll work, however it's not fully completed yet. Still need to write up the python code to swap out the references to http://cdn-2.matterport.com inside those newly cached JSON files to instead point to your local server instead. I'm not a python hacker and my computer isn't properly setup for this yet so may need to do that over the weekend instead.

Happy (code) hacking!

luka-tour commented 1 year ago

Which branch should I use, so I don't get this error, because I download official one, then also mu-ramadan and mitchcapper fork and I always get the same error model is not available

mu-ramadan commented 1 year ago

Which branch should I use, so I don't get this error, because I download official one, then also mu-ramadan and mitchcapper fork and I always get the same error model is not available

you should only use 127.0.0.1 8080 as local server or you can change it on the script if you still have same issue send me Email of the Virtual tour URL, I'll try to check

jdstone commented 1 year ago

Apparently this is broken again. :/

I downloaded the GetModelDetails.json file mentioned in this post (above), but now, when running matterport-dl.py https://my.matterport.com/show/?m=87ehWawBGLj, I get the following:

Downloading base page...
https://cdn-2.matterport.com/models/c5e7a343b66b4ec79477fa2b34131e80/assets/~/{filename}?t=2-03483122e8c2c977ce9ebd79873dbe343d6f03a4-1664425250-1
Downloading static assets...
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 207.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 260.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 300.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 309.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 385.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 393.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 521.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 564.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 58.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 633.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 769.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 794.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 934.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 976.js, will download for you though:)
JS FILE EXTRACTED BUT not known, please file a github issue and tell us to add: 995.js, will download for you though:)
Downloading model info...
Downloading images...
Downloading graph model data...
Traceback (most recent call last):
  File "C:\Users\JDStone\Downloads\matterport-dl-main\matterport-dl-main\matterport-dl.py", line 511, in <module>
    initiateDownload(pageId)
  File "C:\Users\JDStone\Downloads\matterport-dl-main\matterport-dl-main\matterport-dl.py", line 388, in initiateDownload
    downloadPage(getPageId(url))
  File "C:\Users\JDStone\Downloads\matterport-dl-main\matterport-dl-main\matterport-dl.py", line 380, in downloadPage
    downloadGraphModels(pageid)
  File "C:\Users\JDStone\Downloads\matterport-dl-main\matterport-dl-main\matterport-dl.py", line 133, in downloadGraphModels
    downloadFileWithJSONPost("https://my.matterport.com/api/mp/models/graph",file_path, GRAPH_DATA_REQ[key], key)
  File "C:\Users\JDStone\Downloads\matterport-dl-main\matterport-dl-main\matterport-dl.py", line 86, in downloadFileWithJSONPost
    resp = urllib.request.urlopen(req, body_bytes)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 223, in urlopen
    return opener.open(url, data, timeout)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 532, in open
    response = meth(req, response)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 570, in error
    return self._call_chain(*args)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 504, in _call_chain
    result = func(*args)
  File "C:\Users\JDStone\AppData\Local\Programs\Python\Python36\lib\urllib\request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 500: Internal Server Error

I've also attached the run-report.log. run_report.log

christianepeters commented 1 year ago

Using version in @mu-ramadan 's fork fixes the issue for me https://github.com/mu-ramadan/matterport-dl.

grinco commented 1 year ago

Using version in @mu-ramadan 's fork fixes the issue for me https://github.com/mu-ramadan/matterport-dl.

can confirm!

dazzsser commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working?

Thanks!

grinco commented 1 year ago

It's hard coded in a few of the javascripts, assuming the downloader replaces it with full url as relative paths might not be supported.

dazzsser commented 1 year ago

It's hard coded in a few of the javascripts, assuming the downloader replaces it with full url as relative paths might not be supported.

Ah yep makes sense, would there be any work arounds to get it working on a public IP?

mu-ramadan commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working?

Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

dazzsser commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver

And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()".

httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS)

Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

luka-tour commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver

And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()".

httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS)

Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

Hi,

Can you maybe share your matterportl-dl.py because I am trying to do like you, but I am messing something. I can see the tour if I use a public ip, but not with a domain, and I would prefer that. Thanks in advance for your help

dazzsser commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()". httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS) Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

Hi,

Can you maybe share your matterportl-dl.py because I am trying to do like you, but I am messing something. I can see the tour if I use a public ip, but not with a domain, and I would prefer that. Thanks in advance for your help

If you are using https, ensure that you add https:// to the URL. If you are doing this without SSL, then there shouldn't be any difference between using a public IP or domain as long as you specify the domain:port when running the webserver

dazzsser commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()". httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS) Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

Hi, Can you maybe share your matterportl-dl.py because I am trying to do like you, but I am messing something. I can see the tour if I use a public ip, but not with a domain, and I would prefer that. Thanks in advance for your help

If you are using https, ensure that you add https:// to the URL. If you are doing this without SSL, then there shouldn't be any difference between using a public IP or domain as long as you specify the domain:port when running the webserver

link to the .py file below https://we.tl/t-kG4zZpDNma

bmilla2009 commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()". httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS) Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

Hi, Can you maybe share your matterportl-dl.py because I am trying to do like you, but I am messing something. I can see the tour if I use a public ip, but not with a domain, and I would prefer that. Thanks in advance for your help

If you are using https, ensure that you add https:// to the URL. If you are doing this without SSL, then there shouldn't be any difference between using a public IP or domain as long as you specify the domain:port when running the webserver

link to the .py file below https://we.tl/t-kG4zZpDNma

Could you share the link again it expired. THANK YOU!

bmilla2009 commented 1 year ago

Hi guys, @mu-ramadan 's fork is working for me when I use 127.0.0.1:8080 as the address. However when I try to use the public IP address of my machine, as well as changing the IP address from 127.0.0.1:8080 to public IP:port on Line 300 of matterport-dl.py, I am still running into the Model Not Available error. Is there anything else that I need to change to get this working? Thanks!

after you change the ip address on matterpor-dl.py you need to run download command again

Thanks for all the help guys. For anyone interested, I have managed to achieve https (TLS) by adding the following code to matterport-dl.py. We will require import ssl: import ssl, socketserver And we need to add this code between "httpd = HTTPServer((sys.argv[2], int(sys.argv[3])), OurSimpleHTTPRequestHandler)" and "httpd.serve_forever()". httpd.socket = ssl.wrap_socket(httpd.socket, server_side=True, certfile='/pathtofullchain.pem', keyfile="/pathtoprivkey.pem", ssl_version=ssl.PROTOCOL_TLS) Remember to add the domain name and port (ie domain.com:443) on Line 300 of matterport-dl.py, and re-run the download command. When starting the web-server use the domain name and port as specified instead of 127.0.0.1:8080. This is how I have gotten it to work for me.

Hi,

Can you maybe share your matterportl-dl.py because I am trying to do like you, but I am messing something. I can see the tour if I use a public ip, but not with a domain, and I would prefer that. Thanks in advance for your help

Did you ever download the matterport-dl.py for https? if so could you share it? Thanks!

IAMCALM24 commented 5 months ago

Using version in @mu-ramadan 's fork fixes the issue for me https://github.com/mu-ramadan/matterport-dl.

Hey guys I'm trying to get matterport-dl.py working, and I downloaded the new @mu-ramadan files, but it's still not working for me. I get the following errors:

Downloading base page...

Downloading static assets... JS FILE EXTRACTED, 217.js JS FILE EXTRACTED, 231.js JS FILE EXTRACTED, 27.js JS FILE EXTRACTED, 324.js JS FILE EXTRACTED, 325.js JS FILE EXTRACTED, 327.js JS FILE EXTRACTED, 378.js JS FILE EXTRACTED, 401.js JS FILE EXTRACTED, 425.js JS FILE EXTRACTED, 477.js JS FILE EXTRACTED, 625.js JS FILE EXTRACTED, 648.js JS FILE EXTRACTED, 653.js JS FILE EXTRACTED, 672.js JS FILE EXTRACTED, 679.js JS FILE EXTRACTED, 746.js JS FILE EXTRACTED, 782.js JS FILE EXTRACTED, 858.js JS FILE EXTRACTED, 948.js JS FILE EXTRACTED, 958.js JS FILE EXTRACTED, 973.js Downloading model info... Downloading images... Downloading graph model data... Patching graph_GetModelDetails.json URLs Traceback (most recent call last): File "C:\Users\insuc\OneDrive\Documents\Python\matterport-dl-main\matterport-dl.py", line 690, in initiateDownload(pageId) File "C:\Users\insuc\OneDrive\Documents\Python\matterport-dl-main\matterport-dl.py", line 555, in initiateDownload downloadPage(getPageId(url)) File "C:\Users\insuc\OneDrive\Documents\Python\matterport-dl-main\matterport-dl.py", line 545, in downloadPage patchGetModelDetails() File "C:\Users\insuc\OneDrive\Documents\Python\matterport-dl-main\matterport-dl.py", line 314, in patchGetModelDetails with open(f"api/mp/models/graph_GetModelDetails.json", "r", encoding="UTF-8") as f: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ FileNotFoundError: [Errno 2] No such file or directory: 'api/mp/models/graph_GetModelDetails.json'

However, when I look at the folder GetModelDetails.json is already there. Is there something I am missing? It's not working for the 127.0.0.1:8080 address as well

IAMCALM24 commented 5 months ago

In case anyone is interested in the full error report. Matterport.txt