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

Blank map when launching example app more than once #318

Open
nferrissey opened this issue Jun 6, 2024 · 9 comments
Open

Blank map when launching example app more than once #318

nferrissey opened this issue Jun 6, 2024 · 9 comments

Comments

@nferrissey
Copy link

nferrissey commented Jun 6, 2024

Hello team,

I've run into an issue with 4.18.4.0.109997 of the here SDK for Android, so I thought I would spin up your example app to see what I was doing wrong but found the issue there also.

Running the HelloMapKotlin example from Android Studio on an emulator, the map will only display on the first run. Launching the app more than once results in a blank map and a message in LogCat along the lines of "Unable to open '/data/app/~~FN1KmexT1NahqDEMDdnGrA==/com.here.hellomap-5F3elBTtwt5POHdMiZhrUA==/base.dm': No such file or directory
"
EDIT
It looks like the crux of the issue is that the map is cached on first run but the map tiles can't be read on subsequent runs:
[WARN ] hsdk-FileSystemPosix - Opening directory failed, error=kIOError - No such file or directory, directory_path='/data/user/0/com.here.hellomap/files/v1/FdSKs9s1eYIxEw5lKN2mGQ/ocm-map//ARCHIVES/5e'

Any ideas would be appreciated.


The error does not occur on a real device, only the emulator.

Are there extra steps required to run the examples on an emulator, without having to uninstall before every run?

Thanks :)

@HERE-SDK-Support-Team
Copy link
Contributor

HERE-SDK-Support-Team commented Jun 10, 2024

Hi @nferrissey, thanks for reporting!

We'll look into this issue as soon as possible. Is this issue happening for you also with other example apps? I.e. the "HelloMap" application? And, if possible, can you share which Android Studio version and emulator set-up you are using? Thank you.

@nferrissey
Copy link
Author

Hi, thanks for the reply.

Yes, unfortunately it happens with any app that uses the SDK. I'm running these examples using Android Studio Jellyfish and Android emulator 34.2.14-11834374. I've tried a few versions in case it was a new bug.

I have tried these examples, my own native app and a .Net app via a binding library with the same results. Fine on a physical device, but the map will only appear once on an emulator, unless I uninstall (or force stop and clear cache) between runs. The force stop and clearing the cache is a new discovery today which leads me to believe the SDK might have some permissions issues on an emulator?

Cheers.

@ipawanshukla
Copy link

Hi ,
We tried to reproduce your issue but we are unable to reproduce it. We tried on Android Studio Jellyfish, Iguana, Giraffe and Dolphin . This issue seems to be emulator specific and not with the physical devices. Could you please let us know your emulator setup, openGL version, current JDK version ?

Thanks!

@nferrissey
Copy link
Author

Thanks for trying :)

I have updated Android Studio to latest:

Android Studio Jellyfish | 2023.3.1 Patch 2
Build #AI-233.14808.21.2331.11926650, built on June 5, 2024

The emulator is 34.2.15-11906825

Run the sample - first time OK, second time heaps of log cat entries along the lines of:

2024-06-12 18:19:47.700 10593-10691 FileSystemPosix com.here.hellomap W [WARN ] FileSystemPosix - Opening directory failed, error=kIOError - No such file or directory, directory_path='/data/user/0/com.here.hellomap/files/v1/FdSKs9s1eYIxEw5lKN2mGQ/ocm-map//ARCHIVES/17'

2024-06-12 18:19:47.700 10593-10691 FileSystemPosix com.here.hellomap W [WARN ] hsdk-FileSystemPosix - Opening directory failed, error=kIOError - No such file or directory, directory_path='/data/user/0/com.here.hellomap/files/v1/FdSKs9s1eYIxEw5lKN2mGQ/ocm-map//ARCHIVES/17'

I notice the "//" in the file path before the ARCHIVES folder...that's probably not helping it load cached files, and causing a blank map, but I don't know why it would be doing that.

@ipawanshukla
Copy link

Thank you for the information but can you please confirm -

  1. Exact emulator set up such as Storage, Ram size and CPU configs?
  2. When you are experiencing this issue , are other components working? Like the button is rendered and upon clicking the button you are able to see the route?
  3. Is it like some part of the map not loading , have you tried panning or pinching the map?

The logs that you have shared are WARN level logs and they are there for just information. In cases like this Error level logs are shown.

@nferrissey
Copy link
Author

  1. Emulator: x86_64, API34, 2GB RAM, 4GB Storage
  2. Map displays fine on first run, no Warn messages in log, everything good. Start app again and nothing works unless app cache is cleared or uninstalled. No visual components appear. Pinching/zooming results in many log entries like these:

