[PR #670] [MERGED] Diff cell utf-8 truncation #700

Closed
opened 2026-02-26 22:32:10 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/670
Author: @cursor[bot]
Created: 2/20/2026
Status: Merged
Merged: 2/20/2026
Merged by: @rudrankriyam

Base: feat/metadata-diff-586Head: cursor/diff-cell-utf-8-truncation-3c73


📝 Commits (2)

  • 010a11e Fix UTF-8-safe truncation in localization diff cells
  • fc08ed2 fix: harden diff cell truncation and utf-8 coverage

📊 Changes

2 files changed (+76 additions, -2 deletions)

View changed files

📝 internal/cli/diffcmd/localizations.go (+8 -2)
internal/cli/diffcmd/localizations_test.go (+68 -0)

📄 Description

Summary

  • Fixes a bug in sanitizeDiffCell where byte-based string truncation could split multi-byte UTF-8 characters, resulting in garbled output. The truncation logic now operates on runes to ensure character integrity. A new test case has been added to validate this behavior.

Validation

  • make format
  • make lint
  • make test


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/670 **Author:** [@cursor[bot]](https://github.com/apps/cursor) **Created:** 2/20/2026 **Status:** ✅ Merged **Merged:** 2/20/2026 **Merged by:** [@rudrankriyam](https://github.com/rudrankriyam) **Base:** `feat/metadata-diff-586` ← **Head:** `cursor/diff-cell-utf-8-truncation-3c73` --- ### 📝 Commits (2) - [`010a11e`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/010a11e0a5bc999b3648be3eb1779fc61010e4a8) Fix UTF-8-safe truncation in localization diff cells - [`fc08ed2`](https://github.com/rudrankriyam/App-Store-Connect-CLI/commit/fc08ed21d6b52330286709e2358f3ce5aa91c302) fix: harden diff cell truncation and utf-8 coverage ### 📊 Changes **2 files changed** (+76 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `internal/cli/diffcmd/localizations.go` (+8 -2) ➕ `internal/cli/diffcmd/localizations_test.go` (+68 -0) </details> ### 📄 Description ## Summary - Fixes a bug in `sanitizeDiffCell` where byte-based string truncation could split multi-byte UTF-8 characters, resulting in garbled output. The truncation logic now operates on runes to ensure character integrity. A new test case has been added to validate this behavior. ## Validation - [x] `make format` - [x] `make lint` - [x] `make test` --- --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-26 22:32:10 +03:00
Sign in to join this conversation.
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
starred/App-Store-Connect-CLI#700
No description provided.