Reputation: 560
Last night, I upgrade my android studio from 3.0.1 to 3.1, and rebuild my project, and I got the error as show below.
CHECKED LIST:
compileSdkVersion 27
buildToolsVersion '27.0.3'
classpath 'com.android.tools.build:gradle:3.1.0'
implementation 'com.android.support:appcompat-v7:27.1.0'
implementation 'com.android.support:design:27.1.0'
Upvotes: 4
Views: 2567
Reputation: 2387
Even though my first answer works, it's actually a hassle because the issue keeps on reoccurring, especially after I switch branches (for different development or code reviews). So, I read further and found this answer:
Switch your support lib version - either to a newer ver (27.1.1 stable as of now), or to an older version & back to current.
It's an alternative and seems to work.
Related issues from issuetracker: 77211616, 77938563, 73536373
Upvotes: 1
Reputation: 2387
As mentioned in this question:
Basically, close & re-open the project.. worked for me (after even invalidating cache didn't work).
Related issues from issuetracker: 77211616, 77938563, 73536373
Upvotes: 18