question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Buck project doesn't generate the correct minSdk for Android app modules

See original GitHub issue

In IntelliJ, after running buck project, library modules (android_library targets) properly have the value of android:minSdkVersion from the AndroidManifest set and do not have any inspection errors when using an API at or below that SDK level.

However, in app modules (android_library target that is depended on by an android_binary), inspection errors are shown because it thinks the android:minSdkVersion is not set and it defaults to 1. This even happens when we explicitly set the value in the android manifest for that module.

My guess as to why this is not working is because both android_binary and android_library have an entry for manifest in the rule. But I can’t seem to resolve the issue when I remove the binary target.

I can provide more details and/or sample project if necessary. This could be a result of us using OkBuck and coming from a Gradle structure.

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:1
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
cwoodwar6commented, Apr 27, 2018

Any status update on this?

0reactions
cwoodwar6commented, Nov 9, 2017

@styurin sounds good, thanks for the update.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Android Studio: Module won't show up in "Edit Configuration"
right click on project > open Module settings > Add module ( "+" sign at the top ) > Phone and Tablet Application...
Read more >
Configure the app module - Android Developers
This page describes useful app settings in the module-level build.gradle file. In addition to giving an overview of important properties set ...
Read more >
<uses-sdk> | Android Developers
Make sure to declare a android:minSdkVersion attribute in the application's manifest and set its value to the API Level of the platform version....
Read more >
Configure your build - Android Developers
Figure 1. The default project structure for an Android app module. There are a few Gradle build configuration files that are part of...
Read more >
Buck: .buckconfig
This specifies the version of the Android SDK Build-tools that all Android code in the project should be built against. By default, Buck...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found