databricks-demos / dbdemos

Demos to implement your Databricks Lakehouse
Other
255 stars 80 forks source link

dbdemos install fails at self.db.get #69

Closed pivotrobin closed 8 months ago

pivotrobin commented 10 months ago

running: dbdemos.install(path="./",use_current_cluster=True, demo_name='llm-dolly-chatbot') fails with an exception below. It appears to be trying to access a url which doesn't exist, note it is not a demo name mismatch as it doesn't even get to that point

File /local_disk0/.ephemeral_nfs/envs/pythonEnv-ff9d5db1-71c1-4f42-88d5-4128883722c7/lib/python3.10/site-packages/dbdemos/dbdemos.py:238, in install(demo_name, path, overwrite, username, pat_token, workspace_url, skip_dashboards, cloud, start_cluster, use_current_cluster, current_cluster_id, install_dashboard_sequentially, debug, catalog, schema) 235 except Exception as e: 236 print(f"ERROR setting up GCP conf: {e}") --> 238 if not installer.test_premium_pricing(): 239 #Force dashboard skip as dbsql isn't available to avoid any error. 240 skip_dashboards = True 241 installer.install_demo(demo_name, path, overwrite, skip_dashboards = skip_dashboards, start_cluster = start_cluster, use_current_cluster = use_current_cluster, debug = debug, catalog = catalog, schema = schema)

File /local_disk0/.ephemeral_nfs/envs/pythonEnv-ff9d5da1-71b1-4f42-88d5-4128883722c7/lib/python3.10/site-packages/dbdemos/installer.py:161, in Installer.test_premium_pricing(self) 160 def test_premium_pricing(self): --> 161 w = self.db.get("2.0/sql/config/warehouses", {"limit": 1}) 162 if "error_code" in w and (w["error_code"] == "FEATURE_DISABLED" or w["error_code"] == "ENDPOINT_NOT_FOUND"): 163 self.report.display_non_premium_warn(Exception(f"DBSQL not available"), w)

QuentinAmbard commented 10 months ago

hi, I don't see the final error, would you mind adding the full stack trace? Are you using a premium workspace?

pivotrobin commented 10 months ago

Yes, running in a premium workspace. This was solved today by including a PAT, which I didn't think to add since none of the demo code had it.

QuentinAmbard commented 10 months ago

Do you think you could send me the full stack trace you had without the token?

QuentinAmbard commented 8 months ago

@pivotrobin I added an extra test to better handle this in the installation procesS. Let me know if this happens again, it should continue without the dashboard if this happens again.