**
2024-06-14 07:56:37.423 11804-11916 FileSystemPosix com.here.routing W [WARN ] hsdk-FileSystemPosix - Opening directory failed, error=kIOError - No such file or directory, directory_path='/data/user/0/com.here.routing/files/v1/FdSKs9s1eYIxEw5lKN2mGQ/ocm-map//ARCHIVES/c0'
2024-06-14 07:56:37.424 11804-11916 FileSystemPosix com.here.routing W [WARN ] FileSystemPosix - Opening directory failed, error=kIOError - No such file or directory, directory_path='/data/user/0/com.here.routing/files/v1/FdSKs9s1eYIxEw5lKN2mGQ/ocm-map//ARCHIVES/c2'

and

2024-06-14 07:46:21.502 11012-11200 DataRepository com.here.hellomap I [INFO ] DataRepository - GetBlobData not found in cache, hrn='hrn:here:data::olp-here:ocm', key='C72082C2ACD05740F0B00219C9A1C72F.128'
2024-06-14 07:46:21.502 11012-11200 DataRepository com.here.hellomap I [INFO ] hsdk-DataRepository - GetBlobData not found in cache, hrn='hrn:here:data::olp-here:ocm', key='C72082C2ACD05740F0B00219C9A1C72F.128'
2024-06-14 07:46:21.502 11012-11200 VersionedL...ClientImpl com.here.hellomap W [WARN ] VersionedLayerClientImpl - GetAggregatedData: failed to load data, key=1476121, data_handle=C72082C2ACD05740F0B00219C9A1C72F.128
2024-06-14 07:46:21.502 11012-11200 VersionedL...ClientImpl com.here.hellomap W [WARN ] hsdk-VersionedLayerClientImpl - GetAggregatedData: failed to load data, key=1476121, data_handle=C72082C2ACD05740F0B00219C9A1C72F.128
2024-06-14 07:46:21.503 11012-11199 DataRepository com.here.hellomap I [INFO ] DataRepository - GetBlobData not found in cache, hrn='hrn:here:data::olp-here:ocm', key='C72082C2ACD05740F0B00219C9A1C72F.128'
2024-06-14 07:46:21.504 11012-11199 DataRepository com.here.hellomap I [INFO ] hsdk-DataRepository - GetBlobData not found in cache, hrn='hrn:here:data::olp-here:ocm', key='C72082C2ACD05740F0B00219C9A1C72F.128'
2024-06-14 07:46:21.504 11012-11199 VersionedL...ClientImpl com.here.hellomap W [WARN ] VersionedLayerClientImpl - GetAggregatedData: failed to load data, key=1476121, data_handle=C72082C2ACD05740F0B00219C9A1C72F.128
2024-06-14 07:46:21.504 11012-11199 VersionedL...ClientImpl com.here.hellomap W [WARN ] hsdk-VersionedLayerClientImpl - GetAggregatedData: failed to load data, key=1476121, data_handle=C72082C2ACD05740F0B00219C9A1C72F.128 **

  1. I have tried the Routing sample and get the same results. Works first time. Second run the map is blank, clicking the Add Route button shows the dialog but the map control remains completely blank.

@HERE-SDK-Support-Team
Copy link
Contributor

Thanks a lot, we are currently investigating the issue.

@andriiudovenko
Copy link

I manged to reproduce the issue using an Android emulator with Emulated Performance Graphics: Hardware. It’s an Android emulator issue.
I tried different emulator versions and Android Emulator (34.1.20) Stable is the latest stable version where the issue isn’t reproducible.

There is a log indicated about OpenGL errors:
emuglGLESv2_enc com.here.hellomap device/generic/goldfish-opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glGetUniformLocation:2206 GL error 0x502

And this is a known issue with the emulator, and it occurs not only on HERE SDK apps:
https://issuetracker.google.com/issues/345674553
flutter/flutter#146890

Also I have checked different versions of Android Emulators:
Android Emulator (35.1.14) Canary - Reproduced
Android Emulator (34.2.14) Stable - Reproduced
Android Emulator (34.2.13) Stable - Reproduced
Android Emulator (34.1.20) Stable - Not Reproduced

Please use Android Emulator (34.1.20) Stable version until Google fixes the issue: https://issuetracker.google.com/issues/345674553

@nferrissey
Copy link
Author

Hi,

Thanks for investigating and putting so much effort in.

Looks like I'll have to put up with clearing the cache before every run for the time being as the location functionality in the Android Emulator is also broken for versions before 34.2.13 ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants