butterknife: @BindDimen weird bug

Have this weird bug where lint will throw an exception about @BindDimen

I had this line and it worked fine till now

@BindDimen(R.dimen.divider_margin)
int dividerMargin;

Now lint sometimes fails. Not sure if it’s an issue with AS or with butterknife. Attaching lint result screen shot 2015-08-26 at 1 11 33 am

About this issue

  • Original URL
  • State: closed
  • Created 9 years ago
  • Reactions: 1
  • Comments: 19 (6 by maintainers)

Commits related to this issue

Most upvoted comments

For the time being I’d recommend adding this to your lint.xml

    <issue id="ResourceType">
        <!-- Remove this when this is fixed: https://github.com/JakeWharton/butterknife/issues/338 -->
        <ignore path="**/*$$ViewBinder.java" />
    </issue>

Hmm. I started getting this error with butterknife-8.2.1. Using kapt (dunno if this is related).

Can this be a regression?

Just to clarify, the lint.xml file should be on your-project-folder/app/lint.xml