Depend on the correct moFile for a given md file. #31
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We need the correct title for a given languages translated documentation, which comes from the moFile. However, the previous version of the build script accidentally depended on a variable assigned inside the for loop which was used to assign the languages actual moFile. This loop variable is assigned inside the loop, and not outside it, is overridden on each iteration, and is not persisted anywhere so we cann reference the correct moFile when we later generate the html. This pr fixes that. in this pr, I create a moByLang dictionary, and store the moFile as a value. The key for this moFile is the language code. That way, the html for language KR depends on the moFile for kr, and not the moFile for whatever language was last assigned in the for loop. That way, if the ES languagges po file updates, the dependency system will correctly attribute that Korean is the language we need to regenenrate HTML for. This also undoes the try/except logic that incorrectly hid the real issue, which was the inappropriate refrencing of a for loop variable that may have never been created.