GithubHelp home page GithubHelp logo

rlshep / bjcpbeerstyles_android Goto Github PK

View Code? Open in Web Editor NEW
9.0 9.0 4.0 187.96 MB

An Android application to display BJCP 2015 Style Guidelines

License: GNU General Public License v3.0

Java 100.00%

bjcpbeerstyles_android's People

Contributors

iafilatov avatar rlshep avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

bjcpbeerstyles_android's Issues

App for Android missing a style

Hello,

v1.0.0 of the Android Style Guidelines app is missing category 16D, Foreign Extra Stout. Love the App, thank you!

Damien

Going back from a category does not preserve the last view

Steps to reproduce:

  • Start the app
  • Scroll down to category 24 - Belgian ale
  • click on it
  • press the back button
  • it scrolls up to show the first categories

I would expect it to keep the viewport as it was before and leave it to the user if he wants to scroll up or go on selecting another category near the last one.

SQL Error loading on OnePlus devices

************ CAUSE OF ERROR ************

android.database.sqlite.SQLiteException: no such table: CATEGORY (code 1): , while compiling: SELECT _id, category_code, name, order_number, parent_id,bookmarked,revision,language FROM CATEGORY C WHERE language = 'English' AND revision = 2015.0 AND parent_id IS NULL ORDER BY order_number
at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native Method)
at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:953)
at android.database.sqlite.SQLiteConnection.prepare(SQLiteConnection.java:564)
at android.database.sqlite.SQLiteSession.prepare(SQLiteSession.java:588)
at android.database.sqlite.SQLiteProgram.(SQLiteProgram.java:58)
at android.database.sqlite.SQLiteQuery.(SQLiteQuery.java:37)
at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:44)
at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1316)
at android.database.sqlite.SQLiteDatabase.rawQuery(SQLiteDatabase.java:1255)
at io.github.rlshep.bjcp2015beerstyles.db.BjcpDataHelper.getCategories(BjcpDataHelper.java:75)
at io.github.rlshep.bjcp2015beerstyles.db.BjcpDataHelper.getAllCategories(BjcpDataHelper.java:42)
at io.github.rlshep.bjcp2015beerstyles.CategoryListTab.setupCategoryListView(CategoryListTab.java:40)
at io.github.rlshep.bjcp2015beerstyles.CategoryListTab.onCreateView(CategoryListTab.java:28)
at android.support.v4.app.Fragment.performCreateView(Fragment.java:1962)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1067)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1248)
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:738)
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1613)
at android.support.v4.app.FragmentManagerImpl.executePendingTransactions(FragmentManager.java:570)
at android.support.v4.app.FragmentStatePagerAdapter.finishUpdate(FragmentStatePagerAdapter.java:163)
at android.support.v4.view.ViewPager.populate(ViewPager.java:1106)
at android.support.v4.view.ViewPager.populate(ViewPager.java:952)
at android.support.v4.view.ViewPager.onMeasure(ViewPager.java:1474)
at android.view.View.measure(View.java:17578)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:875)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:613)
at android.view.View.measure(View.java:17578)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5536)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:436)
at android.support.v7.widget.ContentFrameLayout.onMeasure(ContentFrameLayout.java:135)
at android.view.View.measure(View.java:17578)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5536)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1436)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:722)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:613)
at android.view.View.measure(View.java:17578)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5536)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:436)
at android.view.View.measure(View.java:17578)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5536)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1436)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:722)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:613)
at android.view.View.measure(View.java:17578)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:5536)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:436)
at com.android.internal.policy.impl.PhoneWindow$DecorView.onMeasure(PhoneWindow.java:2615)
at android.view.View.measure(View.java:17578)
at android.view.ViewRootImpl.performMeasure(ViewRootImpl.java:2015)
at android.view.ViewRootImpl.measureHierarchy(ViewRootImpl.java:1173)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1379)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1061)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5891)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:767)
at android.view.Choreographer.doCallbacks(Choreographer.java:580)
at android.view.Choreographer.doFrame(Choreographer.java:550)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:753)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5300)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:699)

************ DEVICE INFORMATION ***********
Brand: OnePlus
Device: OnePlus2
Model: ONE A2003
Id: LMY47V
Product: OnePlus2

************ FIRMWARE ************
SDK: 22
Release: 5.1.1
Incremental: 56

Above the log output

Tab headers now showing on all devices

the problem - the headings 'Categories', 'Bookmarks', etc, on the main screen don't appear on my phone, although when I press where the headings should be I am taken to the correct section.

I have a Motorola running Android, if that helps.
Screenshot_20190905-123814

