JakeWharton / JakeWharton/timber
Timber lint check does not consider formatting string using indexing for backreferences
- Dominant language
- Kotlin
- Stars
- 10.8k
- Forks
- 994
- Avg merge
- 17h 16m
- Merged PRs (30d)
- 17
Description
Given code:
`Timber.d("setMeasuredDimension(%d, %1$d)", size);`
or
`Timber.d("setMeasuredDimension(%1$d, %1$d)", size);`
Actual result:
Lint warns about invalid argument count for formatting string
Lint outputs:

Actual result:
No lint warning with proper format string including backreferences
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by locating the Timber lint check that validates formatting-string argument counts, then reproduce the issue with the two Java snippets in the report. The fix is done when indexed backreferences such as %1$d no longer produce false warnings while genuinely invalid argument counts still do.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100