You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tsfile.apache.org by Hongzhi Gao <76...@qq.com> on 2026/04/13 02:34:51 UTC
Re:[DISCUSS] Add Spotless + Black for Python formatting
Fully agree with this proposal—it will greatly improve consistency and reduce unnecessary review noise.
It might be safer to pin a specific Black version in Spotless to ensure consistent formatting.
Hongzhi Gao
761417898@qq.com
原始邮件
发件人:Haonan Hou <hhaonan4444@qq.com>
发件时间:2026年4月13日 09:53
收件人:dev <dev@tsfile.apache.org>
主题:[DISCUSS] Add Spotless + Black for Python formatting
Hi all,
I would like to start a discussion about adding Python formatting
with Spotless + Black in the python module.
Currently, both the Java and C++ modules already use Spotless
for code formatting. I think it may make sense to align the Python
module with the same workflow.
The current proposal is to use spotless-maven-plugin in
python/pom.xml, use black to format regular Python files (*.py),
and exclude Cython-related files such as *.pyx and *.pxd for now,
since Black does not handle Cython syntax well.
This should help keep Python code style consistent and reduce
formatting-related review noise.
I have opened a PR for this here:
https://github.com/apache/tsfile/pull/770
Any thoughts on whether we should adopt this?
Best,
Haonan Hou