Give RT/iter the empty input list - #5
Merged
Merged
Conversation
latest/run and sample/run both open with (.iterator (seq fs)), and in both `fs` can be empty: a zero-input (m/latest f) has no flows at all, and (m/sample f sampler) splits its varargs so the continuous inputs are (). An empty seq is nil, and a method call on nil is a NullPointerException. It only ever ran because jolt through 0.8.1 answered (.iterator nil) with an empty iterator instead of refusing it; 0.8.2 refuses it as the JVM always has, which is what surfaced this as #4. RT/iter is what clojure.core's own walkers use for this and takes nil on both hosts. The sample half was unreported and uncovered — a sampler-only sample is the single most ordinary shape of the operator. It has a row now, and it fails without the fix. Pin moved to 0.8.2 with the fix, per the cutover convention in ci.yml. Closes #4. Claude-Session: https://claude.ai/code/session_019tGgRzPx3vtr5siPkKjjLE
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #4.
Not the type-hint codegen bridges.
latest/runandsample/runboth open withand in both,
fscan be empty — a zero-input(m/latest f)has no flows at all, andsamplesplits its varargs so(m/sample f sampler)leaves()as the continuous inputs. An empty seq isnil, and a method call onnilis aNullPointerException.It only ever ran because jolt answered for the nil. Through 0.8.1
(.iterator nil)handed back an empty iterator and(.toString nil)the empty string; 0.8.2 refuses both, as the JVM always has. So this is ebb's bug, not jolt's — jolt got stricter and stopped covering it. jolt-lang/jolt#867 gates the corrected behavior so it cannot drift back.clojure.lang.RT/iteris whatclojure.core's own walkers use for exactly this, and it takesnilon both hosts (verified against Clojure 1.12.0 on a JVM and against jolt 0.8.2).The sample half was unreported
Nothing covered a sampler-only
sample, which is the single most ordinary shape of the operator:It has a row now, and it fails without the fix.
Verified
bin/testunder the released 0.8.2 binary: 283 tests, 1199 assertions, 0 failures, 0 errors, three runs.latest-test/zero-input,missionary-issues-test/latest-supports-zero-inputs-126) — the two the issue reports — plus the new sample row.JOLT_VERSIONpin moved 0.8.1 -> 0.8.2 with the fix, per the cutover convention inci.yml.The intermittent one-in-ten hang
ci.ymldocuments is untouched and unrelated.https://claude.ai/code/session_019tGgRzPx3vtr5siPkKjjLE