Skip to content

Fix Shiny app UTF-8 decoding and normalize app-side qs2 reads - #411

Draft
anna-abelman with Copilot wants to merge 16 commits into
fsl-quickstart-guide-updatesfrom
copilot/update-quick-start-guide
Draft

Fix Shiny app UTF-8 decoding and normalize app-side qs2 reads#411
anna-abelman with Copilot wants to merge 16 commits into
fsl-quickstart-guide-updatesfrom
copilot/update-quick-start-guide

Conversation

Copilot AI commented Jul 23, 2026

Copy link
Copy Markdown

The Shiny app was still rendering existing emoji UI text as mojibake on some environments, and several app flows were still surfacing qs2::qs_read(...) native-encoding warnings. This change fixes the app-side decoding path and routes the remaining serialized model reads through the existing UTF-8 normalization wrapper.

  • UTF-8 source loading for app modules

    • Add encoding = "UTF-8" to runtime source() calls in the main app entrypoints.
    • Covers both the current app entrypoints and the legacy heavy UI/server entrypoints so hard-coded UI strings are decoded correctly before Shiny renders them.
  • Normalize remaining app-side .qs2 reads

    • Replace direct qs2::qs_read(qs2_path) calls in Shiny model/design/policy modules with the existing read_qs2_utf8() helper.
    • Ensures these code paths suppress the known native-encoding warning and normalize character/factor payloads after deserialization.
  • Scope cleanup

    • Revert the unrelated quickstart emoji edits from the earlier pass so this PR is limited to the actual app encoding issue.
# Before
source("modules/load_files_server.R", local = TRUE)
d_obj <- qs2::qs_read(qs2_path)

# After
source("modules/load_files_server.R", local = TRUE, encoding = "UTF-8")
d_obj <- read_qs2_utf8(qs2_path)

Copilot AI and others added 16 commits July 23, 2026 00:25
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Co-authored-by: anna-abelman <165065127+anna-abelman@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants