piggilypoo
Aspiring developer
Profile
Posts: 172
Reg: Jun 28, 2011
San Diego
5,120
04/25/15 03:11 PM (9 years ago)

Interactive Quiz error with Android Studio

Tried to compile an app today with Android Studio that includes the Interactive Quiz plugin. I get the following error when trying to build the apk: Note: Some input files use or override a deprecated API. Note: Recompile with -Xlint:deprecation for details. :app:lintVitalRelease C:UsersMyUserDesktopMyAppNameappsrcmain eslayoutt_screen_quiz.xml:70: Error: @+id/txtScore is not a sibling in the same RelativeLayout [NotSibling] android:layout_below="@+id/txtScore" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Explanation for issues of type "NotSibling": Layout constraints in a given RelativeLayout should reference other views within the same relative layout. 1 errors, 0 warnings FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':app:lintVitalRelease'. > Lint found fatal errors while assembling a release target. To proceed, either fix the issues identified by lint, or modify your build script as follows: ... android { lintOptions { checkReleaseBuilds false // Or, if you prefer, you can continue to check for errors in release builds, // but continue the build even when errors are found: abortOnError false } } ... * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED
 
krompa
Lost but trying
Profile
Posts: 257
Reg: Jun 14, 2013
Bristol
8,820
like
04/28/15 01:48 AM (9 years ago)
This is a strange one because txtScore is a sibling in the Relative layout. Have you altered any code in the xml file or corresponding bt_screen_quiz.java file relating to either the txtScore or the txtQuestion text views? I haven't moved over to Android Studio yet - so no expert on AS. But I did a quick search on the internet and found a couple of posts with the same problem, but no solution. They reported the problems arose when upgrading to a later version of AS.
 
LA
Aspiring developer
Profile
Posts: 3278
Reg: Aug 16, 2012
Jerseyville, IL
42,880
like
04/29/15 06:21 AM (9 years ago)
Did you try to fix with lint fix? Not sure if Studio has it but if it does, it should be when you right click and run lint check (I believe that's what it is called). Also, if you didn't change any code, then try a clean and refresh and maybe a restart. Logcat actually says this? To proceed, either fix the issues identified by lint, or modify your build script as follows: ... android { lintOptions { checkReleaseBuilds false // Or, if you prefer, you can continue to check for errors in release builds, // but continue the build even when errors are found: abortOnError false } } LA
 
piggilypoo
Aspiring developer
Profile
Posts: 172
Reg: Jun 28, 2011
San Diego
5,120
like
04/30/15 07:51 AM (9 years ago)
I'm not to sure how to do anything with lint in Android Studio, I'm still used to eclipse. I know I didn't change any of the code though. And yea that message showed up in the Android Studio log
 
ridgerock
Veteran developer
Profile
Posts: 183
Reg: May 19, 2011
Louisville
1,830
like
05/13/15 12:19 PM (8 years ago)
I wish I could provide some help here but I'm in the same boat with this problem. So far it's the only plugin that I own that gives me problems within Android Studio.
 
Louie
Code is Art
Profile
Posts: 40
Reg: Dec 31, 2012
Toronto
400
like
06/18/15 10:07 AM (8 years ago)
I just encountered the same issue. I solved it by adding "tools:ignore="NotSibling" to the end of Answer_1 in the "bt_screen_quiz.xml". So the code looks like this: <Button android:id="@+id/btnAnswer_1" android:layout_width="fill_parent" android:layout_height="58dip" android:gravity="center_vertical|center_horizontal" android:layout_marginLeft="5dip" android:layout_marginRight="5dip" android:text="Answer 1" android:textSize="18dip" android:layout_below="@+id/txtScore" tools:ignore="NotSibling" /> Hope that helped
 
Jaundice101
I hate code!
Profile
Posts: 19
Reg: Apr 12, 2012
Davis, CA
4,590
like
02/28/16 12:51 AM (8 years ago)
I am having this exact same problem myself. I attempted the fix suggested by Louie, but couldn't make it work. Just adds another problem. "Unbound prefix." If anyone else has discovered any work arounds it'd be appreciated.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.