Description:
The Stallion Android SDK requires PascalCase string resource names (StallionProjectId and StallionAppToken) in strings.xml, which conflicts with Android's standard naming convention requiring lowercase identifiers (a-z0-9_).
Current Documentation:
The installation guide shows:
<resources>
<string name="StallionProjectId">66ed03380eb95c9c316256d3</string>
<string name="StallionAppToken">spb_FTLx5umZ...</string>
</resources>
The Problem:
Android best practices and linting tools flag PascalCase resource names as violations
Some teams have strict AAPT configurations that may enforce lowercase-only naming
This creates inconsistency with other resources in the project
Attempted Workaround (didn't work):
<!-- strings.xml -->
<string name="stallion_project_id">66ed03380eb95c9c316256d3</string>
<string name="stallion_app_token">spb_FTLx5umZ...</string>
<!-- AndroidManifest.xml -->
<meta-data android:name="StallionProjectId" android:value="@string/stallion_project_id" />
<meta-data android:name="StallionAppToken" android:value="@string/stallion_app_token" />
The SDK doesn't read from manifest meta-data, only directly from string resources.
Current Working Solution:
Using PascalCase names directly (works but triggers linting warnings):
<string name="StallionProjectId">@string/STALLION_OTA_PROJECT_ID</string>
<string name="StallionAppToken">@string/STALLION_OTA_APP_TOKEN</string>
Suggested Fix:
Update the SDK to support either:
Option A (Backward Compatible):
Read from manifest meta-data if present, fall back to string resources
// Check manifest first
val projectId = context.packageManager
.getApplicationInfo(context.packageName, PackageManager.GET_META_DATA)
.metaData?.getString("StallionProjectId")
?: context.getString(R.string.stallion_project_id) // Fallback to lowercase resource
Option B (Simpler):
Only support lowercase resource names and update documentation
// SDK reads from lowercase resources
context.getString(R.string.stallion_project_id)
context.getString(R.string.stallion_app_token)
Both approaches would align with Android conventions while maintaining developer experience.
Environment:
Stallion SDK version: [2.3.2]
React Native: 0.77
Build tool: Gradle 8.x
Target SDK: 34
Description:
The Stallion Android SDK requires PascalCase string resource names (
StallionProjectIdandStallionAppToken) instrings.xml, which conflicts with Android's standard naming convention requiring lowercase identifiers (a-z0-9_).Current Documentation:
The installation guide shows:
The Problem:
Android best practices and linting tools flag PascalCase resource names as violations
Some teams have strict AAPT configurations that may enforce lowercase-only naming
This creates inconsistency with other resources in the project
Attempted Workaround (didn't work):
The SDK doesn't read from manifest meta-data, only directly from string resources.
Current Working Solution:
Using PascalCase names directly (works but triggers linting warnings):
Suggested Fix:
Update the SDK to support either:
Option A (Backward Compatible):
Read from manifest meta-data if present, fall back to string resources
Option B (Simpler):
Only support lowercase resource names and update documentation
Both approaches would align with Android conventions while maintaining developer experience.
Environment:
Stallion SDK version: [2.3.2]
React Native: 0.77
Build tool: Gradle 8.x
Target SDK: 34