我试图在我的文档字符串上使用prospector在python文件之上.
这是我的docstring的一个例子:
"""item_exporters.py contains Scrapy item exporters.
Once you have scraped your items, you often want to persist or export those items, to use the data in some other
application. That is, after all, the whole purpose of the scraping process.
For this purpose Scrapy provides a collection of Item Exporters for different output formats, such as XML, CSV or JSON.
More Info:
https://doc.scrapy.org/en/latest/topics/exporters.html
"""
Run Code Online (Sandbox Code Playgroud)
它有一个问题:
pep257: D213 / Multi-line docstring summary should start at the second line
Run Code Online (Sandbox Code Playgroud)
因此,我将第一行向下移动,它将从第二行开始:
"""
item_exporters.py contains Scrapy item exporters.
Once you have scraped your items, you often want to persist or export those items, to use the data in some other
application. That is, after all, the whole purpose of the scraping process.
For this purpose Scrapy provides a collection of Item Exporters for different output formats, such as XML, CSV or JSON.
More Info:
https://doc.scrapy.org/en/latest/topics/exporters.html
"""
Run Code Online (Sandbox Code Playgroud)
然后,如果我再次运行探测器,我会得到D212作为错误.
pep257: D212 / Multi-line docstring summary should start at the first line
Run Code Online (Sandbox Code Playgroud)
D212和D213有问题吗?