Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed Credits view crashing and unhardcoded AUTHORS file name/path #19739

Merged
merged 1 commit into from Nov 12, 2021

Conversation

penev92
Copy link
Member

@penev92 penev92 commented Oct 11, 2021

The CREDITS view has been crashing because it can't find the AUTHORS file, most likely since the restructuring of the repository and the introduction of the bin folder.
Turns out that is only a problem when not specifically setting a different working directory (which I assume the launch scripts do, which is a whole lot of "why"s in itself, but I'm not going to go down that rabbit hole in this PR), so is probably only reproducible when running from Visual Studio (idk about Rider).

@pchote
Copy link
Member

pchote commented Oct 11, 2021

The proper fix here will be to change https://github.com/OpenRA/OpenRA/blob/bleed/OpenRA.Mods.Common/Widgets/Logic/CreditsLogic.cs#L43 to use Platform.ResolvePath("^EngineDir|AUTHORS").

@penev92
Copy link
Member Author

penev92 commented Oct 11, 2021

To be fair I kind of wanted to avoid that so I don't have to test the packaged build too. Also the proper fix would be to move that to the mod.yaml file entirely (despite this being the engine's credits file as well, it is the mods who present it) like we do for third-party mods that have their own credits file.

@pchote
Copy link
Member

pchote commented Oct 11, 2021

the mod.yaml path would still be ^EngineDir|AUTHORS, but sure, I won't complain at the self-scope-creep 😁

OpenRA.Mods.Common/Widgets/Logic/CreditsLogic.cs Outdated Show resolved Hide resolved
OpenRA.Mods.Common/ModCredits.cs Outdated Show resolved Hide resolved
Moved the file name/path to ModCredits, read from mod.yaml
@penev92 penev92 changed the title Copy AUTHORS to the bin directory Fixed Credits view crashing and unhardcoded AUTHORS file name/path Oct 12, 2021
@penev92
Copy link
Member Author

penev92 commented Oct 12, 2021

Reworked/updated/fixed.

@abcdefg30 abcdefg30 added this to the Next release milestone Oct 12, 2021
@abcdefg30 abcdefg30 added the hacktoberfest-accepted Label to mark PRs as accepted for the Hacktoberfest label Nov 1, 2021
@Mailaender Mailaender merged commit a71da0a into OpenRA:bleed Nov 12, 2021
@Mailaender
Copy link
Member

Changelog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest-accepted Label to mark PRs as accepted for the Hacktoberfest PR: Needs +2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants