警告:
/opt/anaconda3/lib/python3.8/site-packages/ipykernel/ipkernel.py:287: DeprecationWarning:
`should_run_async` will not call `transform_cell` automatically in the future. Please pass the result to `transformed_cell` argument and any exception that happen during thetransform in `preprocessing_exc_tuple` in IPython 7.17 and above.
解决方法1:掩耳盗铃
import warnings
warnings.filterwarnings("ignore", category=DeprecationWarning)
解决方法2:以退为进
pip install install ipython==7.10.0
本文介绍了如何处理Python中关于`ipykernel`的DeprecationWarning,提供了两种解决方案:忽略警告和回滚到特定版本。重点在于帮助开发者解决这类常见问题,确保代码的稳定运行。
301

被折叠的 条评论
为什么被折叠?



