B13: Binance commission rebates sign-flipped into fake fee disposals
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 78/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- typescript
- Domain
- cli
Research direction
Start in binance/csv.ts at lines 367 and 213, tracing how operation names are classified and how the fee check precedes income handling. Add coverage for Commission Rebate as positive income and Commission Fee as a fee, then run the relevant test suite. Done means rebates retain a positive income leg and fees retain fee treatment without sign errors.
Written by the indexing model from the issue text.
Description
VERIFIED. binance/csv.ts:367:
return value.includes('fee') || value.includes('commission');
Binance ledger operations Commission Rebate, Commission Fee Shared With You, and
Commission History are positive income, but they match includes('commission'). Line 213 then
negates the positive change and flags it as a fee. isFeeOperation is also tested before
isIncomeOperation, so the income branch is unreachable for these rows.
input: 1,2024-01-15 12:00:00,Spot,Commission Rebate,USDT,5,
observed: { type: 'fee_only', legs: [{ USDT, -5, feeFlag: true }] }
expected: { type: 'income', legs: [{ USDT, +5 }] }
$5 of income is dropped and a bogus $5 deductible disposal is invented — a 2x error on the amount.
What's needed
- Match rebate/shared-commission operations as income before the fee check
- Test both
Commission Rebate(income) andCommission Fee(fee) so the precedence is pinned
Extracted from a repo audit performed 2026-07 (the audit doc it came from was proposed via an unmerged docs PR).
- Dominant language
- TypeScript
- Stars
- 1
- Forks
- 0
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 7
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from gfargo/daybook
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement needs-verification
Difficulty 5/5 Over a week Newbie friendliness 35/100
-
documentation needs-verification
Difficulty 5/5 Over a week Newbie friendliness 35/100
-
enhancement needs-verification
Difficulty 5/5 Over a week Newbie friendliness 32/100
-
enhancement needs-verification
Difficulty 5/5 Over a week Newbie friendliness 25/100
Similar issues
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 91/100
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 95/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100