Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v1] Fix things found by custom ktlint rules #1728

Merged
merged 4 commits into from
Jan 24, 2025
Merged

Conversation

alancai98
Copy link
Member

@alancai98 alancai98 commented Jan 23, 2025

Relevant Issues

  • None

Description

  • Fixes issues found by custom ktlint rules. These include
    • Using top-level internal functions and values
    • Using top-level public functions and values without a @JvmName specified for the file
  • Fixes typing and overflow behavior of AVG and SUM aggregation functions

License Information

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@alancai98 alancai98 self-assigned this Jan 23, 2025
Copy link

github-actions bot commented Jan 23, 2025

CROSS-ENGINE-REPORT ❌

BASE (LEGACY-V0.14.8) TARGET (EVAL-E6BE5EB) +/-
% Passing 89.67% 94.96% 5.29% ✅
Passing 5287 5618 331 ✅
Failing 609 74 -535 ✅
Ignored 0 224 224 🔶
Total Tests 5896 5916 20 ✅

Testing Details

  • Base Commit: v0.14.8
  • Base Engine: LEGACY
  • Target Commit: e6be5eb
  • Target Engine: EVAL

Result Details

  • ❌ REGRESSION DETECTED. See Now Failing/Ignored Tests. ❌
  • Passing in both: 2622
  • Failing in both: 18
  • Ignored in both: 0
  • PASSING in BASE but now FAILING in TARGET: 16
  • PASSING in BASE but now IGNORED in TARGET: 102
  • FAILING in BASE but now PASSING in TARGET: 179
  • IGNORED in BASE but now PASSING in TARGET: 0

Now FAILING Tests ❌

The complete list can be found in GitHub CI summary, either from Step Summary or in the Artifact.

Now IGNORED Tests ❌

The complete list can be found in GitHub CI summary, either from Step Summary or in the Artifact.

Now Passing Tests

179 test(s) were previously failing in BASE (LEGACY-V0.14.8) but now pass in TARGET (EVAL-E6BE5EB). Before merging, confirm they are intended to pass.

The complete list can be found in GitHub CI summary, either from Step Summary or in the Artifact.

CROSS-COMMIT-REPORT ❌

BASE (EVAL-F3A65FF) TARGET (EVAL-E6BE5EB) +/-
% Passing 94.96% 94.96% 0.00% ✅
Passing 5618 5618 0 ✅
Failing 74 74 0 ✅
Ignored 224 224 0 ✅
Total Tests 5916 5916 0 ✅

Testing Details

  • Base Commit: f3a65ff
  • Base Engine: EVAL
  • Target Commit: e6be5eb
  • Target Engine: EVAL

Result Details

  • ❌ REGRESSION DETECTED. See Now Failing/Ignored Tests. ❌
  • Passing in both: 5618
  • Failing in both: 74
  • Ignored in both: 224
  • PASSING in BASE but now FAILING in TARGET: 8
  • PASSING in BASE but now IGNORED in TARGET: 0
  • FAILING in BASE but now PASSING in TARGET: 8
  • IGNORED in BASE but now PASSING in TARGET: 0

Now FAILING Tests ❌

The following 8 test(s) were previously PASSING in BASE but are now FAILING in TARGET:

Click here to see
  1. structs should be ordered by data types (DESC) (nulls first as default for desc), compileOption: PERMISSIVE
  2. structs should be ordered by data types (DESC) (nulls first as default for desc), compileOption: STRICT
  3. group by with where, compileOption: PERMISSIVE
  4. group by with where, compileOption: STRICT
  5. group by with group as and where, compileOption: PERMISSIVE
  6. group by with group as and where, compileOption: STRICT
  7. repeated field on struct is ambiguous{identifier:"REPEATED",cn:9,bn:"REPEATED"}, compileOption: STRICT
  8. repeated field on struct is ambiguous{identifier:" "repeated" ",cn:10,bn:"repeated"}, compileOption: STRICT

Now Passing Tests

The following 8 test(s) were previously FAILING in BASE but are now PASSING in TARGET. Before merging, confirm they are intended to pass:

Click here to see
  1. repeated field on struct is ambiguous{identifier:"REPEATED",cn:9,bn:"REPEATED"}, compileOption: STRICT
  2. repeated field on struct is ambiguous{identifier:" "repeated" ",cn:10,bn:"repeated"}, compileOption: STRICT
  3. structs should be ordered by data types (DESC) (nulls first as default for desc), compileOption: PERMISSIVE
  4. structs should be ordered by data types (DESC) (nulls first as default for desc), compileOption: STRICT
  5. group by with where, compileOption: PERMISSIVE
  6. group by with where, compileOption: STRICT
  7. group by with group as and where, compileOption: PERMISSIVE
  8. group by with group as and where, compileOption: STRICT


// TODO docs + further cleanup
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(self-review) attempted to fix overflow and typing behavior of AVG and SUM in c841580 (#1728). Still have to verify and do some further cleanup here and in NumberUtils

@codecov-commenter
Copy link

codecov-commenter commented Jan 24, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.03%. Comparing base (4bf549b) to head (59fa4ce).
Report is 19 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##               main    #1728   +/-   ##
=========================================
  Coverage     80.03%   80.03%           
  Complexity       47       47           
=========================================
  Files            19       19           
  Lines           506      506           
  Branches         23       23           
=========================================
  Hits            405      405           
  Misses           88       88           
  Partials         13       13           
Flag Coverage Δ
EXAMPLES 80.03% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@alancai98 alancai98 changed the title [wip][v1] Fix things found by custom ktlint rules [v1] Fix things found by custom ktlint rules Jan 24, 2025
@alancai98 alancai98 requested a review from johnedquinn January 24, 2025 22:02
@alancai98 alancai98 marked this pull request as ready for review January 24, 2025 22:12
Copy link
Member

@johnedquinn johnedquinn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Nice work.

@alancai98 alancai98 merged commit 8c5f0b4 into main Jan 24, 2025
14 checks passed
@alancai98 alancai98 deleted the main-final-audit branch January 24, 2025 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants