You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by Francesco Guardiani <fr...@ververica.com> on 2022/03/01 16:52:31 UTC
[DISCUSS] Enable scala formatting check
Hi all,
I want to propose to enable the spotless scalafmt integration and remove
the scalastyle plugin.
From an initial analysis, scalafmt can do everything scalastyle can do, and
the integration with spotless looks easy to enable:
https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
scalafmt conf file gets picked up automatically from every IDE, and it can
be heavily tuned.
This way we can unify the formatting and integrate with our CI without any
additional configurations. And we won't need scalastyle anymore, as
scalafmt will take care of the checks:
* mvn spotless:check will check both java and scala
* mvn spotless:apply will format both java and scala
WDYT?
FG
--
Francesco Guardiani | Software Engineer
francesco@ververica.com
<https://www.ververica.com/>
Follow us @VervericaData
--
Join Flink Forward <https://flink-forward.org/> - The Apache Flink
Conference
Stream Processing | Event Driven | Real Time
--
Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
--
Ververica GmbH
Registered at Amtsgericht Charlottenburg: HRB 158244 B
Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
Jinwei (Kevin) Zhang
Re: [DISCUSS] Enable scala formatting check
Posted by Chesnay Schepler <ch...@apache.org>.
Just merge it to master & release-1.15 after 1.15.0 is released. No
impact on the current release, but also no issues with backports.
On 10/03/2022 07:33, Jark Wu wrote:
> I also have some concerns because it's a huge change and the 1.15 will be
> released soon.
> I remember the last time when we merged Java formatting, and all the
> pending bugfix PRs
> needed to be refactored. I'm afraid this may delay the 1.15 release. I
> guess the scala formatting
> is a nice-to-have feature, so we don't need to rush into 1.15.
>
> Best,
> Jark
>
> On Thu, 10 Mar 2022 at 14:24, Yun Tang <ta...@apache.org> wrote:
>
>> The feature freeze is already passed, and we just not cut the release
>> branch yet.
>> I am a bit against the idea to include this in Flink-1.15 as this is
>> really a feature change to build system not to mentition it includes 118k
>> lines change!
>>
>> Thanks
>> Yun Tang
>>
>> On 2022/03/09 16:48:10 Francesco Guardiani wrote:
>>> It would be nice to merge it before the release branch cut, but I'm not
>>> sure we're on time for that...
>>>
>>> On Wed, Mar 9, 2022 at 4:58 PM Martijn Visser <ma...@apache.org>
>>> wrote:
>>>
>>>> I think it would actually be better to merge it before the release
>> branch
>>>> is cut to avoid potential issues when needing to backport bugfixes?
>>>>
>>>> Thanks, Martijn
>>>>
>>>> On Wed, 9 Mar 2022 at 16:55, Seth Wiesman <sj...@gmail.com> wrote:
>>>>
>>>>> Happy to help get this merged.
>>>>>
>>>>> Do we want to wait until the 1.15 branch is cut? The change is mostly
>>>>> trivial (reformatting) but does make changes to the build system.
>>>>>
>>>>> Seth
>>>>>
>>>>> On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <
>>>>> francesco@ververica.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>> I've been spending some time prototyping a scalafmt conf, which
>> doesn't
>>>>>> look too different from our java style and tries to keep the same
>>>>>> properties from our scalastyle conf. Here is the PR:
>>>>>> https://github.com/apache/flink/pull/19025
>>>>>>
>>>>>> In particular, this is the scalafmt config commit:
>>>>>>
>>>>>>
>> https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
>>>>>> And this is the commit removing scalastyle:
>>>>>>
>>>>>>
>> https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
>>>>>> I need some committer to pair with to merge the big PR, any
>> volunteers?
>>>>> :)
>>>>>> After we merge it I will also update the contributor guide doc to
>>>> remove
>>>>>> scalastyle.
>>>>>>
>>>>>> FG
>>>>>>
>>>>>> On Tue, Mar 8, 2022 at 10:07 AM David Anderson <
>> danderson@apache.org>
>>>>>> wrote:
>>>>>>
>>>>>>> +1
>>>>>>>
>>>>>>> For flink-training we initially tried cloning the scalastyle
>> setup
>>>> from
>>>>>>> flink, but we decided to use spotless + scalafmt instead.
>>>>>>>
>>>>>>> David
>>>>>>>
>>>>>>> On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org>
>>>>> wrote:
>>>>>>>> Big +1
>>>>>>>>
>>>>>>>> This will improve the contribution experience. Even though we
>>>> stopped
>>>>>>>> adding more Scala code, it is still necessary from time to
>> time.
>>>>>>>> Regards,
>>>>>>>> Timo
>>>>>>>>
>>>>>>>> Am 02.03.22 um 09:29 schrieb 刘首维:
>>>>>>>>> +1
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> I still remember my first pr. Lack of experience, I had to
>> pay
>>>>>>> attention
>>>>>>>> to Scala code format and corrected the format manually, which
>> made
>>>>> me a
>>>>>>>> little embarrassed(though I'm a big fan of Scala). I think
>>>> this
>>>>>>>> proposal will lighten the burden of writing Scala code.
>>>>>>>>>
>>>>>>>>> Shouwei Liu
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------ 原始邮件 ------------------
>>>>>>>>> 发件人:
>>>>>>>> "dev"
>>>>>>>>
>> <
>>>>>>>> knaufk@apache.org>;
>>>>>>>>> 发送时间: 2022年3月2日(星期三) 下午3:01
>>>>>>>>> 收件人: "dev"<dev@flink.apache.org>;
>>>>>>>>>
>>>>>>>>> 主题: Re: [DISCUSS] Enable scala formatting check
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> +1 I've never written any Scala in Flink, but this makes a
>> lot of
>>>>>> sense
>>>>>>>> to
>>>>>>>>> me. Converging on a smaller set of tools and simplifying the
>>>> build
>>>>> is
>>>>>>>>> always a good idea and the Community already concluded before
>>>> that
>>>>>>>> spotless
>>>>>>>>> is generally a good approach.
>>>>>>>>>
>>>>>>>>> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
>>>>>>>> francesco@ververica.com>
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> > Hi all,
>>>>>>>>> >
>>>>>>>>> > I want to propose to enable the spotless scalafmt
>>>> integration
>>>>>> and
>>>>>>>> remove
>>>>>>>>> > the scalastyle plugin.
>>>>>>>>> >
>>>>>>>>> > From an initial analysis, scalafmt can do everything
>>>>> scalastyle
>>>>>>> can
>>>>>>>> do, and
>>>>>>>>> > the integration with spotless looks easy to enable:
>>>>>>>>> >
>>>>>> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
>>>>>>> .
>>>>>>>> The
>>>>>>>>> > scalafmt conf file gets picked up automatically from
>> every
>>>>> IDE,
>>>>>>> and
>>>>>>>> it can
>>>>>>>>> > be heavily tuned.
>>>>>>>>> >
>>>>>>>>> > This way we can unify the formatting and integrate with
>> our
>>>> CI
>>>>>>>> without any
>>>>>>>>> > additional configurations. And we won't need scalastyle
>>>>> anymore,
>>>>>>> as
>>>>>>>>> > scalafmt will take care of the checks:
>>>>>>>>> >
>>>>>>>>> > * mvn spotless:check will check both java and scala
>>>>>>>>> > * mvn spotless:apply will format both java and scala
>>>>>>>>> >
>>>>>>>>> > WDYT?
>>>>>>>>> >
>>>>>>>>> > FG
>>>>>>>>> >
>>>>>>>>> >
>>>>>>>>> >
>>>>>>>>> > --
>>>>>>>>> >
>>>>>>>>> > Francesco Guardiani | Software Engineer
>>>>>>>>> >
>>>>>>>>> > francesco@ververica.com
>>>>>>>>> >
>>>>>>>>> >
>>>>>>>>> > <https://www.ververica.com/>
>>>>>>>>> >
>>>>>>>>> > Follow us @VervericaData
>>>>>>>>> >
>>>>>>>>> > --
>>>>>>>>> >
>>>>>>>>> > Join Flink Forward <https://flink-forward.org/> -
>> The
>>>>> Apache
>>>>>>>> Flink
>>>>>>>>> > Conference
>>>>>>>>> >
>>>>>>>>> > Stream Processing | Event Driven | Real Time
>>>>>>>>> >
>>>>>>>>> > --
>>>>>>>>> >
>>>>>>>>> > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin,
>> Germany
>>>>>>>>> >
>>>>>>>>> > --
>>>>>>>>> >
>>>>>>>>> > Ververica GmbH
>>>>>>>>> >
>>>>>>>>> > Registered at Amtsgericht Charlottenburg: HRB 158244 B
>>>>>>>>> >
>>>>>>>>> > Managing Directors: Karl Anton Wehner, Holger Temme, Yip
>>>> Park
>>>>>> Tung
>>>>>>>> Jason,
>>>>>>>>> > Jinwei (Kevin) Zhang
>>>>>>>>> >
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
Re: [DISCUSS] Enable scala formatting check
Posted by Jark Wu <im...@gmail.com>.
I also have some concerns because it's a huge change and the 1.15 will be
released soon.
I remember the last time when we merged Java formatting, and all the
pending bugfix PRs
needed to be refactored. I'm afraid this may delay the 1.15 release. I
guess the scala formatting
is a nice-to-have feature, so we don't need to rush into 1.15.
Best,
Jark
On Thu, 10 Mar 2022 at 14:24, Yun Tang <ta...@apache.org> wrote:
> The feature freeze is already passed, and we just not cut the release
> branch yet.
> I am a bit against the idea to include this in Flink-1.15 as this is
> really a feature change to build system not to mentition it includes 118k
> lines change!
>
> Thanks
> Yun Tang
>
> On 2022/03/09 16:48:10 Francesco Guardiani wrote:
> > It would be nice to merge it before the release branch cut, but I'm not
> > sure we're on time for that...
> >
> > On Wed, Mar 9, 2022 at 4:58 PM Martijn Visser <ma...@apache.org>
> > wrote:
> >
> > > I think it would actually be better to merge it before the release
> branch
> > > is cut to avoid potential issues when needing to backport bugfixes?
> > >
> > > Thanks, Martijn
> > >
> > > On Wed, 9 Mar 2022 at 16:55, Seth Wiesman <sj...@gmail.com> wrote:
> > >
> > > > Happy to help get this merged.
> > > >
> > > > Do we want to wait until the 1.15 branch is cut? The change is mostly
> > > > trivial (reformatting) but does make changes to the build system.
> > > >
> > > > Seth
> > > >
> > > > On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <
> > > > francesco@ververica.com>
> > > > wrote:
> > > >
> > > > > Hi all,
> > > > > I've been spending some time prototyping a scalafmt conf, which
> doesn't
> > > > > look too different from our java style and tries to keep the same
> > > > > properties from our scalastyle conf. Here is the PR:
> > > > > https://github.com/apache/flink/pull/19025
> > > > >
> > > > > In particular, this is the scalafmt config commit:
> > > > >
> > > > >
> > > >
> > >
> https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
> > > > > And this is the commit removing scalastyle:
> > > > >
> > > > >
> > > >
> > >
> https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
> > > > >
> > > > > I need some committer to pair with to merge the big PR, any
> volunteers?
> > > > :)
> > > > >
> > > > > After we merge it I will also update the contributor guide doc to
> > > remove
> > > > > scalastyle.
> > > > >
> > > > > FG
> > > > >
> > > > > On Tue, Mar 8, 2022 at 10:07 AM David Anderson <
> danderson@apache.org>
> > > > > wrote:
> > > > >
> > > > > > +1
> > > > > >
> > > > > > For flink-training we initially tried cloning the scalastyle
> setup
> > > from
> > > > > > flink, but we decided to use spotless + scalafmt instead.
> > > > > >
> > > > > > David
> > > > > >
> > > > > > On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org>
> > > > wrote:
> > > > > >
> > > > > > > Big +1
> > > > > > >
> > > > > > > This will improve the contribution experience. Even though we
> > > stopped
> > > > > > > adding more Scala code, it is still necessary from time to
> time.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Timo
> > > > > > >
> > > > > > > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > > > > > > +1
> > > > > > > >
> > > > > > > >
> > > > > > > > I still remember my first pr. Lack of experience, I had to
> pay
> > > > > > attention
> > > > > > > to Scala code format and corrected the format manually, which
> made
> > > > me a
> > > > > > > little embarrassed(though I'm a big fan of Scala). I think
> > > this
> > > > > > > proposal will lighten the burden of writing Scala code.
> > > > > > > >
> > > > > > > >
> > > > > > > > Shouwei Liu
> > > > > > > >
> > > > > > > >
> > > > > > > > ------------------ 原始邮件 ------------------
> > > > > > > > 发件人:
> > > > > > > "dev"
> > > > > > >
> <
> > > > > > > knaufk@apache.org>;
> > > > > > > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > > > > > > 收件人: "dev"<dev@flink.apache.org>;
> > > > > > > >
> > > > > > > > 主题: Re: [DISCUSS] Enable scala formatting check
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > +1 I've never written any Scala in Flink, but this makes a
> lot of
> > > > > sense
> > > > > > > to
> > > > > > > > me. Converging on a smaller set of tools and simplifying the
> > > build
> > > > is
> > > > > > > > always a good idea and the Community already concluded before
> > > that
> > > > > > > spotless
> > > > > > > > is generally a good approach.
> > > > > > > >
> > > > > > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > > > > > francesco@ververica.com>
> > > > > > > > wrote:
> > > > > > > >
> > > > > > > > > Hi all,
> > > > > > > > >
> > > > > > > > > I want to propose to enable the spotless scalafmt
> > > integration
> > > > > and
> > > > > > > remove
> > > > > > > > > the scalastyle plugin.
> > > > > > > > >
> > > > > > > > > From an initial analysis, scalafmt can do everything
> > > > scalastyle
> > > > > > can
> > > > > > > do, and
> > > > > > > > > the integration with spotless looks easy to enable:
> > > > > > > > >
> > > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> > > > > > .
> > > > > > > The
> > > > > > > > > scalafmt conf file gets picked up automatically from
> every
> > > > IDE,
> > > > > > and
> > > > > > > it can
> > > > > > > > > be heavily tuned.
> > > > > > > > >
> > > > > > > > > This way we can unify the formatting and integrate with
> our
> > > CI
> > > > > > > without any
> > > > > > > > > additional configurations. And we won't need scalastyle
> > > > anymore,
> > > > > > as
> > > > > > > > > scalafmt will take care of the checks:
> > > > > > > > >
> > > > > > > > > * mvn spotless:check will check both java and scala
> > > > > > > > > * mvn spotless:apply will format both java and scala
> > > > > > > > >
> > > > > > > > > WDYT?
> > > > > > > > >
> > > > > > > > > FG
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > >
> > > > > > > > > Francesco Guardiani | Software Engineer
> > > > > > > > >
> > > > > > > > > francesco@ververica.com
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > <https://www.ververica.com/>
> > > > > > > > >
> > > > > > > > > Follow us @VervericaData
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > >
> > > > > > > > > Join Flink Forward <https://flink-forward.org/> -
> The
> > > > Apache
> > > > > > > Flink
> > > > > > > > > Conference
> > > > > > > > >
> > > > > > > > > Stream Processing | Event Driven | Real Time
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > >
> > > > > > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin,
> Germany
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > >
> > > > > > > > > Ververica GmbH
> > > > > > > > >
> > > > > > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > > > > > >
> > > > > > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip
> > > Park
> > > > > Tung
> > > > > > > Jason,
> > > > > > > > > Jinwei (Kevin) Zhang
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by Yun Tang <ta...@apache.org>.
The feature freeze is already passed, and we just not cut the release branch yet.
I am a bit against the idea to include this in Flink-1.15 as this is really a feature change to build system not to mentition it includes 118k lines change!
Thanks
Yun Tang
On 2022/03/09 16:48:10 Francesco Guardiani wrote:
> It would be nice to merge it before the release branch cut, but I'm not
> sure we're on time for that...
>
> On Wed, Mar 9, 2022 at 4:58 PM Martijn Visser <ma...@apache.org>
> wrote:
>
> > I think it would actually be better to merge it before the release branch
> > is cut to avoid potential issues when needing to backport bugfixes?
> >
> > Thanks, Martijn
> >
> > On Wed, 9 Mar 2022 at 16:55, Seth Wiesman <sj...@gmail.com> wrote:
> >
> > > Happy to help get this merged.
> > >
> > > Do we want to wait until the 1.15 branch is cut? The change is mostly
> > > trivial (reformatting) but does make changes to the build system.
> > >
> > > Seth
> > >
> > > On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <
> > > francesco@ververica.com>
> > > wrote:
> > >
> > > > Hi all,
> > > > I've been spending some time prototyping a scalafmt conf, which doesn't
> > > > look too different from our java style and tries to keep the same
> > > > properties from our scalastyle conf. Here is the PR:
> > > > https://github.com/apache/flink/pull/19025
> > > >
> > > > In particular, this is the scalafmt config commit:
> > > >
> > > >
> > >
> > https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
> > > > And this is the commit removing scalastyle:
> > > >
> > > >
> > >
> > https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
> > > >
> > > > I need some committer to pair with to merge the big PR, any volunteers?
> > > :)
> > > >
> > > > After we merge it I will also update the contributor guide doc to
> > remove
> > > > scalastyle.
> > > >
> > > > FG
> > > >
> > > > On Tue, Mar 8, 2022 at 10:07 AM David Anderson <da...@apache.org>
> > > > wrote:
> > > >
> > > > > +1
> > > > >
> > > > > For flink-training we initially tried cloning the scalastyle setup
> > from
> > > > > flink, but we decided to use spotless + scalafmt instead.
> > > > >
> > > > > David
> > > > >
> > > > > On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org>
> > > wrote:
> > > > >
> > > > > > Big +1
> > > > > >
> > > > > > This will improve the contribution experience. Even though we
> > stopped
> > > > > > adding more Scala code, it is still necessary from time to time.
> > > > > >
> > > > > > Regards,
> > > > > > Timo
> > > > > >
> > > > > > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > > > > > +1
> > > > > > >
> > > > > > >
> > > > > > > I still remember my first pr. Lack of experience, I had to pay
> > > > > attention
> > > > > > to Scala code format and corrected the format manually, which made
> > > me a
> > > > > > little embarrassed(though I'm a big fan of Scala). I think
> > this
> > > > > > proposal will lighten the burden of writing Scala code.
> > > > > > >
> > > > > > >
> > > > > > > Shouwei Liu
> > > > > > >
> > > > > > >
> > > > > > > ------------------ 原始邮件 ------------------
> > > > > > > 发件人:
> > > > > > "dev"
> > > > > > <
> > > > > > knaufk@apache.org>;
> > > > > > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > > > > > 收件人: "dev"<dev@flink.apache.org>;
> > > > > > >
> > > > > > > 主题: Re: [DISCUSS] Enable scala formatting check
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > +1 I've never written any Scala in Flink, but this makes a lot of
> > > > sense
> > > > > > to
> > > > > > > me. Converging on a smaller set of tools and simplifying the
> > build
> > > is
> > > > > > > always a good idea and the Community already concluded before
> > that
> > > > > > spotless
> > > > > > > is generally a good approach.
> > > > > > >
> > > > > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > > > > francesco@ververica.com>
> > > > > > > wrote:
> > > > > > >
> > > > > > > > Hi all,
> > > > > > > >
> > > > > > > > I want to propose to enable the spotless scalafmt
> > integration
> > > > and
> > > > > > remove
> > > > > > > > the scalastyle plugin.
> > > > > > > >
> > > > > > > > From an initial analysis, scalafmt can do everything
> > > scalastyle
> > > > > can
> > > > > > do, and
> > > > > > > > the integration with spotless looks easy to enable:
> > > > > > > >
> > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> > > > > .
> > > > > > The
> > > > > > > > scalafmt conf file gets picked up automatically from every
> > > IDE,
> > > > > and
> > > > > > it can
> > > > > > > > be heavily tuned.
> > > > > > > >
> > > > > > > > This way we can unify the formatting and integrate with our
> > CI
> > > > > > without any
> > > > > > > > additional configurations. And we won't need scalastyle
> > > anymore,
> > > > > as
> > > > > > > > scalafmt will take care of the checks:
> > > > > > > >
> > > > > > > > * mvn spotless:check will check both java and scala
> > > > > > > > * mvn spotless:apply will format both java and scala
> > > > > > > >
> > > > > > > > WDYT?
> > > > > > > >
> > > > > > > > FG
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > --
> > > > > > > >
> > > > > > > > Francesco Guardiani | Software Engineer
> > > > > > > >
> > > > > > > > francesco@ververica.com
> > > > > > > >
> > > > > > > >
> > > > > > > > <https://www.ververica.com/>
> > > > > > > >
> > > > > > > > Follow us @VervericaData
> > > > > > > >
> > > > > > > > --
> > > > > > > >
> > > > > > > > Join Flink Forward <https://flink-forward.org/> - The
> > > Apache
> > > > > > Flink
> > > > > > > > Conference
> > > > > > > >
> > > > > > > > Stream Processing | Event Driven | Real Time
> > > > > > > >
> > > > > > > > --
> > > > > > > >
> > > > > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > > > > >
> > > > > > > > --
> > > > > > > >
> > > > > > > > Ververica GmbH
> > > > > > > >
> > > > > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > > > > >
> > > > > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip
> > Park
> > > > Tung
> > > > > > Jason,
> > > > > > > > Jinwei (Kevin) Zhang
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by Francesco Guardiani <fr...@ververica.com>.
It would be nice to merge it before the release branch cut, but I'm not
sure we're on time for that...
On Wed, Mar 9, 2022 at 4:58 PM Martijn Visser <ma...@apache.org>
wrote:
> I think it would actually be better to merge it before the release branch
> is cut to avoid potential issues when needing to backport bugfixes?
>
> Thanks, Martijn
>
> On Wed, 9 Mar 2022 at 16:55, Seth Wiesman <sj...@gmail.com> wrote:
>
> > Happy to help get this merged.
> >
> > Do we want to wait until the 1.15 branch is cut? The change is mostly
> > trivial (reformatting) but does make changes to the build system.
> >
> > Seth
> >
> > On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <
> > francesco@ververica.com>
> > wrote:
> >
> > > Hi all,
> > > I've been spending some time prototyping a scalafmt conf, which doesn't
> > > look too different from our java style and tries to keep the same
> > > properties from our scalastyle conf. Here is the PR:
> > > https://github.com/apache/flink/pull/19025
> > >
> > > In particular, this is the scalafmt config commit:
> > >
> > >
> >
> https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
> > > And this is the commit removing scalastyle:
> > >
> > >
> >
> https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
> > >
> > > I need some committer to pair with to merge the big PR, any volunteers?
> > :)
> > >
> > > After we merge it I will also update the contributor guide doc to
> remove
> > > scalastyle.
> > >
> > > FG
> > >
> > > On Tue, Mar 8, 2022 at 10:07 AM David Anderson <da...@apache.org>
> > > wrote:
> > >
> > > > +1
> > > >
> > > > For flink-training we initially tried cloning the scalastyle setup
> from
> > > > flink, but we decided to use spotless + scalafmt instead.
> > > >
> > > > David
> > > >
> > > > On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org>
> > wrote:
> > > >
> > > > > Big +1
> > > > >
> > > > > This will improve the contribution experience. Even though we
> stopped
> > > > > adding more Scala code, it is still necessary from time to time.
> > > > >
> > > > > Regards,
> > > > > Timo
> > > > >
> > > > > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > > > > +1
> > > > > >
> > > > > >
> > > > > > I still remember my first pr. Lack of experience, I had to pay
> > > > attention
> > > > > to Scala code format and corrected the format manually, which made
> > me a
> > > > > little embarrassed(though I'm a big fan of Scala). I think
> this
> > > > > proposal will lighten the burden of writing Scala code.
> > > > > >
> > > > > >
> > > > > > Shouwei Liu
> > > > > >
> > > > > >
> > > > > > ------------------ 原始邮件 ------------------
> > > > > > 发件人:
> > > > > "dev"
> > > > > <
> > > > > knaufk@apache.org>;
> > > > > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > > > > 收件人: "dev"<dev@flink.apache.org>;
> > > > > >
> > > > > > 主题: Re: [DISCUSS] Enable scala formatting check
> > > > > >
> > > > > >
> > > > > >
> > > > > > +1 I've never written any Scala in Flink, but this makes a lot of
> > > sense
> > > > > to
> > > > > > me. Converging on a smaller set of tools and simplifying the
> build
> > is
> > > > > > always a good idea and the Community already concluded before
> that
> > > > > spotless
> > > > > > is generally a good approach.
> > > > > >
> > > > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > > > francesco@ververica.com>
> > > > > > wrote:
> > > > > >
> > > > > > > Hi all,
> > > > > > >
> > > > > > > I want to propose to enable the spotless scalafmt
> integration
> > > and
> > > > > remove
> > > > > > > the scalastyle plugin.
> > > > > > >
> > > > > > > From an initial analysis, scalafmt can do everything
> > scalastyle
> > > > can
> > > > > do, and
> > > > > > > the integration with spotless looks easy to enable:
> > > > > > >
> > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> > > > .
> > > > > The
> > > > > > > scalafmt conf file gets picked up automatically from every
> > IDE,
> > > > and
> > > > > it can
> > > > > > > be heavily tuned.
> > > > > > >
> > > > > > > This way we can unify the formatting and integrate with our
> CI
> > > > > without any
> > > > > > > additional configurations. And we won't need scalastyle
> > anymore,
> > > > as
> > > > > > > scalafmt will take care of the checks:
> > > > > > >
> > > > > > > * mvn spotless:check will check both java and scala
> > > > > > > * mvn spotless:apply will format both java and scala
> > > > > > >
> > > > > > > WDYT?
> > > > > > >
> > > > > > > FG
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > >
> > > > > > > Francesco Guardiani | Software Engineer
> > > > > > >
> > > > > > > francesco@ververica.com
> > > > > > >
> > > > > > >
> > > > > > > <https://www.ververica.com/>
> > > > > > >
> > > > > > > Follow us @VervericaData
> > > > > > >
> > > > > > > --
> > > > > > >
> > > > > > > Join Flink Forward <https://flink-forward.org/> - The
> > Apache
> > > > > Flink
> > > > > > > Conference
> > > > > > >
> > > > > > > Stream Processing | Event Driven | Real Time
> > > > > > >
> > > > > > > --
> > > > > > >
> > > > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > > > >
> > > > > > > --
> > > > > > >
> > > > > > > Ververica GmbH
> > > > > > >
> > > > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > > > >
> > > > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip
> Park
> > > Tung
> > > > > Jason,
> > > > > > > Jinwei (Kevin) Zhang
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by Martijn Visser <ma...@apache.org>.
I think it would actually be better to merge it before the release branch
is cut to avoid potential issues when needing to backport bugfixes?
Thanks, Martijn
On Wed, 9 Mar 2022 at 16:55, Seth Wiesman <sj...@gmail.com> wrote:
> Happy to help get this merged.
>
> Do we want to wait until the 1.15 branch is cut? The change is mostly
> trivial (reformatting) but does make changes to the build system.
>
> Seth
>
> On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <
> francesco@ververica.com>
> wrote:
>
> > Hi all,
> > I've been spending some time prototyping a scalafmt conf, which doesn't
> > look too different from our java style and tries to keep the same
> > properties from our scalastyle conf. Here is the PR:
> > https://github.com/apache/flink/pull/19025
> >
> > In particular, this is the scalafmt config commit:
> >
> >
> https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
> > And this is the commit removing scalastyle:
> >
> >
> https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
> >
> > I need some committer to pair with to merge the big PR, any volunteers?
> :)
> >
> > After we merge it I will also update the contributor guide doc to remove
> > scalastyle.
> >
> > FG
> >
> > On Tue, Mar 8, 2022 at 10:07 AM David Anderson <da...@apache.org>
> > wrote:
> >
> > > +1
> > >
> > > For flink-training we initially tried cloning the scalastyle setup from
> > > flink, but we decided to use spotless + scalafmt instead.
> > >
> > > David
> > >
> > > On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org>
> wrote:
> > >
> > > > Big +1
> > > >
> > > > This will improve the contribution experience. Even though we stopped
> > > > adding more Scala code, it is still necessary from time to time.
> > > >
> > > > Regards,
> > > > Timo
> > > >
> > > > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > > > +1
> > > > >
> > > > >
> > > > > I still remember my first pr. Lack of experience, I had to pay
> > > attention
> > > > to Scala code format and corrected the format manually, which made
> me a
> > > > little embarrassed(though I'm a big fan of Scala). I think this
> > > > proposal will lighten the burden of writing Scala code.
> > > > >
> > > > >
> > > > > Shouwei Liu
> > > > >
> > > > >
> > > > > ------------------ 原始邮件 ------------------
> > > > > 发件人:
> > > > "dev"
> > > > <
> > > > knaufk@apache.org>;
> > > > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > > > 收件人: "dev"<dev@flink.apache.org>;
> > > > >
> > > > > 主题: Re: [DISCUSS] Enable scala formatting check
> > > > >
> > > > >
> > > > >
> > > > > +1 I've never written any Scala in Flink, but this makes a lot of
> > sense
> > > > to
> > > > > me. Converging on a smaller set of tools and simplifying the build
> is
> > > > > always a good idea and the Community already concluded before that
> > > > spotless
> > > > > is generally a good approach.
> > > > >
> > > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > > francesco@ververica.com>
> > > > > wrote:
> > > > >
> > > > > > Hi all,
> > > > > >
> > > > > > I want to propose to enable the spotless scalafmt integration
> > and
> > > > remove
> > > > > > the scalastyle plugin.
> > > > > >
> > > > > > From an initial analysis, scalafmt can do everything
> scalastyle
> > > can
> > > > do, and
> > > > > > the integration with spotless looks easy to enable:
> > > > > >
> > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> > > .
> > > > The
> > > > > > scalafmt conf file gets picked up automatically from every
> IDE,
> > > and
> > > > it can
> > > > > > be heavily tuned.
> > > > > >
> > > > > > This way we can unify the formatting and integrate with our CI
> > > > without any
> > > > > > additional configurations. And we won't need scalastyle
> anymore,
> > > as
> > > > > > scalafmt will take care of the checks:
> > > > > >
> > > > > > * mvn spotless:check will check both java and scala
> > > > > > * mvn spotless:apply will format both java and scala
> > > > > >
> > > > > > WDYT?
> > > > > >
> > > > > > FG
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Francesco Guardiani | Software Engineer
> > > > > >
> > > > > > francesco@ververica.com
> > > > > >
> > > > > >
> > > > > > <https://www.ververica.com/>
> > > > > >
> > > > > > Follow us @VervericaData
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Join Flink Forward <https://flink-forward.org/> - The
> Apache
> > > > Flink
> > > > > > Conference
> > > > > >
> > > > > > Stream Processing | Event Driven | Real Time
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Ververica GmbH
> > > > > >
> > > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > > >
> > > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park
> > Tung
> > > > Jason,
> > > > > > Jinwei (Kevin) Zhang
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by Seth Wiesman <sj...@gmail.com>.
Happy to help get this merged.
Do we want to wait until the 1.15 branch is cut? The change is mostly
trivial (reformatting) but does make changes to the build system.
Seth
On Wed, Mar 9, 2022 at 9:45 AM Francesco Guardiani <fr...@ververica.com>
wrote:
> Hi all,
> I've been spending some time prototyping a scalafmt conf, which doesn't
> look too different from our java style and tries to keep the same
> properties from our scalastyle conf. Here is the PR:
> https://github.com/apache/flink/pull/19025
>
> In particular, this is the scalafmt config commit:
>
> https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
> And this is the commit removing scalastyle:
>
> https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
>
> I need some committer to pair with to merge the big PR, any volunteers? :)
>
> After we merge it I will also update the contributor guide doc to remove
> scalastyle.
>
> FG
>
> On Tue, Mar 8, 2022 at 10:07 AM David Anderson <da...@apache.org>
> wrote:
>
> > +1
> >
> > For flink-training we initially tried cloning the scalastyle setup from
> > flink, but we decided to use spotless + scalafmt instead.
> >
> > David
> >
> > On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org> wrote:
> >
> > > Big +1
> > >
> > > This will improve the contribution experience. Even though we stopped
> > > adding more Scala code, it is still necessary from time to time.
> > >
> > > Regards,
> > > Timo
> > >
> > > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > > +1
> > > >
> > > >
> > > > I still remember my first pr. Lack of experience, I had to pay
> > attention
> > > to Scala code format and corrected the format manually, which made me a
> > > little embarrassed(though I'm a big fan of Scala). I think this
> > > proposal will lighten the burden of writing Scala code.
> > > >
> > > >
> > > > Shouwei Liu
> > > >
> > > >
> > > > ------------------ 原始邮件 ------------------
> > > > 发件人:
> > > "dev"
> > > <
> > > knaufk@apache.org>;
> > > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > > 收件人: "dev"<dev@flink.apache.org>;
> > > >
> > > > 主题: Re: [DISCUSS] Enable scala formatting check
> > > >
> > > >
> > > >
> > > > +1 I've never written any Scala in Flink, but this makes a lot of
> sense
> > > to
> > > > me. Converging on a smaller set of tools and simplifying the build is
> > > > always a good idea and the Community already concluded before that
> > > spotless
> > > > is generally a good approach.
> > > >
> > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > francesco@ververica.com>
> > > > wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > I want to propose to enable the spotless scalafmt integration
> and
> > > remove
> > > > > the scalastyle plugin.
> > > > >
> > > > > From an initial analysis, scalafmt can do everything scalastyle
> > can
> > > do, and
> > > > > the integration with spotless looks easy to enable:
> > > > >
> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> > .
> > > The
> > > > > scalafmt conf file gets picked up automatically from every IDE,
> > and
> > > it can
> > > > > be heavily tuned.
> > > > >
> > > > > This way we can unify the formatting and integrate with our CI
> > > without any
> > > > > additional configurations. And we won't need scalastyle anymore,
> > as
> > > > > scalafmt will take care of the checks:
> > > > >
> > > > > * mvn spotless:check will check both java and scala
> > > > > * mvn spotless:apply will format both java and scala
> > > > >
> > > > > WDYT?
> > > > >
> > > > > FG
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > >
> > > > > Francesco Guardiani | Software Engineer
> > > > >
> > > > > francesco@ververica.com
> > > > >
> > > > >
> > > > > <https://www.ververica.com/>
> > > > >
> > > > > Follow us @VervericaData
> > > > >
> > > > > --
> > > > >
> > > > > Join Flink Forward <https://flink-forward.org/> - The Apache
> > > Flink
> > > > > Conference
> > > > >
> > > > > Stream Processing | Event Driven | Real Time
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH
> > > > >
> > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > >
> > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park
> Tung
> > > Jason,
> > > > > Jinwei (Kevin) Zhang
> > > > >
> > > >
> > > >
> > >
> > >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by Francesco Guardiani <fr...@ververica.com>.
Hi all,
I've been spending some time prototyping a scalafmt conf, which doesn't
look too different from our java style and tries to keep the same
properties from our scalastyle conf. Here is the PR:
https://github.com/apache/flink/pull/19025
In particular, this is the scalafmt config commit:
https://github.com/apache/flink/pull/19025/commits/cb32893df4b554e4526324c43c86681cc9fe8169
And this is the commit removing scalastyle:
https://github.com/apache/flink/pull/19025/commits/9ffe7d52e3368c5c40f15e3dc48f6d81691a8dd0
I need some committer to pair with to merge the big PR, any volunteers? :)
After we merge it I will also update the contributor guide doc to remove
scalastyle.
FG
On Tue, Mar 8, 2022 at 10:07 AM David Anderson <da...@apache.org> wrote:
> +1
>
> For flink-training we initially tried cloning the scalastyle setup from
> flink, but we decided to use spotless + scalafmt instead.
>
> David
>
> On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org> wrote:
>
> > Big +1
> >
> > This will improve the contribution experience. Even though we stopped
> > adding more Scala code, it is still necessary from time to time.
> >
> > Regards,
> > Timo
> >
> > Am 02.03.22 um 09:29 schrieb 刘首维:
> > > +1
> > >
> > >
> > > I still remember my first pr. Lack of experience, I had to pay
> attention
> > to Scala code format and corrected the format manually, which made me a
> > little embarrassed(though I'm a big fan of Scala). I think this
> > proposal will lighten the burden of writing Scala code.
> > >
> > >
> > > Shouwei Liu
> > >
> > >
> > > ------------------ 原始邮件 ------------------
> > > 发件人:
> > "dev"
> > <
> > knaufk@apache.org>;
> > > 发送时间: 2022年3月2日(星期三) 下午3:01
> > > 收件人: "dev"<dev@flink.apache.org>;
> > >
> > > 主题: Re: [DISCUSS] Enable scala formatting check
> > >
> > >
> > >
> > > +1 I've never written any Scala in Flink, but this makes a lot of sense
> > to
> > > me. Converging on a smaller set of tools and simplifying the build is
> > > always a good idea and the Community already concluded before that
> > spotless
> > > is generally a good approach.
> > >
> > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > francesco@ververica.com>
> > > wrote:
> > >
> > > > Hi all,
> > > >
> > > > I want to propose to enable the spotless scalafmt integration and
> > remove
> > > > the scalastyle plugin.
> > > >
> > > > From an initial analysis, scalafmt can do everything scalastyle
> can
> > do, and
> > > > the integration with spotless looks easy to enable:
> > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> .
> > The
> > > > scalafmt conf file gets picked up automatically from every IDE,
> and
> > it can
> > > > be heavily tuned.
> > > >
> > > > This way we can unify the formatting and integrate with our CI
> > without any
> > > > additional configurations. And we won't need scalastyle anymore,
> as
> > > > scalafmt will take care of the checks:
> > > >
> > > > * mvn spotless:check will check both java and scala
> > > > * mvn spotless:apply will format both java and scala
> > > >
> > > > WDYT?
> > > >
> > > > FG
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Francesco Guardiani | Software Engineer
> > > >
> > > > francesco@ververica.com
> > > >
> > > >
> > > > <https://www.ververica.com/>
> > > >
> > > > Follow us @VervericaData
> > > >
> > > > --
> > > >
> > > > Join Flink Forward <https://flink-forward.org/> - The Apache
> > Flink
> > > > Conference
> > > >
> > > > Stream Processing | Event Driven | Real Time
> > > >
> > > > --
> > > >
> > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > >
> > > > --
> > > >
> > > > Ververica GmbH
> > > >
> > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > >
> > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> > Jason,
> > > > Jinwei (Kevin) Zhang
> > > >
> > >
> > >
> >
> >
>
Re: [DISCUSS] Enable scala formatting check
Posted by David Anderson <da...@apache.org>.
+1
For flink-training we initially tried cloning the scalastyle setup from
flink, but we decided to use spotless + scalafmt instead.
David
On Mon, Mar 7, 2022 at 1:12 PM Timo Walther <tw...@apache.org> wrote:
> Big +1
>
> This will improve the contribution experience. Even though we stopped
> adding more Scala code, it is still necessary from time to time.
>
> Regards,
> Timo
>
> Am 02.03.22 um 09:29 schrieb 刘首维:
> > +1
> >
> >
> > I still remember my first pr. Lack of experience, I had to pay attention
> to Scala code format and corrected the format manually, which made me a
> little embarrassed(though I'm a big fan of Scala). I think this
> proposal will lighten the burden of writing Scala code.
> >
> >
> > Shouwei Liu
> >
> >
> > ------------------ 原始邮件 ------------------
> > 发件人:
> "dev"
> <
> knaufk@apache.org>;
> > 发送时间: 2022年3月2日(星期三) 下午3:01
> > 收件人: "dev"<dev@flink.apache.org>;
> >
> > 主题: Re: [DISCUSS] Enable scala formatting check
> >
> >
> >
> > +1 I've never written any Scala in Flink, but this makes a lot of sense
> to
> > me. Converging on a smaller set of tools and simplifying the build is
> > always a good idea and the Community already concluded before that
> spotless
> > is generally a good approach.
> >
> > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> francesco@ververica.com>
> > wrote:
> >
> > > Hi all,
> > >
> > > I want to propose to enable the spotless scalafmt integration and
> remove
> > > the scalastyle plugin.
> > >
> > > From an initial analysis, scalafmt can do everything scalastyle can
> do, and
> > > the integration with spotless looks easy to enable:
> > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
> The
> > > scalafmt conf file gets picked up automatically from every IDE, and
> it can
> > > be heavily tuned.
> > >
> > > This way we can unify the formatting and integrate with our CI
> without any
> > > additional configurations. And we won't need scalastyle anymore, as
> > > scalafmt will take care of the checks:
> > >
> > > * mvn spotless:check will check both java and scala
> > > * mvn spotless:apply will format both java and scala
> > >
> > > WDYT?
> > >
> > > FG
> > >
> > >
> > >
> > > --
> > >
> > > Francesco Guardiani | Software Engineer
> > >
> > > francesco@ververica.com
> > >
> > >
> > > <https://www.ververica.com/>
> > >
> > > Follow us @VervericaData
> > >
> > > --
> > >
> > > Join Flink Forward <https://flink-forward.org/> - The Apache
> Flink
> > > Conference
> > >
> > > Stream Processing | Event Driven | Real Time
> > >
> > > --
> > >
> > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > >
> > > --
> > >
> > > Ververica GmbH
> > >
> > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > >
> > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> Jason,
> > > Jinwei (Kevin) Zhang
> > >
> >
> >
>
>
Re: [DISCUSS] Enable scala formatting check
Posted by Timo Walther <tw...@apache.org>.
Big +1
This will improve the contribution experience. Even though we stopped
adding more Scala code, it is still necessary from time to time.
Regards,
Timo
Am 02.03.22 um 09:29 schrieb 刘首维:
> +1
>
>
> I still remember my first pr. Lack of experience, I had to pay attention to Scala code format and corrected the format manually, which made me a little embarrassed(though I'm a big fan of Scala). I think this proposal will lighten the burden of writing Scala code.
>
>
> Shouwei Liu
>
>
> ------------------ 原始邮件 ------------------
> 发件人: "dev" <knaufk@apache.org>;
> 发送时间: 2022年3月2日(星期三) 下午3:01
> 收件人: "dev"<dev@flink.apache.org>;
>
> 主题: Re: [DISCUSS] Enable scala formatting check
>
>
>
> +1 I've never written any Scala in Flink, but this makes a lot of sense to
> me. Converging on a smaller set of tools and simplifying the build is
> always a good idea and the Community already concluded before that spotless
> is generally a good approach.
>
> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <francesco@ververica.com>
> wrote:
>
> > Hi all,
> >
> > I want to propose to enable the spotless scalafmt integration and remove
> > the scalastyle plugin.
> >
> > From an initial analysis, scalafmt can do everything scalastyle can do, and
> > the integration with spotless looks easy to enable:
> > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> > scalafmt conf file gets picked up automatically from every IDE, and it can
> > be heavily tuned.
> >
> > This way we can unify the formatting and integrate with our CI without any
> > additional configurations. And we won't need scalastyle anymore, as
> > scalafmt will take care of the checks:
> >
> > * mvn spotless:check will check both java and scala
> > * mvn spotless:apply will format both java and scala
> >
> > WDYT?
> >
> > FG
> >
> >
> >
> > --
> >
> > Francesco Guardiani | Software Engineer
> >
> > francesco@ververica.com
> >
> >
> > <https://www.ververica.com/>
> >
> > Follow us @VervericaData
> >
> > --
> >
> > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > Conference
> >
> > Stream Processing | Event Driven | Real Time
> >
> > --
> >
> > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> >
> > --
> >
> > Ververica GmbH
> >
> > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> >
> > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
> > Jinwei (Kevin) Zhang
> >
>
>
re: [DISCUSS] Enable scala formatting check
Posted by 刘首维 <jo...@qq.com.INVALID>.
+1
I still remember my first pr. Lack of experience, I had to pay attention to Scala code format and corrected the format manually, which made me a little embarrassed(though I'm a big fan of Scala). I think this proposal will lighten the burden of writing Scala code.
Shouwei Liu
------------------ 原始邮件 ------------------
发件人: "dev" <knaufk@apache.org>;
发送时间: 2022年3月2日(星期三) 下午3:01
收件人: "dev"<dev@flink.apache.org>;
主题: Re: [DISCUSS] Enable scala formatting check
+1 I've never written any Scala in Flink, but this makes a lot of sense to
me. Converging on a smaller set of tools and simplifying the build is
always a good idea and the Community already concluded before that spotless
is generally a good approach.
On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <francesco@ververica.com>
wrote:
> Hi all,
>
> I want to propose to enable the spotless scalafmt integration and remove
> the scalastyle plugin.
>
> From an initial analysis, scalafmt can do everything scalastyle can do, and
> the integration with spotless looks easy to enable:
> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> scalafmt conf file gets picked up automatically from every IDE, and it can
> be heavily tuned.
>
> This way we can unify the formatting and integrate with our CI without any
> additional configurations. And we won't need scalastyle anymore, as
> scalafmt will take care of the checks:
>
> * mvn spotless:check will check both java and scala
> * mvn spotless:apply will format both java and scala
>
> WDYT?
>
> FG
>
>
>
> --
>
> Francesco Guardiani | Software Engineer
>
> francesco@ververica.com
>
>
> <https://www.ververica.com/>
>
> Follow us @VervericaData
>
> --
>
> Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> Conference
>
> Stream Processing | Event Driven | Real Time
>
> --
>
> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
>
> --
>
> Ververica GmbH
>
> Registered at Amtsgericht Charlottenburg: HRB 158244 B
>
> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
> Jinwei (Kevin) Zhang
>
--
Konstantin Knauf
https://twitter.com/snntrable
https://github.com/knaufk
Re: [DISCUSS] Enable scala formatting check
Posted by Ryan Skraba <ry...@aiven.io.INVALID>.
+1 for me -- I've used spotless and scalafmt together in the past, and
especially appreciated how consistent it is between using on the command
line and in the IDE.
All my best, Ryan
On Wed, Mar 2, 2022 at 11:19 AM Marios Trivyzas <ma...@gmail.com> wrote:
> +1 from me as well, Having a unified auto-formatter for scala would be
> great.
> Currently we don't have consistency in our code base, and this makes it
> more difficult
> to read and work on the scala code.
>
> Best,
> Marios
>
> On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com>
> wrote:
>
> > +1, currently the scalastyle does not work well actually, there are a lot
> > of style differences in different files. It would be great if the code
> can
> > be auto formatted.
> >
> > Best,
> > Wenlong
> >
> > On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com> wrote:
> >
> > > +1.
> > >
> > > Thanks for driving.
> > >
> > > I wrote some scala code, the style of our flink's scala is messy. We
> > > can do better.
> > >
> > > Best,
> > > Jingsong
> > >
> > > On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> > > >
> > > > +1
> > > >
> > > > I also noticed that the project of scalafmt [1] is much more active
> > than
> > > scalatyle [2], which has no release in the past 4 years.
> > > >
> > > >
> > > > [1] https://github.com/scalameta/scalafmt/releases
> > > > [2] https://github.com/scalastyle/scalastyle/tags
> > > >
> > > > Best
> > > > Yun Tang
> > > >
> > > > ________________________________
> > > > From: Konstantin Knauf <kn...@apache.org>
> > > > Sent: Wednesday, March 2, 2022 15:01
> > > > To: dev <de...@flink.apache.org>
> > > > Subject: Re: [DISCUSS] Enable scala formatting check
> > > >
> > > > +1 I've never written any Scala in Flink, but this makes a lot of
> sense
> > > to
> > > > me. Converging on a smaller set of tools and simplifying the build is
> > > > always a good idea and the Community already concluded before that
> > > spotless
> > > > is generally a good approach.
> > > >
> > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > francesco@ververica.com>
> > > > wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > I want to propose to enable the spotless scalafmt integration and
> > > remove
> > > > > the scalastyle plugin.
> > > > >
> > > > > From an initial analysis, scalafmt can do everything scalastyle can
> > > do, and
> > > > > the integration with spotless looks easy to enable:
> > > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
> > The
> > > > > scalafmt conf file gets picked up automatically from every IDE, and
> > it
> > > can
> > > > > be heavily tuned.
> > > > >
> > > > > This way we can unify the formatting and integrate with our CI
> > without
> > > any
> > > > > additional configurations. And we won't need scalastyle anymore, as
> > > > > scalafmt will take care of the checks:
> > > > >
> > > > > * mvn spotless:check will check both java and scala
> > > > > * mvn spotless:apply will format both java and scala
> > > > >
> > > > > WDYT?
> > > > >
> > > > > FG
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > >
> > > > > Francesco Guardiani | Software Engineer
> > > > >
> > > > > francesco@ververica.com
> > > > >
> > > > >
> > > > > <https://www.ververica.com/>
> > > > >
> > > > > Follow us @VervericaData
> > > > >
> > > > > --
> > > > >
> > > > > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > > > > Conference
> > > > >
> > > > > Stream Processing | Event Driven | Real Time
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH
> > > > >
> > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > >
> > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> > > Jason,
> > > > > Jinwei (Kevin) Zhang
> > > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Konstantin Knauf
> > > >
> > > > https://twitter.com/snntrable
> > > >
> > > > https://github.com/knaufk
> > >
> >
>
>
> --
> Marios
>
Re: [DISCUSS] Enable scala formatting check
Posted by Terry <zj...@gmail.com>.
big +1.
Shuo Cheng <nj...@gmail.com> 于2022年3月3日周四 10:33写道:
> +1, a lot of convenience will be brought then. 👍
>
> On Wed, Mar 2, 2022 at 7:29 PM Leonard Xu <xb...@gmail.com> wrote:
>
> > +1 from my side, thanks for driving this improvement.
> >
> > Best,
> > Leonard
> >
> > > 2022年3月2日 下午7:13,Jiangang Liu <li...@gmail.com> 写道:
> > >
> > > +1 for the feature. Good style management can help the developer a lot.
> > >
> > > Marios Trivyzas <ma...@gmail.com> 于2022年3月2日周三 18:19写道:
> > >
> > >> +1 from me as well, Having a unified auto-formatter for scala would be
> > >> great.
> > >> Currently we don't have consistency in our code base, and this makes
> it
> > >> more difficult
> > >> to read and work on the scala code.
> > >>
> > >> Best,
> > >> Marios
> > >>
> > >> On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com>
> > >> wrote:
> > >>
> > >>> +1, currently the scalastyle does not work well actually, there are a
> > lot
> > >>> of style differences in different files. It would be great if the
> code
> > >> can
> > >>> be auto formatted.
> > >>>
> > >>> Best,
> > >>> Wenlong
> > >>>
> > >>> On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com>
> > wrote:
> > >>>
> > >>>> +1.
> > >>>>
> > >>>> Thanks for driving.
> > >>>>
> > >>>> I wrote some scala code, the style of our flink's scala is messy. We
> > >>>> can do better.
> > >>>>
> > >>>> Best,
> > >>>> Jingsong
> > >>>>
> > >>>> On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> > >>>>>
> > >>>>> +1
> > >>>>>
> > >>>>> I also noticed that the project of scalafmt [1] is much more active
> > >>> than
> > >>>> scalatyle [2], which has no release in the past 4 years.
> > >>>>>
> > >>>>>
> > >>>>> [1] https://github.com/scalameta/scalafmt/releases
> > >>>>> [2] https://github.com/scalastyle/scalastyle/tags
> > >>>>>
> > >>>>> Best
> > >>>>> Yun Tang
> > >>>>>
> > >>>>> ________________________________
> > >>>>> From: Konstantin Knauf <kn...@apache.org>
> > >>>>> Sent: Wednesday, March 2, 2022 15:01
> > >>>>> To: dev <de...@flink.apache.org>
> > >>>>> Subject: Re: [DISCUSS] Enable scala formatting check
> > >>>>>
> > >>>>> +1 I've never written any Scala in Flink, but this makes a lot of
> > >> sense
> > >>>> to
> > >>>>> me. Converging on a smaller set of tools and simplifying the build
> is
> > >>>>> always a good idea and the Community already concluded before that
> > >>>> spotless
> > >>>>> is generally a good approach.
> > >>>>>
> > >>>>> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > >>>> francesco@ververica.com>
> > >>>>> wrote:
> > >>>>>
> > >>>>>> Hi all,
> > >>>>>>
> > >>>>>> I want to propose to enable the spotless scalafmt integration and
> > >>>> remove
> > >>>>>> the scalastyle plugin.
> > >>>>>>
> > >>>>>> From an initial analysis, scalafmt can do everything scalastyle
> can
> > >>>> do, and
> > >>>>>> the integration with spotless looks easy to enable:
> > >>>>>> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala
> .
> > >>> The
> > >>>>>> scalafmt conf file gets picked up automatically from every IDE,
> and
> > >>> it
> > >>>> can
> > >>>>>> be heavily tuned.
> > >>>>>>
> > >>>>>> This way we can unify the formatting and integrate with our CI
> > >>> without
> > >>>> any
> > >>>>>> additional configurations. And we won't need scalastyle anymore,
> as
> > >>>>>> scalafmt will take care of the checks:
> > >>>>>>
> > >>>>>> * mvn spotless:check will check both java and scala
> > >>>>>> * mvn spotless:apply will format both java and scala
> > >>>>>>
> > >>>>>> WDYT?
> > >>>>>>
> > >>>>>> FG
> > >>>>>>
> > >>>>>>
> > >>>>>>
> > >>>>>> --
> > >>>>>>
> > >>>>>> Francesco Guardiani | Software Engineer
> > >>>>>>
> > >>>>>> francesco@ververica.com
> > >>>>>>
> > >>>>>>
> > >>>>>> <https://www.ververica.com/>
> > >>>>>>
> > >>>>>> Follow us @VervericaData
> > >>>>>>
> > >>>>>> --
> > >>>>>>
> > >>>>>> Join Flink Forward <https://flink-forward.org/> - The Apache
> Flink
> > >>>>>> Conference
> > >>>>>>
> > >>>>>> Stream Processing | Event Driven | Real Time
> > >>>>>>
> > >>>>>> --
> > >>>>>>
> > >>>>>> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > >>>>>>
> > >>>>>> --
> > >>>>>>
> > >>>>>> Ververica GmbH
> > >>>>>>
> > >>>>>> Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > >>>>>>
> > >>>>>> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> > >>>> Jason,
> > >>>>>> Jinwei (Kevin) Zhang
> > >>>>>>
> > >>>>>
> > >>>>>
> > >>>>> --
> > >>>>>
> > >>>>> Konstantin Knauf
> > >>>>>
> > >>>>> https://twitter.com/snntrable
> > >>>>>
> > >>>>> https://github.com/knaufk
> > >>>>
> > >>>
> > >>
> > >>
> > >> --
> > >> Marios
> > >>
> >
> >
>
--
Best Regards,
Terry Wang
Re: [DISCUSS] Enable scala formatting check
Posted by Shuo Cheng <nj...@gmail.com>.
+1, a lot of convenience will be brought then. 👍
On Wed, Mar 2, 2022 at 7:29 PM Leonard Xu <xb...@gmail.com> wrote:
> +1 from my side, thanks for driving this improvement.
>
> Best,
> Leonard
>
> > 2022年3月2日 下午7:13,Jiangang Liu <li...@gmail.com> 写道:
> >
> > +1 for the feature. Good style management can help the developer a lot.
> >
> > Marios Trivyzas <ma...@gmail.com> 于2022年3月2日周三 18:19写道:
> >
> >> +1 from me as well, Having a unified auto-formatter for scala would be
> >> great.
> >> Currently we don't have consistency in our code base, and this makes it
> >> more difficult
> >> to read and work on the scala code.
> >>
> >> Best,
> >> Marios
> >>
> >> On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com>
> >> wrote:
> >>
> >>> +1, currently the scalastyle does not work well actually, there are a
> lot
> >>> of style differences in different files. It would be great if the code
> >> can
> >>> be auto formatted.
> >>>
> >>> Best,
> >>> Wenlong
> >>>
> >>> On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com>
> wrote:
> >>>
> >>>> +1.
> >>>>
> >>>> Thanks for driving.
> >>>>
> >>>> I wrote some scala code, the style of our flink's scala is messy. We
> >>>> can do better.
> >>>>
> >>>> Best,
> >>>> Jingsong
> >>>>
> >>>> On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> >>>>>
> >>>>> +1
> >>>>>
> >>>>> I also noticed that the project of scalafmt [1] is much more active
> >>> than
> >>>> scalatyle [2], which has no release in the past 4 years.
> >>>>>
> >>>>>
> >>>>> [1] https://github.com/scalameta/scalafmt/releases
> >>>>> [2] https://github.com/scalastyle/scalastyle/tags
> >>>>>
> >>>>> Best
> >>>>> Yun Tang
> >>>>>
> >>>>> ________________________________
> >>>>> From: Konstantin Knauf <kn...@apache.org>
> >>>>> Sent: Wednesday, March 2, 2022 15:01
> >>>>> To: dev <de...@flink.apache.org>
> >>>>> Subject: Re: [DISCUSS] Enable scala formatting check
> >>>>>
> >>>>> +1 I've never written any Scala in Flink, but this makes a lot of
> >> sense
> >>>> to
> >>>>> me. Converging on a smaller set of tools and simplifying the build is
> >>>>> always a good idea and the Community already concluded before that
> >>>> spotless
> >>>>> is generally a good approach.
> >>>>>
> >>>>> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> >>>> francesco@ververica.com>
> >>>>> wrote:
> >>>>>
> >>>>>> Hi all,
> >>>>>>
> >>>>>> I want to propose to enable the spotless scalafmt integration and
> >>>> remove
> >>>>>> the scalastyle plugin.
> >>>>>>
> >>>>>> From an initial analysis, scalafmt can do everything scalastyle can
> >>>> do, and
> >>>>>> the integration with spotless looks easy to enable:
> >>>>>> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
> >>> The
> >>>>>> scalafmt conf file gets picked up automatically from every IDE, and
> >>> it
> >>>> can
> >>>>>> be heavily tuned.
> >>>>>>
> >>>>>> This way we can unify the formatting and integrate with our CI
> >>> without
> >>>> any
> >>>>>> additional configurations. And we won't need scalastyle anymore, as
> >>>>>> scalafmt will take care of the checks:
> >>>>>>
> >>>>>> * mvn spotless:check will check both java and scala
> >>>>>> * mvn spotless:apply will format both java and scala
> >>>>>>
> >>>>>> WDYT?
> >>>>>>
> >>>>>> FG
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Francesco Guardiani | Software Engineer
> >>>>>>
> >>>>>> francesco@ververica.com
> >>>>>>
> >>>>>>
> >>>>>> <https://www.ververica.com/>
> >>>>>>
> >>>>>> Follow us @VervericaData
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> >>>>>> Conference
> >>>>>>
> >>>>>> Stream Processing | Event Driven | Real Time
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Ververica GmbH
> >>>>>>
> >>>>>> Registered at Amtsgericht Charlottenburg: HRB 158244 B
> >>>>>>
> >>>>>> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> >>>> Jason,
> >>>>>> Jinwei (Kevin) Zhang
> >>>>>>
> >>>>>
> >>>>>
> >>>>> --
> >>>>>
> >>>>> Konstantin Knauf
> >>>>>
> >>>>> https://twitter.com/snntrable
> >>>>>
> >>>>> https://github.com/knaufk
> >>>>
> >>>
> >>
> >>
> >> --
> >> Marios
> >>
>
>
Re: [DISCUSS] Enable scala formatting check
Posted by Leonard Xu <xb...@gmail.com>.
+1 from my side, thanks for driving this improvement.
Best,
Leonard
> 2022年3月2日 下午7:13,Jiangang Liu <li...@gmail.com> 写道:
>
> +1 for the feature. Good style management can help the developer a lot.
>
> Marios Trivyzas <ma...@gmail.com> 于2022年3月2日周三 18:19写道:
>
>> +1 from me as well, Having a unified auto-formatter for scala would be
>> great.
>> Currently we don't have consistency in our code base, and this makes it
>> more difficult
>> to read and work on the scala code.
>>
>> Best,
>> Marios
>>
>> On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com>
>> wrote:
>>
>>> +1, currently the scalastyle does not work well actually, there are a lot
>>> of style differences in different files. It would be great if the code
>> can
>>> be auto formatted.
>>>
>>> Best,
>>> Wenlong
>>>
>>> On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com> wrote:
>>>
>>>> +1.
>>>>
>>>> Thanks for driving.
>>>>
>>>> I wrote some scala code, the style of our flink's scala is messy. We
>>>> can do better.
>>>>
>>>> Best,
>>>> Jingsong
>>>>
>>>> On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
>>>>>
>>>>> +1
>>>>>
>>>>> I also noticed that the project of scalafmt [1] is much more active
>>> than
>>>> scalatyle [2], which has no release in the past 4 years.
>>>>>
>>>>>
>>>>> [1] https://github.com/scalameta/scalafmt/releases
>>>>> [2] https://github.com/scalastyle/scalastyle/tags
>>>>>
>>>>> Best
>>>>> Yun Tang
>>>>>
>>>>> ________________________________
>>>>> From: Konstantin Knauf <kn...@apache.org>
>>>>> Sent: Wednesday, March 2, 2022 15:01
>>>>> To: dev <de...@flink.apache.org>
>>>>> Subject: Re: [DISCUSS] Enable scala formatting check
>>>>>
>>>>> +1 I've never written any Scala in Flink, but this makes a lot of
>> sense
>>>> to
>>>>> me. Converging on a smaller set of tools and simplifying the build is
>>>>> always a good idea and the Community already concluded before that
>>>> spotless
>>>>> is generally a good approach.
>>>>>
>>>>> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
>>>> francesco@ververica.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> I want to propose to enable the spotless scalafmt integration and
>>>> remove
>>>>>> the scalastyle plugin.
>>>>>>
>>>>>> From an initial analysis, scalafmt can do everything scalastyle can
>>>> do, and
>>>>>> the integration with spotless looks easy to enable:
>>>>>> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
>>> The
>>>>>> scalafmt conf file gets picked up automatically from every IDE, and
>>> it
>>>> can
>>>>>> be heavily tuned.
>>>>>>
>>>>>> This way we can unify the formatting and integrate with our CI
>>> without
>>>> any
>>>>>> additional configurations. And we won't need scalastyle anymore, as
>>>>>> scalafmt will take care of the checks:
>>>>>>
>>>>>> * mvn spotless:check will check both java and scala
>>>>>> * mvn spotless:apply will format both java and scala
>>>>>>
>>>>>> WDYT?
>>>>>>
>>>>>> FG
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Francesco Guardiani | Software Engineer
>>>>>>
>>>>>> francesco@ververica.com
>>>>>>
>>>>>>
>>>>>> <https://www.ververica.com/>
>>>>>>
>>>>>> Follow us @VervericaData
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Join Flink Forward <https://flink-forward.org/> - The Apache Flink
>>>>>> Conference
>>>>>>
>>>>>> Stream Processing | Event Driven | Real Time
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Ververica GmbH
>>>>>>
>>>>>> Registered at Amtsgericht Charlottenburg: HRB 158244 B
>>>>>>
>>>>>> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
>>>> Jason,
>>>>>> Jinwei (Kevin) Zhang
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> Konstantin Knauf
>>>>>
>>>>> https://twitter.com/snntrable
>>>>>
>>>>> https://github.com/knaufk
>>>>
>>>
>>
>>
>> --
>> Marios
>>
Re: [DISCUSS] Enable scala formatting check
Posted by Jiangang Liu <li...@gmail.com>.
+1 for the feature. Good style management can help the developer a lot.
Marios Trivyzas <ma...@gmail.com> 于2022年3月2日周三 18:19写道:
> +1 from me as well, Having a unified auto-formatter for scala would be
> great.
> Currently we don't have consistency in our code base, and this makes it
> more difficult
> to read and work on the scala code.
>
> Best,
> Marios
>
> On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com>
> wrote:
>
> > +1, currently the scalastyle does not work well actually, there are a lot
> > of style differences in different files. It would be great if the code
> can
> > be auto formatted.
> >
> > Best,
> > Wenlong
> >
> > On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com> wrote:
> >
> > > +1.
> > >
> > > Thanks for driving.
> > >
> > > I wrote some scala code, the style of our flink's scala is messy. We
> > > can do better.
> > >
> > > Best,
> > > Jingsong
> > >
> > > On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> > > >
> > > > +1
> > > >
> > > > I also noticed that the project of scalafmt [1] is much more active
> > than
> > > scalatyle [2], which has no release in the past 4 years.
> > > >
> > > >
> > > > [1] https://github.com/scalameta/scalafmt/releases
> > > > [2] https://github.com/scalastyle/scalastyle/tags
> > > >
> > > > Best
> > > > Yun Tang
> > > >
> > > > ________________________________
> > > > From: Konstantin Knauf <kn...@apache.org>
> > > > Sent: Wednesday, March 2, 2022 15:01
> > > > To: dev <de...@flink.apache.org>
> > > > Subject: Re: [DISCUSS] Enable scala formatting check
> > > >
> > > > +1 I've never written any Scala in Flink, but this makes a lot of
> sense
> > > to
> > > > me. Converging on a smaller set of tools and simplifying the build is
> > > > always a good idea and the Community already concluded before that
> > > spotless
> > > > is generally a good approach.
> > > >
> > > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > > francesco@ververica.com>
> > > > wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > I want to propose to enable the spotless scalafmt integration and
> > > remove
> > > > > the scalastyle plugin.
> > > > >
> > > > > From an initial analysis, scalafmt can do everything scalastyle can
> > > do, and
> > > > > the integration with spotless looks easy to enable:
> > > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
> > The
> > > > > scalafmt conf file gets picked up automatically from every IDE, and
> > it
> > > can
> > > > > be heavily tuned.
> > > > >
> > > > > This way we can unify the formatting and integrate with our CI
> > without
> > > any
> > > > > additional configurations. And we won't need scalastyle anymore, as
> > > > > scalafmt will take care of the checks:
> > > > >
> > > > > * mvn spotless:check will check both java and scala
> > > > > * mvn spotless:apply will format both java and scala
> > > > >
> > > > > WDYT?
> > > > >
> > > > > FG
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > >
> > > > > Francesco Guardiani | Software Engineer
> > > > >
> > > > > francesco@ververica.com
> > > > >
> > > > >
> > > > > <https://www.ververica.com/>
> > > > >
> > > > > Follow us @VervericaData
> > > > >
> > > > > --
> > > > >
> > > > > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > > > > Conference
> > > > >
> > > > > Stream Processing | Event Driven | Real Time
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > > >
> > > > > --
> > > > >
> > > > > Ververica GmbH
> > > > >
> > > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > > >
> > > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> > > Jason,
> > > > > Jinwei (Kevin) Zhang
> > > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Konstantin Knauf
> > > >
> > > > https://twitter.com/snntrable
> > > >
> > > > https://github.com/knaufk
> > >
> >
>
>
> --
> Marios
>
Re: [DISCUSS] Enable scala formatting check
Posted by Marios Trivyzas <ma...@gmail.com>.
+1 from me as well, Having a unified auto-formatter for scala would be
great.
Currently we don't have consistency in our code base, and this makes it
more difficult
to read and work on the scala code.
Best,
Marios
On Wed, Mar 2, 2022 at 11:41 AM wenlong.lwl <we...@gmail.com> wrote:
> +1, currently the scalastyle does not work well actually, there are a lot
> of style differences in different files. It would be great if the code can
> be auto formatted.
>
> Best,
> Wenlong
>
> On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com> wrote:
>
> > +1.
> >
> > Thanks for driving.
> >
> > I wrote some scala code, the style of our flink's scala is messy. We
> > can do better.
> >
> > Best,
> > Jingsong
> >
> > On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> > >
> > > +1
> > >
> > > I also noticed that the project of scalafmt [1] is much more active
> than
> > scalatyle [2], which has no release in the past 4 years.
> > >
> > >
> > > [1] https://github.com/scalameta/scalafmt/releases
> > > [2] https://github.com/scalastyle/scalastyle/tags
> > >
> > > Best
> > > Yun Tang
> > >
> > > ________________________________
> > > From: Konstantin Knauf <kn...@apache.org>
> > > Sent: Wednesday, March 2, 2022 15:01
> > > To: dev <de...@flink.apache.org>
> > > Subject: Re: [DISCUSS] Enable scala formatting check
> > >
> > > +1 I've never written any Scala in Flink, but this makes a lot of sense
> > to
> > > me. Converging on a smaller set of tools and simplifying the build is
> > > always a good idea and the Community already concluded before that
> > spotless
> > > is generally a good approach.
> > >
> > > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> > francesco@ververica.com>
> > > wrote:
> > >
> > > > Hi all,
> > > >
> > > > I want to propose to enable the spotless scalafmt integration and
> > remove
> > > > the scalastyle plugin.
> > > >
> > > > From an initial analysis, scalafmt can do everything scalastyle can
> > do, and
> > > > the integration with spotless looks easy to enable:
> > > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala.
> The
> > > > scalafmt conf file gets picked up automatically from every IDE, and
> it
> > can
> > > > be heavily tuned.
> > > >
> > > > This way we can unify the formatting and integrate with our CI
> without
> > any
> > > > additional configurations. And we won't need scalastyle anymore, as
> > > > scalafmt will take care of the checks:
> > > >
> > > > * mvn spotless:check will check both java and scala
> > > > * mvn spotless:apply will format both java and scala
> > > >
> > > > WDYT?
> > > >
> > > > FG
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Francesco Guardiani | Software Engineer
> > > >
> > > > francesco@ververica.com
> > > >
> > > >
> > > > <https://www.ververica.com/>
> > > >
> > > > Follow us @VervericaData
> > > >
> > > > --
> > > >
> > > > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > > > Conference
> > > >
> > > > Stream Processing | Event Driven | Real Time
> > > >
> > > > --
> > > >
> > > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > > >
> > > > --
> > > >
> > > > Ververica GmbH
> > > >
> > > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > > >
> > > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> > Jason,
> > > > Jinwei (Kevin) Zhang
> > > >
> > >
> > >
> > > --
> > >
> > > Konstantin Knauf
> > >
> > > https://twitter.com/snntrable
> > >
> > > https://github.com/knaufk
> >
>
--
Marios
Re: [DISCUSS] Enable scala formatting check
Posted by "wenlong.lwl" <we...@gmail.com>.
+1, currently the scalastyle does not work well actually, there are a lot
of style differences in different files. It would be great if the code can
be auto formatted.
Best,
Wenlong
On Wed, 2 Mar 2022 at 16:34, Jingsong Li <ji...@gmail.com> wrote:
> +1.
>
> Thanks for driving.
>
> I wrote some scala code, the style of our flink's scala is messy. We
> can do better.
>
> Best,
> Jingsong
>
> On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
> >
> > +1
> >
> > I also noticed that the project of scalafmt [1] is much more active than
> scalatyle [2], which has no release in the past 4 years.
> >
> >
> > [1] https://github.com/scalameta/scalafmt/releases
> > [2] https://github.com/scalastyle/scalastyle/tags
> >
> > Best
> > Yun Tang
> >
> > ________________________________
> > From: Konstantin Knauf <kn...@apache.org>
> > Sent: Wednesday, March 2, 2022 15:01
> > To: dev <de...@flink.apache.org>
> > Subject: Re: [DISCUSS] Enable scala formatting check
> >
> > +1 I've never written any Scala in Flink, but this makes a lot of sense
> to
> > me. Converging on a smaller set of tools and simplifying the build is
> > always a good idea and the Community already concluded before that
> spotless
> > is generally a good approach.
> >
> > On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <
> francesco@ververica.com>
> > wrote:
> >
> > > Hi all,
> > >
> > > I want to propose to enable the spotless scalafmt integration and
> remove
> > > the scalastyle plugin.
> > >
> > > From an initial analysis, scalafmt can do everything scalastyle can
> do, and
> > > the integration with spotless looks easy to enable:
> > > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> > > scalafmt conf file gets picked up automatically from every IDE, and it
> can
> > > be heavily tuned.
> > >
> > > This way we can unify the formatting and integrate with our CI without
> any
> > > additional configurations. And we won't need scalastyle anymore, as
> > > scalafmt will take care of the checks:
> > >
> > > * mvn spotless:check will check both java and scala
> > > * mvn spotless:apply will format both java and scala
> > >
> > > WDYT?
> > >
> > > FG
> > >
> > >
> > >
> > > --
> > >
> > > Francesco Guardiani | Software Engineer
> > >
> > > francesco@ververica.com
> > >
> > >
> > > <https://www.ververica.com/>
> > >
> > > Follow us @VervericaData
> > >
> > > --
> > >
> > > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > > Conference
> > >
> > > Stream Processing | Event Driven | Real Time
> > >
> > > --
> > >
> > > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> > >
> > > --
> > >
> > > Ververica GmbH
> > >
> > > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> > >
> > > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung
> Jason,
> > > Jinwei (Kevin) Zhang
> > >
> >
> >
> > --
> >
> > Konstantin Knauf
> >
> > https://twitter.com/snntrable
> >
> > https://github.com/knaufk
>
Re: [DISCUSS] Enable scala formatting check
Posted by Jingsong Li <ji...@gmail.com>.
+1.
Thanks for driving.
I wrote some scala code, the style of our flink's scala is messy. We
can do better.
Best,
Jingsong
On Wed, Mar 2, 2022 at 4:19 PM Yun Tang <my...@live.com> wrote:
>
> +1
>
> I also noticed that the project of scalafmt [1] is much more active than scalatyle [2], which has no release in the past 4 years.
>
>
> [1] https://github.com/scalameta/scalafmt/releases
> [2] https://github.com/scalastyle/scalastyle/tags
>
> Best
> Yun Tang
>
> ________________________________
> From: Konstantin Knauf <kn...@apache.org>
> Sent: Wednesday, March 2, 2022 15:01
> To: dev <de...@flink.apache.org>
> Subject: Re: [DISCUSS] Enable scala formatting check
>
> +1 I've never written any Scala in Flink, but this makes a lot of sense to
> me. Converging on a smaller set of tools and simplifying the build is
> always a good idea and the Community already concluded before that spotless
> is generally a good approach.
>
> On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <fr...@ververica.com>
> wrote:
>
> > Hi all,
> >
> > I want to propose to enable the spotless scalafmt integration and remove
> > the scalastyle plugin.
> >
> > From an initial analysis, scalafmt can do everything scalastyle can do, and
> > the integration with spotless looks easy to enable:
> > https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> > scalafmt conf file gets picked up automatically from every IDE, and it can
> > be heavily tuned.
> >
> > This way we can unify the formatting and integrate with our CI without any
> > additional configurations. And we won't need scalastyle anymore, as
> > scalafmt will take care of the checks:
> >
> > * mvn spotless:check will check both java and scala
> > * mvn spotless:apply will format both java and scala
> >
> > WDYT?
> >
> > FG
> >
> >
> >
> > --
> >
> > Francesco Guardiani | Software Engineer
> >
> > francesco@ververica.com
> >
> >
> > <https://www.ververica.com/>
> >
> > Follow us @VervericaData
> >
> > --
> >
> > Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> > Conference
> >
> > Stream Processing | Event Driven | Real Time
> >
> > --
> >
> > Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
> >
> > --
> >
> > Ververica GmbH
> >
> > Registered at Amtsgericht Charlottenburg: HRB 158244 B
> >
> > Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
> > Jinwei (Kevin) Zhang
> >
>
>
> --
>
> Konstantin Knauf
>
> https://twitter.com/snntrable
>
> https://github.com/knaufk
Re: [DISCUSS] Enable scala formatting check
Posted by Yun Tang <my...@live.com>.
+1
I also noticed that the project of scalafmt [1] is much more active than scalatyle [2], which has no release in the past 4 years.
[1] https://github.com/scalameta/scalafmt/releases
[2] https://github.com/scalastyle/scalastyle/tags
Best
Yun Tang
________________________________
From: Konstantin Knauf <kn...@apache.org>
Sent: Wednesday, March 2, 2022 15:01
To: dev <de...@flink.apache.org>
Subject: Re: [DISCUSS] Enable scala formatting check
+1 I've never written any Scala in Flink, but this makes a lot of sense to
me. Converging on a smaller set of tools and simplifying the build is
always a good idea and the Community already concluded before that spotless
is generally a good approach.
On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <fr...@ververica.com>
wrote:
> Hi all,
>
> I want to propose to enable the spotless scalafmt integration and remove
> the scalastyle plugin.
>
> From an initial analysis, scalafmt can do everything scalastyle can do, and
> the integration with spotless looks easy to enable:
> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> scalafmt conf file gets picked up automatically from every IDE, and it can
> be heavily tuned.
>
> This way we can unify the formatting and integrate with our CI without any
> additional configurations. And we won't need scalastyle anymore, as
> scalafmt will take care of the checks:
>
> * mvn spotless:check will check both java and scala
> * mvn spotless:apply will format both java and scala
>
> WDYT?
>
> FG
>
>
>
> --
>
> Francesco Guardiani | Software Engineer
>
> francesco@ververica.com
>
>
> <https://www.ververica.com/>
>
> Follow us @VervericaData
>
> --
>
> Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> Conference
>
> Stream Processing | Event Driven | Real Time
>
> --
>
> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
>
> --
>
> Ververica GmbH
>
> Registered at Amtsgericht Charlottenburg: HRB 158244 B
>
> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
> Jinwei (Kevin) Zhang
>
--
Konstantin Knauf
https://twitter.com/snntrable
https://github.com/knaufk
Re: [DISCUSS] Enable scala formatting check
Posted by Konstantin Knauf <kn...@apache.org>.
+1 I've never written any Scala in Flink, but this makes a lot of sense to
me. Converging on a smaller set of tools and simplifying the build is
always a good idea and the Community already concluded before that spotless
is generally a good approach.
On Tue, Mar 1, 2022 at 5:52 PM Francesco Guardiani <fr...@ververica.com>
wrote:
> Hi all,
>
> I want to propose to enable the spotless scalafmt integration and remove
> the scalastyle plugin.
>
> From an initial analysis, scalafmt can do everything scalastyle can do, and
> the integration with spotless looks easy to enable:
> https://github.com/diffplug/spotless/tree/main/plugin-maven#scala. The
> scalafmt conf file gets picked up automatically from every IDE, and it can
> be heavily tuned.
>
> This way we can unify the formatting and integrate with our CI without any
> additional configurations. And we won't need scalastyle anymore, as
> scalafmt will take care of the checks:
>
> * mvn spotless:check will check both java and scala
> * mvn spotless:apply will format both java and scala
>
> WDYT?
>
> FG
>
>
>
> --
>
> Francesco Guardiani | Software Engineer
>
> francesco@ververica.com
>
>
> <https://www.ververica.com/>
>
> Follow us @VervericaData
>
> --
>
> Join Flink Forward <https://flink-forward.org/> - The Apache Flink
> Conference
>
> Stream Processing | Event Driven | Real Time
>
> --
>
> Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany
>
> --
>
> Ververica GmbH
>
> Registered at Amtsgericht Charlottenburg: HRB 158244 B
>
> Managing Directors: Karl Anton Wehner, Holger Temme, Yip Park Tung Jason,
> Jinwei (Kevin) Zhang
>
--
Konstantin Knauf
https://twitter.com/snntrable
https://github.com/knaufk