Dymerz / StarCitizen-Localization

Language File Installation Guide
Creative Commons Zero v1.0 Universal
44 stars 38 forks source link

Issue with Git Action Workflow Validator on Handling Empty Entries #257

Closed ROBdk97 closed 7 months ago

ROBdk97 commented 7 months ago

Description:

Problem:

The current Git Action workflow validator fails to handle empty entries appropriately. When encountering an empty entry in the format of:

Mtps_killallcreatures_multitype__hard_desc_01=

The validator mistakenly reports it as missing, even though it's a valid entry according to the source file (in this case, the English global.ini).

Expected Behavior:

The validator should recognize empty entries as valid, reflecting the behavior of the source file.

Steps to Reproduce:

  1. Include an empty entry in the format specified above in the source file.
  2. Run the Git Action workflow validator.

Actual Result:

The validator reports the empty entry as missing, leading to a false-positive error:

Validating keys...

Unable to find key "Mtps_killallcreatures_multitype__hard_desc_01"
=> 🔥 One or more keys are missing in source file

Expected Result:

The validator should recognize the empty entry as valid, without reporting it as missing:

Validating keys...

No missing keys found in the source file.
Dymerz commented 7 months ago

Nice catch! I'm working on a fix

Dymerz commented 7 months ago

I am able to reproduce this behavior, but I don't fully understand the problem. In my view, all keys defined in english/global.ini should be included in the target .ini file. This is important because if the game fails to resolve a key in the translation file, the key will be displayed in the game UI/GUI, which should be avoided.

In the specific scenario:

# ./reference.ini
Mtps_killallcreatures_multitype__hard_desc_01=
# ./target.ini
Mtps_killallcreatures_multitype__hard_desc_01=

No errors are triggered, which suggests that the key is properly handled in this case.

Could you provide more context or details about any potential issues you've observed?

ROBdk97 commented 7 months ago

I messed up. It's missing in the German global.ini and the validation is falling because of that.