Async support for `PDBDebugger`
- Dominant language
- Jupyter Notebook
- Stars
- 2.6k
- Forks
- 213
- PR merge metrics
- No merged PRs in 30d
Description
**Is your feature request related to a problem? Please describe.**
`sf-hamitlon=1.80.0`
I would like to use `PDBDebugger` with `async_driver.Builder()`.
```python
from hamilton.lifecycle import PDBDebugger
dr = asyncio.run(
async_driver.Builder()
.with_modules(__main__)
.with_config({"env": "dev"})
.with_adapters(
# base.PandasDataFrameResult(),
# PDBDebugger("raw_loaded_report_data", after=True),
PDBDebugger("raw_trades.missing_trade_attributes", during=True),
)
.build()
)
```
Raises : `ValueError: Multiple adapters cannot (currently) implement the same lifecycle method. Sync methods: ['do_node_execute']. Async methods: []`
even though there was only one adapter provided. I think this error is a bit imprecise?
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
I would like to use `PDBDebugger` with `async_driver.Builder()`.
If it makes sense, I'd also like to
**Describe alternatives you've considered**
Using `pdb.set_trace()` on lines I want to inspect.
**Additional context**
The `async_driver` requires the use of `.with_adapters()` but does not support multiple adapters.
```python
.with_adapters(
base.PandasDataFrameResult(),
PDBDebugger("raw_trades.missing_trade_attributes", during=True),
)
```
Raises: `ValueError: Multiple adapters cannot (currently) implement the same lifecycle method. Sync methods: ['do_node_execute']. Async methods: []`
Contributor guide
Assessment
This issue has not been assessed yet.