Skip to content

Commit d6221c5

Browse files
committed
Add cleanroooms package
1 parent 52a2955 commit d6221c5

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

docs/gen-client-docs.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,7 @@ class Generator:
248248
Package("dashboards", "Dashboards", "Manage Lakeview dashboards"),
249249
Package("marketplace", "Marketplace", "Manage AI and analytics assets such as ML models, notebooks, applications in an open marketplace"),
250250
Package("apps", "Apps", "Build custom applications on Databricks"),
251+
Package("cleanrooms", "Clean Rooms", "Manage clean rooms and their assets and task runs"),
251252
]
252253

253254
def __init__(self):
@@ -375,13 +376,19 @@ def _make_folder_if_not_exists(folder):
375376

376377
def write_dataclass_docs(self):
377378
self._make_folder_if_not_exists(f'{__dir__}/dbdataclasses')
379+
all_packages = []
378380
for pkg in self.packages:
379-
module = importlib.import_module(f'databricks.sdk.service.{pkg.name}')
381+
try:
382+
module = importlib.import_module(f'databricks.sdk.service.{pkg.name}')
383+
except ModuleNotFoundError:
384+
print(f'No module found for {pkg.name}, continuing')
385+
continue
386+
all_packages.append(pkg.name)
380387
all_members = [name for name, _ in inspect.getmembers(module, predicate=self._should_document)]
381388
doc = DataclassesDoc(package=pkg, dataclasses=sorted(all_members))
382389
with open(f'{__dir__}/dbdataclasses/{pkg.name}.rst', 'w') as f:
383390
f.write(doc.as_rst())
384-
all = "\n ".join(sorted([p.name for p in self.packages]))
391+
all = "\n ".join(sorted(all_packages))
385392
with open(f'{__dir__}/dbdataclasses/index.rst', 'w') as f:
386393
f.write(f'''
387394
Dataclasses

0 commit comments

Comments
 (0)