Invalid note

30C under notes starts off with "Autumn Seasonal Beers" and should read "Winter Seasonal Beer"

Add Plato?

This reference tool would be even more useful if the user had the option to toggle the gravity numbers to Plato.

Error when searching the word "fuller's"

When searching the word "fuller's", the next error appears

************ CAUSE OF ERROR ************

java.lang.RuntimeException: Unable to start activity ComponentInfo{io.github.rlshep.bjcp2015beerstyles/io.github.rlshep.bjcp2015beerstyles.SearchResultsActivity}: android.database.sqlite.SQLiteException: near "s": syntax error (code 1): , while compiling: SELECT right FROM SYNONYMS WHERE language = 'English' AND UPPER(left) = UPPER('fuller's')
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2659)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2724)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1473)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6123)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)
Caused by: android.database.sqlite.SQLiteException: near "s": syntax error (code 1): , while compiling: SELECT right FROM SYNONYMS WHERE language = 'English' AND UPPER(left) = UPPER('fuller's')
at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native Method)
at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:889)
at android.database.sqlite.SQLiteConnection.prepare(SQLiteConnection.java:500)
at android.database.sqlite.SQLiteSession.prepare(SQLiteSession.java:588)
at android.database.sqlite.SQLiteProgram.(SQLiteProgram.java:58)
at android.database.sqlite.SQLiteQuery.(SQLiteQuery.java:37)
at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:44)
at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1318)
at android.database.sqlite.SQLiteDatabase.rawQuery(SQLiteDatabase.java:1257)
at io.github.rlshep.bjcp2015beerstyles.db.BjcpDataHelper.searchSynonyms(BjcpDataHelper.java:211)
at io.github.rlshep.bjcp2015beerstyles.db.BjcpDataHelper.search(BjcpDataHelper.java:192)
at io.github.rlshep.bjcp2015beerstyles.SearchResultsActivity.onCreate(SearchResultsActivity.java:38)
at android.app.Activity.performCreate(Activity.java:6672)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1140)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2612)
... 9 more

************ DEVICE INFORMATION ***********
Brand: motorola
Model: Moto G (4)

************ FIRMWARE ************
SDK: 24
Release: 7.0
Incremental: 5

Sometimes crashes on reload

Jan 19, 9:25 PM on app version 146
Huawei nova 3i (HWINE), Android 8.1
Report 1 of 1
java.lang.RuntimeException:
at android.app.ActivityThread.performResumeActivity (ActivityThread.java:4278)
at android.app.ActivityThread.handleResumeActivity (ActivityThread.java:4319)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:2065)
at android.os.Handler.dispatchMessage (Handler.java:109)
at android.os.Looper.loop (Looper.java:166)
at android.app.ActivityThread.main (ActivityThread.java:7555)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:469)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:963)
Caused by: java.lang.NullPointerException:
at io.github.rlshep.bjcp2015beerstyles.MainActivity.onRestart (MainActivity.java:160)
at android.app.Instrumentation.callActivityOnRestart (Instrumentation.java:1352)
at android.app.Activity.performRestart (Activity.java:7438)
at android.app.Activity.performResume (Activity.java:7449)
at android.app.ActivityThread.performResumeActivity (ActivityThread.java:4246)

Translating to other languages

Hello Richard. Thank you for the great app!

I know someone who'd be willing to translate BJCP into Ukrainian and have it in the app as well. I've poked around the code a bit and IIUC most, if not all, strings are contained in BjcpBeerStyles.db. I can provide you with the translated version of the same db. If you are willing to support the effort, could you please answer a couple of questions?

  1. Is it enough to translate just the BjcpBeerStyles.db or are there any other strings (i.e. UI) that would need to be translated that are not in the DB?
  2. I'm guessing that some kind of fall-back to English would be required for when the English DB is updated before the translated DB is. Do you think it would be possible for you to implement such fallback? If not, any hints and recommendations on how you would do it would be greatly appreciated.
  3. Any other considerations re/ translation that you might have as someone who knows the code best? Anything you think worth mentioning?

Crashes trying to view cider/perry styles

The app crashes when trying to view any of the cider/perry styles. I got a capture of the relevant part of the dump. It looks like the app is crashing because it's trying to get the SRM (color) of the style and gets a null. The cider styles don't have SRM or IBU for stats, only the gravities and ABV.

capture-bjcp15-error.

Scottish beers, cat 14

"Schilling" is not, and has never been, the correct spelling for any British coinage. It is the Germanic spelling. Referring to "Scottish schilling ales" is wrong, it should be "Scottish Shilling Ales".

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.