I’m trying to integrate DJI Mobile SDK v5 on my Android project. I follwed the instruction from here text
While compiling I’m getiing the following error from value.xml files,
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:493: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3317: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3318: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3319: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3320: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3322: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3325: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3326: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3588: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3589: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3590: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3591: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3592: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3595: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3596: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3598: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3599: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3600: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3601: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
dji-sdk-v5-aircraft-5.8.0resvalues-devalues-de.xml:3629: error: multiple substitutions specified in non-positional format; did you mean to add the formatted="false" attribute?.
The issue is with the value.xml contents that is packed inside the AAR file.
<string name="dji_msdk_error_uas_area_code_not_same_hip">The current country code is %1s, but the actual country code of the device is %2s</string>
The correct format is %$1 but the DJI SDK value.xml file has %1 only. So the above string should be like this,
<string name="dji_msdk_error_uas_area_code_not_same_hip">The current country code is %$1s, but the actual country code of the device is %$2s</string>
Tried to modify the XML files. This resolved the issue partially. Because there are lots of xml file containing 10K+ records. I cannot edit one by one.
Biswajit Sarkar is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.