MCPcopy Index your code
hub / github.com/MaartenGr/BERTopic / MockPlotlyModule

Class MockPlotlyModule

bertopic/_utils.py:231–238  ·  view source on GitHub ↗

Mock module that raises an error when plotly functions are called.

Source from the content-addressed store, hash-verified

229
230
231class MockPlotlyModule:
232 """Mock module that raises an error when plotly functions are called."""
233
234 def __getattr__(self, name: str) -> Any:
235 def mock_function(*args, **kwargs):
236 raise ImportError(f"Plotly is required to use '{name}'. Install it with uv pip install plotly")
237
238 return mock_function

Callers 1

_bertopic.pyFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected