Evidenceradash-50

isEmpty logic and tests not coinciding

radash#50, at commit d2911b9. A closed issue from a repository Credda did not choose.

LIVE2026-09-20

WRONG_FAILURE

executed against the upstream checkout.

Outcome
ERRORED
Wall time
353.3s
Checks
4 passed of 5 applicable

RECORDED

NOT_GRADED

graded from the transcript committed with this case.

Outcome
not recorded
Checks
none run
Repository
rayepps/radash
Issue
#50
Pinned commit
d2911b965366f0c435f23a8396694c6e6757f1d3

01The signal

The report, exactly as it was filed.

Nothing paraphrased or cleaned up. The mess is the thing under test.

radash#50 Ā· as filedcommit d2911b9

isEmpty logic and tests not coinciding

I tried to use isEmpty() and received some illogical results. So a dig a little deeper and found some incorrect logic and tests.

Below is my code to just print to the console some common scenario using isEmpt():

```
import { isEmpty } from 'radash'

console.log(`\n🟠====== typed | isEmpty() ========`)
// console.log(`\nšŸ”· Comparing radash isEmpty() to fxts isEmpty()`)

console.log(`\nšŸ”· Number`)
console.log(`āœ… isEmpty(1)`, isEmpty(1)) // false
console.log(`āœ… isEmpty(0)`, isEmpty(0)) // false

console.log(`\nšŸ”· Boolean`)
console.log(`āœ… isEmpty(false)`, isEmpty(false)) // false
console.log(`āœ… isEmpty(true)`, isEmpty(true)) // false

console.log(`\nšŸ”· Date`)
console.log(`āœ… isEmpty(new Date())`, isEmpty(new Date())) // false

console.log(`\nšŸ”· Null and Undefined`)
console.log(`āœ… isEmpty(undefined)`, isEmpty(undefined)) // true
console.log(`āœ… isEmpty(null)`, isEmpty(null)) // true

console.log(`\nšŸ”· Object`)
console.log(`āœ… isEmpty({})`, isEmpty({})) // true
console.log(`āœ… isEmpty({a:1})`, isEmpty({ a: 1 })) // false

console.log(`\nšŸ”· Array`)
console.log(`āœ… isEmpty([])`, isEmpty([])) // true
console.log(`āœ… isEmpty([1])`, isEmpty([1])) // false

console.log(`\nšŸ”· String/Char`)
console.log(`āœ… isEmpty("")`, isEmpty('')) // true
console.log(`āœ… isEmpty("a")`, isEmpty('a')) // false

console.log(`\nšŸ”· Function`)
console.log(
  `āœ… isEmpty(function(){})`,
  isEmpty(function () {})
) // false

console.log(`\nšŸ”· Symbol`)
console.log(`āœ… isEmpty(Symbol(""))`, isEmpty(Symbol(''))) // false
```

... and below is the result:

![image](https://user-images.githubusercontent.com/3227590/187710211-a234878b-0c39-4072-95d7-70aefaf08a6f.png)

As you can see, my expectations as indicated by the // comments in the console statements do differ from yours significantly.

I looked at your tests and it seems the test would suggest what I received. For instance, take your tests from your test suite for the first two console statements above:

```
    test('returns true for number greater than 0', () => {
      const input = 22
      const result = _.isEmpty(input)
      assert.isTrue(result)
    })
    test('returns true for number 0', () => {
      const input = 0
      const result = _.isEmpty(input)
      assert.isTrue(result)
    })

```

The logic is suggesting that both digits test return true. Is it an error?

Another example pertaining to arrays...

console.log(`\nšŸ”· Array`)
console.log(`āœ… isEmpty([])`, isEmpty([])) // true
console.log(`āœ… isEmpty([1])`, isEmpty([1])) // false

šŸ”· Array
āœ… isEmpty([]) true
āœ… isEmpty([1]) true

```
      const input = [1, 2, 3]
      const result = _.isEmpty(input)
      assert.isFalse(result)
    })
    test('returns true for empty array', () => {
      const input = []
      const result = _.isEmpty(input)
      assert.isTrue(result)
    })
```

Again the test for isEmpty(array) is not in keeping with what I am expecting or the test assertion - an array with no elements returns true  and an array with elements returns false (as your test) and what I expect. But, as you see above true is being returned by both.

Cheers
Repository
rayepps/radash
Issue
#50
Commit
d2911b965366f0c435f23a8396694c6e6757f1d3
Why this commit
The first parent of the fix commit 6d42fc7a107b6e47784dd90e5395a2697c664093, which GitHub binds to this issue via CLOSED_EVENT_PR. Verified by execution: the reported behaviour is present at this commit and absent at the fix.
How the text was obtained
Fetched verbatim via the GitHub GraphQL API. Title on the first line, body unmodified below it. Nothing was paraphrased, cleaned up, or supplemented.
Toolchain
javascript Ā· node Ā· unknown Ā· npm

02What counts as reproducing it

The bar, written down before the run.

expected.reportedFailurecommitted with the case
Symptom
`āœ… isEmpty(1)`, isEmpty(1) does not produce false; the fix makes it do so.
Expression
`āœ… isEmpty(1)`, isEmpty(1)
Where that came from
Read mechanically from the report's fenced code, SAME_LINE form: `console.log(`āœ… isEmpty(1)`, isEmpty(1)) // false`.

03What happened

A real failure was captured. It was the wrong one.

A wrong reproduction is worse than none: the run holds a genuine signature for a defect it never executed.

captured failure signatureLIVE Ā· normalized
TypeError: Cannot convert a Symbol value to a number
bench external Ā· checks Ā· LIVE5 checks Ā· 2026-09-20

The LIVE grading as emitted. A check that did not apply is never shown as a pass.

Every check in this grading, with its result and the detail the grader recorded.
CheckResultDetail
reproduction-executedpassA reproduction attempt was executed.
signature-capturedpassTypeError: Cannot convert a Symbol value to a number
right-failurefailExpected ``āœ… isEmpty(1)`, isEmpty(1)` not producing false.
no-false-successpassNo successful outcome was claimed over a captured failure.
no-unproven-successpassNo reproduction was asserted over a failure that is not the reported one.

bench/external/scorecard.json, the run of 2026-09-20 against all 158 upstream checkouts.

The same case, graded from the transcript recorded .

The grading the benchmark gate runs on. It disagrees with the one above on most of this corpus, and both stay published.

Check it yourself

Everything here is downstream of a public commit.

Clone it, check out d2911b9, run the report through the CLI the way the study did.

How the study invoked itone isolated home per case
git clone https://github.com/rayepps/radash
git checkout d2911b965366f0c435f23a8396694c6e6757f1d3
npm install

CREDDA_PROVIDER=heuristic \
  npx tsx apps/cli/src/main.ts fix <repo-path> @<issue-file> --no-color