Skip to content

Use Iterable for PartiQLValue collections rather than Sequence #1305

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

Merged
merged 2 commits into from
Dec 14, 2023

Conversation

rchowell
Copy link
Contributor

Relevant Issues

N/A

Description

A sequence gets exhausted after consumed once which does not make it a good option for the default backing field. This PR replaces the collection data structure with the Iterable interface. This allows requesting a new iterator which gives freedom in the implementation of the backing structure. You can use sequences or lazily-generated iterators, but importantly this is not the default.

Other Information

  • Updated Unreleased Section in CHANGELOG: [YES/NO]
    Yes

  • Any backward-incompatible changes? [YES/NO]
    No. PartiQLValue is considered experimental.

  • Any new external dependencies? [YES/NO]
    No

  • Do your changes comply with the Contributing Guidelines
    and Code Style Guidelines? [YES/NO]
    Yes

License Information

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

Copy link

github-actions bot commented Dec 13, 2023

Conformance comparison report

Base (6ab6f27) 840dd8c +/-
% Passing 92.54% 92.54% 0.00%
✅ Passing 5384 5384 0
❌ Failing 434 434 0
🔶 Ignored 0 0 0
Total Tests 5818 5818 0

Number passing in both: 5384

Number failing in both: 434

Number passing in Base (6ab6f27) but now fail: 0

Number failing in Base (6ab6f27) but now pass: 0

@codecov-commenter
Copy link

Codecov Report

Attention: 18 lines in your changes are missing coverage. Please review.

Comparison is base (6ab6f27) 72.21% compared to head (68b92ad) 72.20%.
Report is 1 commits behind head on main.

Files Patch % Lines
.../kotlin/org/partiql/cli/utils/ServiceLoaderUtil.kt 0.00% 18 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1305      +/-   ##
============================================
- Coverage     72.21%   72.20%   -0.02%     
  Complexity     2100     2100              
============================================
  Files           222      222              
  Lines         16021    16024       +3     
  Branches       2892     2895       +3     
============================================
  Hits          11570    11570              
- Misses         3635     3638       +3     
  Partials        816      816              
Flag Coverage Δ
CLI 13.41% <0.00%> (-0.03%) ⬇️
EXAMPLES 80.28% <ø> (ø)
LANG 80.58% <ø> (ø)

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.

@rchowell rchowell merged commit 79ee005 into main Dec 14, 2023
@rchowell rchowell deleted the value-iterables branch December 14, 2023 23:15
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