Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible null pointer exception and app crash during tour book import #246

Open
chrgernoe opened this issue May 30, 2021 · 1 comment
Open
Labels
bug Something isn't working

Comments

@chrgernoe
Copy link
Member

chrgernoe commented May 30, 2021

In method DatabaseWrapper._checkBitMasks() it is assumed, that if a route is found in the database, the corresponding rock entry also exists. Usually this is ensured by downloading the whole region. However, due to some database inconsistencies at sandsteinklettern.de the rock Deutschland->Sächsische Schweiz->Gebiet der Steine->Kleingießhübler Turm exists twice in the database:

The user tries to import a tour book where the wrong summit is referenced, which does not exists in the app database because of the code in SectorParser.parseRocks():

if (!_CLIMBING_OBJECT_TYPES.contains(type)) {
    continue
}

This leads then to a null pointer exception and an app crash during the import.

The app should handle this case in a proper way without just crashing.

@JoergB2: Is it possible to delete the invalid rock as well as the route entries from the database? There is also a entry in the route table which refers to this rock.

@chrgernoe chrgernoe added the bug Something isn't working label May 30, 2021
@JoergB2
Copy link

JoergB2 commented Jun 1, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants