paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Python-by-contract dataset

Python 契约数据集
FSE Proceedings of the 30th ACM Joint European Software Engineering Conference and Symposium on the Foundations of Software Engineering2022匹配度 2/10 · 该论文发布的是基于 icontract 的 Python 契约测试数据集,属于软件测试/调试领域,与用户的静态分析、Agentic 程序分析、LLM 改进静态分析、浮点程序分析及贝叶斯程序分析等核心方向几乎没有直接交集。虽然数据集类工作可能对 benchmark 构建有参考价值,但任务场景与用户研究画像不匹配。引用 1 inbox
Jiyang Zhang, Marko Ristin, Phillip Schanely, Hans Wernher van de Venn, Milos Gligoric
crossref: 2026-09-12

AI 速览

一句话:发布含 514 个使用 icontract 标注契约的 Python 函数数据集,用于评估基于契约的测试工具。

基于契约的设计(design-by-contract)在 Python 社区日益流行,已出现多种依据契约自动测试代码的工具,但社区一直缺乏规模足够大且有代表性的带契约 Python 代码库来评估这些工具。为此,作者构建了 Python-by-contract 数据集,其中包含 514 个使用 icontract 库标注契约的 Python 函数。论文展示了该数据集可被现有利用契约的测试工具方便地直接使用,从而为契约测试工具的比较与评估提供了统一基准。作者同时提供了演示视频。

问题
Python 社区缺少规模足够大且具代表性的带契约代码库,无法对各类基于契约的测试工具进行公平评估。
方法
使用 icontract 库标注并收集 514 个 Python 函数,构建 Python-by-contract 数据集,并验证其与现有契约测试工具的兼容性。
评估
通过展示现有利用契约的测试工具能够方便地使用该数据集,说明其可用性与适用性,并附带演示视频。
原文摘要(Abstract)

Design-by-contract as a programming technique is becoming popular in Python community as various tools have been developed for automatically testing the code based on the contracts. However, there is no sufficiently large and representative Python code base with contracts to evaluate these different testing tools. We present Python-by-contract dataset containing 514 Python functions annotated with contracts using icontract library. We show that our Python-by-contract dataset can be easily used by existing testing tools that take advantage of contracts. The demo video can be found at https://youtu.be/08wZN-xh6mY.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot7090,
  title = {Python-by-contract dataset},
  author = {Jiyang Zhang and Marko Ristin and Phillip Schanely and Hans Wernher van de Venn and Milos Gligoric},
  booktitle = {FSE},
  year = {2022},
  doi = {10.1145/3540250.3558917}
}