`compute_crops.ipynb` fails because it uses deprecated ` crop_corner.interactive(adata_crop)`
未关闭
@selmanozleyen 已经在做这个了。
开始于 2025年9月4日。
评估
这个 Issue 还没有评估数据。
描述
(squidpy/docs/notebooks/examples/image/compute_crops.ipynb) fails because of trying to use a deprecated function.
Cell In[8], line 1
----> 1 crop_corner.interactive(adata_crop)
------------------
crop_corner.interactive(adata_crop)
------------------
----- stderr -----
/tmp/ipykernel_2900/2108321461.py:1: DeprecationWarning: Call to deprecated function interactive (The squidpy napari plugin is deprecated, please use https://github.com/scverse/napari-spatialdata).
crop_corner.interactive(adata_crop)
------------------
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
Cell In[8], line 1
----> 1 crop_corner.interactive(adata_crop)
File ~/work/squidpy/squidpy/src/squidpy/_utils.py:313, in deprecated.<locals>.decorator.<locals>.new_func1(*args, **kwargs)
307 warnings.warn(
308 fmt1.format(name=func1.__name__, reason=reason),
309 category=DeprecationWarning,
310 stacklevel=2,
311 )
312 warnings.simplefilter("default", DeprecationWarning)
--> 313 return func1(*args, **kwargs)
File ~/work/squidpy/squidpy/src/squidpy/im/_container.py:1136, in ImageContainer.interactive(self, adata, spatial_key, library_key, library_id, cmap, palette, blending, symbol, key_added)
1079 @d.get_sections(base="_interactive", sections=["Parameters"])
1080 @d.dedent
1081 @deprecated(
(...) 1094 key_added: str = "shapes",
1095 ) -> Interactive: # type: ignore[type-var]
1096 """
1097 Launch :mod:`napari` viewer.
1098
(...) 1134 :meth:`squidpy.pl.Interactive.screenshot`.
1135 """
-> 1136 from squidpy.pl import Interactive # type: ignore[attr-defined]
1138 return Interactive( # type: ignore[no-any-return]
1139 img=self,
1140 adata=adata,
(...) 1148 symbol=symbol,
1149 ).show()
ImportError: cannot import name 'Interactive' from 'squidpy.pl' (/home/runner/work/squidpy/squidpy/src/squidpy/pl/__init__.py)
Failed to run /home/runner/work/squidpy/squidpy/docs/notebooks/examples/image/compute_crops.ipynb
- 主要语言
- Jupyter Notebook
- 星标
- 35
- 派生
- 27
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
scverse/squidpy-tutorials 的其他 Issue
-
难度 5/5 一周以上 新手友好度 35/100
scverse/squidpy-tutorials#129 · 7 条评论 ·
-
Two improvements to the Xenium notebook可能重新可做 @LLehner 于 803 天前认领,目前没有进行中的 PR。 未关闭
scverse/squidpy-tutorials#128 · 4 条评论 · 已指派 1 人 ·
-
难度 3/5 1-2 天 新手友好度 35/100
scverse/squidpy-tutorials#123 · 1 条评论 ·
-
难度 1/5 1 小时以内 新手友好度 55/100
scverse/squidpy-tutorials#99 · 1 条评论 ·