Gazer - Cannot export Dashboard from folder

Hello,

Need your help. I run this command below but with error. It used to work well.

C:\Users\username>gzr space export 1093 --host myhosturl: --no-verify-ssl --zip demo.zip
Error querying query(12345)
(GET https://myhosturl:19999/api/4.0/queries/12345 : 404 - Not found
// See: https://cloud.google.com/looker/docs/r/err/4.0/404/get/queries/:query_id 
// And: https://marketplace-api.looker.com/errorcodes/404.md )
I find there is a zip file generated in my local folder however, there is No dashboard json file, I only see some Look json files and one folder json file,
by the way, when I run "gzr user me" with the same host below, it is working fine.
Please advise @Dr__Strangelove 

0 10 158
10 REPLIES 10

Hey @skywalker !
Your question is related to Gazer, but I would recommend you to use in this case Looker Deployer (another third party tool) to export and import not only one dashboard but you can select to download several folders, subfolders or dashboards.
You can find the info here in the git repo:
GitHub - looker-open-source/looker_deployer: A tool to help deploy objects from one Looker instance ...
The setup is easy, just follow the instructions. 
Please come back if you have any questions and share if it worked for what you need.

Many thanks @dsimeonova Let me try. 
Appreciated

Hey @dsimeonova 
I find this one is also using Gazer.

Because Gazer has issues here. Does it impact the Looker Deployer?

Please advise

Can you try it? @skywalker 
If it doesn't work, please come back and share the steps that you've did so I can do tests on my side and compare.

Thanks, let me try

Hey @dsimeonova 

I follow the instruction to set up a looker.ini file with base_url and client_id, client_secret_id which both are copied over from our admin user.
The base_url is the host url of our looker instance,

In the virtual environment, I installed the Python 3.8.3 and install the looker-deployer then I activate the virtual envirionment,

The local folder on my machine is called lookerdeployer and I install the virtual environment. I also create a folder called 'export' to hold exported content. (C:\Users\username\lookerdeployer\export)

then I run this command "C:\Users\username\lookerdeployer\env\Scripts>ldeploy content export --env dev --ini C:\Users\Public\looker.ini --folders 1424 --local-target .\export\" (here, 1424 is the folder number on our looker instance, I want to export)

(env) C:\Users\username\lookerdeployer\env\Scripts>ldeploy content export --env dev --ini C:\Users\Public\looker.ini --folders 1424 --local-target .\export\
{"levelname": "INFO", "module": "deploy_content_export", "funcName": "main", "message": "Exporting content", "env": "dev", "folders": ["1424"], "dashboards": null, "looks": null, "local_target": ".\\export\\", "timestamp": "2024-04-14T13:34:01.463404Z"}
Traceback (most recent call last):
File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\Users\username\lookerdeployer\env\Scripts\ldeploy.exe\__main__.py", line 9, in <module>
sys.exit(main())
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_deployer\cli.py", line 46, in main
args.func(args)
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_deployer\commands\deploy_content_export.py", line 164, in main
send_export(
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_deployer\commands\deploy_content_export.py", line 116, in send_export
folder_list = recurse_folders(fid, folder_list, sdk, debug)
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_deployer\commands\deploy_content_export.py", line 96, in recurse_folders
space = sdk.folder(str(folder_id))
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\sdk\api40\methods.py", line 5895, in folder
self.get(
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\api_methods.py", line 149, in get
response = self.transport.request(
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\requests_transport.py", line 66, in request
headers.update(authenticator(transport_options or {}))
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\auth_session.py", line 100, in authenticate
token = self._get_token(transport_options)
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\auth_session.py", line 87, in _get_token
self._login(transport_options)
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\auth_session.py", line 148, in _login
response = self._ok(
File "c:\users\username\lookerdeployer\env\lib\site-packages\looker_sdk\rtl\auth_session.py", line 240, in _ok
raise error.SDKError(response.value.decode(encoding="utf-8"))
looker_sdk.error.SDKError:
message:
documentation_url:
error_doc_url:
error details:

@dsimeonova 

In the looker.ini file, I remove ':19999" from the base_url, because if I do Not remove it, it will return the error below,

message: HTTPSConnectionPool(host='myhosturl, port=19999): Max retries exceeded with url: /api/4.0/login (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x0000018A7B739BB0>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond'))

I think our port is 443 not 19999.

If I tried for example, https://myhosturl:443/login  which is no issue.

if :19999, time out

 

Hey @skywalker !
I am trying on my side and I cannot manage to achieve the export neither.
It's not the same issue 😕 
I will post you when I found the solution!

Thanks @dsimeonova 

I also post a ticket here, related to Gazer itself,
https://github.com/looker-open-source/gzr/issues/244

I am still waiting for further reply,
Hopefully, this can be resolved soon 🙂😊

Hey @dsimeonova 

Hope you are well. 
Any updates yet?