5

Hi there I am getting this error while getting nearby locations.

P.S My device has no sim card let me know if you think this will be a problem.

responseErrorCode errorCode = 10017 errorReason = SIGNATURE_INVALID

I have searched here but couldn't find the reason. Result Code link

Here is the certificate mentioned in build.gradle

  signingConfigs {
    config {
        storeFile file('keystore.jks')
        storePassword '*****'
        keyPassword '*****'
        keyAlias 'key'
        v1SigningEnabled true
        v2SigningEnabled true
    }
}

Here is the SS of huawei console. Huawei console

Here the complete log.

I/HMSSDK_PendingResultImpl: setResult:0 I/HMSSDK_BaseAdapter: baseCallBack.onComplete I/HMSSDK_HmsClient: receive msg status_code:0, error_code0, api_name:location.requestLocationUpdates, app_id:104565291|, pkg_name:com.ogoul.kalamtime, session_id:, transaction_id:104565291pdates20210813103016514894175, resolution:null I/HMSSDK_RequestLocationUpdatesTaskApiCall: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|doExecute I/HMSSDK_TidCacheManager: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|list to find size is:1 I/HMSSDK_TidCacheManager: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|find tid in list, tid:71d9bb75-f532-45e2-8e2f-4cbd89a41eb2 I/HMSSDK_RequestLocationUpdatesTaskApiCall: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|doExecute onLocationResult I/HMSSDK_RequestLocationUpdatesTaskApiCall: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|modify numUpdates with callback, numUpdates:2147483647 , locationSize:1 I/HMSSDK_RequestLocationUpdatesTaskApiCall: |71d9bb75-f532-45e2-8e2f-4cbd89a41eb2|handleOnResultMessage code:1 I/HMSSDK_PendingResultImpl: setResult:0 I/HMSSDK_BaseAdapter: baseCallBack.onComplete I/HMSSDK_HmsClient: receive msg status_code:1, error_code10017, api_name:site.nearbySearch, app_id:104565291|, pkg_name:com.ogoul.kalamtime, session_id:, transaction_id:104565291Search20210813103016121420275, resolution:null E/HmsSiteKit_NearbySearchTaskApiCall_73: responseErrorCode errorCode = 10017 errorReason = SIGNATURE_INVALID I/TAG: Error : 010017 SIGNATURE_INVALID I/HMSSDK_HuaweiApiManager: sendRequest I/HMSSDK_HmsClient: post msg api_name:site.nearbySearch, app_id:104565291|, pkg_name:com.ogoul.kalamtime, sdk_version:50200300, session_id:*, transaction_id:104565291Search20210813103022971741021, kitSdkVersion:0, apiLevel:10 I/HMSSDK_BaseAdapter: in baseRequest + uri is :site.nearbySearch, transactionId is : 104565291Search20210813103022971741021 I/HMSSDK_PendingResultImpl: init uri:site.nearbySearch I/HMSSDK_PendingResultImpl: setResultCallback

zhangxaochen
  • 32,744
  • 15
  • 77
  • 108
Uzair Mughal
  • 309
  • 4
  • 15
  • Have you generated a signing certificate fingerprint and added it on the Appgallery Connect website (see [this guide](https://developer.huawei.com/consumer/en/codelab/HMSPreparation/index.html#3))? If so, make you that you signed your app with the signing certificate that matches that fingerprint. – Michael Aug 12 '21 at 11:00
  • @Michael I have already allowed site api in manage apis and app signing certificate is also added. – Uzair Mughal Aug 12 '21 at 11:04
  • @Michael I have edited the question with SS – Uzair Mughal Aug 12 '21 at 11:07
  • 1
    getting nearby locations failed or success? Is there more error log about this question? – Matrix Aug 13 '21 at 01:50
  • @Anna obviously it failed. – Uzair Mughal Aug 13 '21 at 05:25

2 Answers2

2

I have solved this issue. Issue was my testing device doesn't have a Sim card it and automatically devices get time according to service providers. Simply insert sim card and install few updates and BINGO. error solved.

Uzair Mughal
  • 309
  • 4
  • 15
0
responseErrorCode errorCode = 10017 errorReason = SIGNATURE_INVALID

This error code indicates that the request signature is invalid.

It is recommended that you to check whether the device time was manually changed. If so, change it back and try again.

For details, See Result Codes.

zhangxaochen
  • 32,744
  • 15
  • 77
  • 108
  • Time is already set automatically using Network Time zone. Anyhow I have changed it to manual and vice versa but still no success. – Uzair Mughal Aug 12 '21 at 11:33
  • hi@Uzair Mughal, You can use Postman to test the WebAPI and check whether any error is reported. like this: https://i.stack.imgur.com/VGl8B.png .See [Docs link](https://developer.huawei.com/consumer/en/doc/development/HMSCore-References/webapi-nearby-search-0000001050163873). – zhangxaochen Aug 12 '21 at 11:53
  • Sorry for the delay. I have checked the key with post man request it is working fine there. – Uzair Mughal Aug 12 '21 at 12:16
  • hi@Uzair Mughal, could you pls provide your complete log, so that we can analyse your problem. – zhangxaochen Aug 13 '21 at 02:04
  • 1
    I have edited the question with the log. Kindly have a look. – Uzair Mughal Aug 13 '21 at 05:34
  • hi@Uzair Mughal, sorry but according the log you provided above , it's still hard to locate this issue. Could you kindly help us with some more log information to locate this issue? The procedure for capturing logs is as follows: 1. Run the following command to connect to the device: adb logcat –v time > D:\hwsite.txt 2. Reproduce the fault. 3. Press Ctrl+C to complete log capture. – zhangxaochen Aug 13 '21 at 08:20
  • Also, The log format provided is a bit unclear. Could you mind adjust the format before providing it? Thx a lot! – zhangxaochen Aug 13 '21 at 08:28
  • 1
    Thanks for your time but the issue is solved. Kindly check my answer. – Uzair Mughal Aug 13 '21 at 08:56
  • 1
    Great! Should you need help with anything else, please feel free to reach out back to us. – zhangxaochen Aug 13 '21 at 09:03