FrontendStatic: Fix crash on invalid configuration #7984

Open
phnt wants to merge 1 commit from frontendstatic-nil-config-crash into develop
Member

Will instead serve the bundled FE, unless the user also placed the frontend files in instance/static/frontends//, ie. without placing them in the folder.

Companion to pleroma/pleroma!7983 which prevents users from setting the invalid config via ConfigDB. But an invalid config can still be specified via *.secret.exs.

Checklist

  • Adding a changelog: In the changelog.d directory, create a file named <code>.<type>.
Will instead serve the bundled FE, unless the user also placed the frontend files in instance/static/frontends/<FE>/<files here>, ie. without placing them in the <ref> folder. Companion to pleroma/pleroma!7983 which prevents users from setting the invalid config via ConfigDB. But an invalid config can still be specified via `*.secret.exs`. ### Checklist - [X] Adding a changelog: In the `changelog.d` directory, create a file named `<code>.<type>`. <!-- `<code>` can be anything, but we recommend using a more or less unique identifier to avoid collisions, such as the branch name. `<type>` can be `add`, `change`, `remove`, `fix`, `security` or `skip`. `skip` is only used if there is no user-visible change in the PR (for example, only editing comments in the code). Otherwise, choose a type that corresponds to your change. In the file, write the changelog entry. For example, if a PR adds group functionality, we can create a file named `group.add` and write `Add group functionality` in it. If one changelog entry is not enough, you may add more. But that might mean you can split it into two PRs. Only use more than one changelog entry if you really need to (for example, when one change in the code fix two different bugs, or when refactoring). -->
FrontendStatic: Fix crash on invalid configuration
All checks were successful
ci/woodpecker/pr/changelog Pipeline was successful
ci/woodpecker/pr/lint Pipeline was successful
ci/woodpecker/pr/unit-testing-elixir-1.19 Pipeline was successful
ci/woodpecker/pr/unit-testing-elixir-1.15 Pipeline was successful
deff445b3e
Will instead serve the bundled FE, unless the user also placed the
frontend files in instance/static/frontends/<FE>/<files here>,
ie. without placing them in the <ref> folder.
All checks were successful
ci/woodpecker/pr/changelog Pipeline was successful
ci/woodpecker/pr/lint Pipeline was successful
ci/woodpecker/pr/unit-testing-elixir-1.19 Pipeline was successful
ci/woodpecker/pr/unit-testing-elixir-1.15 Pipeline was successful
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin frontendstatic-nil-config-crash:frontendstatic-nil-config-crash
git switch frontendstatic-nil-config-crash

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch develop
git merge --no-ff frontendstatic-nil-config-crash
git switch frontendstatic-nil-config-crash
git rebase develop
git switch develop
git merge --ff-only frontendstatic-nil-config-crash
git switch frontendstatic-nil-config-crash
git rebase develop
git switch develop
git merge --no-ff frontendstatic-nil-config-crash
git switch develop
git merge --squash frontendstatic-nil-config-crash
git switch develop
git merge --ff-only frontendstatic-nil-config-crash
git switch develop
git merge frontendstatic-nil-config-crash
git push origin develop
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
pleroma/pleroma!7984
No description provided.