codeant-ai-for-open-source[bot] commented on code in PR #39064:
URL: https://github.com/apache/superset/pull/39064#discussion_r3476294643
##########
superset/translations/tr/LC_MESSAGES/messages.po:
##########
@@ -1136,46 +1213,46 @@ msgid "Add report"
msgstr "Rapor Ekle"
msgid "Add required control values to preview chart"
-msgstr ""
+msgstr "Grafikleri önizlemek için gerekli kontrol değerleri ekleyin"
msgid "Add required control values to save chart"
-msgstr ""
+msgstr "Grafik kaydetmek için gerekli kontrol değerleri ekleyin"
msgid "Add sheet"
msgstr "Sayfa ekle"
msgid "Add tag to entities"
-msgstr ""
+msgstr "Varlıklara etiket ekleyin"
msgid "Add the name of the chart"
msgstr "Grafiğin adını ekleyin"
msgid "Add the name of the dashboard"
-msgstr "Dashboardın adını ekleyin"
+msgstr "G?sterim Paneliın adını ekleyin"
#, fuzzy
msgid "Add theme"
msgstr "Sayfa ekle"
msgid "Add to dashboard"
-msgstr "Dashboarda ekle"
+msgstr "G?sterim Paneline ekle"
#, fuzzy
msgid "Add to tabs"
-msgstr "Dashboarda ekle"
+msgstr "G?sterim Paneline ekle"
msgid "Added"
msgstr "Eklendi"
#, python-format
msgid "Added 1 new column to the virtual dataset"
msgid_plural "Added %s new columns to the virtual dataset"
-msgstr[0] ""
+msgstr[0] "%s Sanal veri kümesine 1 yeni sütun eklendi"
Review Comment:
**Suggestion:** This pluralized entry hardcodes `1 yeni sütun` while also
interpolating `%s`, so counts greater than 1 will render incorrect text (for
example, "5 ... 1 yeni sütun"). Remove the hardcoded `1` and phrase it to work
with the interpolated count for all values. [logic error]
<details>
<summary><b>Severity Level:</b> Major ⚠️</summary>
```mdx
- ⚠️ Turkish toast misreports added virtual dataset columns.
- ⚠️ Can confuse users when syncing dataset schema.
```
</details>
<details>
<summary><b>Steps of Reproduction ✅ </b></summary>
```mdx
1. Open the dataset editor UI, which uses `DatasourceEditor`
(superset-frontend/src/components/Datasource/components/DatasourceEditor/DatasourceEditor.tsx:1225–1238)
to sync columns from the underlying table.
2. Click the control that triggers `fetchSyncedColumns` and `updateColumns`,
so that
`updateColumns` in
superset-frontend/src/components/Datasource/utils/index.ts:150–25
compares current and new columns and populates `columnChanges.added` with
every new
column.
3. When two or more new columns are detected, `columnChanges.added.length`
is > 0 and the
toast at index.ts:35–23 executes `tn('Added 1 new column to the virtual
dataset', 'Added
%s new columns to the virtual dataset', columnChanges.added.length,
columnChanges.added.length)`.
4. In Turkish, the PO entry at
superset/translations/tr/LC_MESSAGES/messages.po:1248–1250
uses a single `msgstr[0] "%s Sanal veri kümesine 1 yeni sütun eklendi"` and
`Plural-Forms:
nplurals=1; plural=0`, so for `columnChanges.added.length = 5` the toast
will render "5
Sanal veri kümesine 1 yeni sütun eklendi", incorrectly hardcoding "1 yeni
sütun" for all
counts.
```
</details>
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=5eeceed6243c47b396d1ab38caef078a&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
[](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt_id=5eeceed6243c47b396d1ab38caef078a&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
*(Use Cmd/Ctrl + Click for best experience)*
<details>
<summary><b>Prompt for AI Agent 🤖 </b></summary>
```mdx
This is a comment left during a code review.
**Path:** superset/translations/tr/LC_MESSAGES/messages.po
**Line:** 1248:1250
**Comment:**
*Logic Error: This pluralized entry hardcodes `1 yeni sütun` while also
interpolating `%s`, so counts greater than 1 will render incorrect text (for
example, "5 ... 1 yeni sütun"). Remove the hardcoded `1` and phrase it to work
with the interpolated count for all values.
Validate the correctness of the flagged issue. If correct, How can I resolve
this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask
user if the user wants to fix the rest of the comments as well. if said yes,
then fetch all the comments validate the correctness and implement a minimal fix
```
</details>
<a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=d2302d85ffe3ed973b8c5acc24bd75887a10ea66cf3b25d0819f12de24be71de&reaction=like'>👍</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=d2302d85ffe3ed973b8c5acc24bd75887a10ea66cf3b25d0819f12de24be71de&reaction=dislike'>👎</a>
##########
superset/translations/tr/LC_MESSAGES/messages.po:
##########
@@ -1136,46 +1213,46 @@ msgid "Add report"
msgstr "Rapor Ekle"
msgid "Add required control values to preview chart"
-msgstr ""
+msgstr "Grafikleri önizlemek için gerekli kontrol değerleri ekleyin"
msgid "Add required control values to save chart"
-msgstr ""
+msgstr "Grafik kaydetmek için gerekli kontrol değerleri ekleyin"
msgid "Add sheet"
msgstr "Sayfa ekle"
msgid "Add tag to entities"
-msgstr ""
+msgstr "Varlıklara etiket ekleyin"
msgid "Add the name of the chart"
msgstr "Grafiğin adını ekleyin"
msgid "Add the name of the dashboard"
-msgstr "Dashboardın adını ekleyin"
+msgstr "G?sterim Paneliın adını ekleyin"
#, fuzzy
msgid "Add theme"
msgstr "Sayfa ekle"
msgid "Add to dashboard"
-msgstr "Dashboarda ekle"
+msgstr "G?sterim Paneline ekle"
#, fuzzy
msgid "Add to tabs"
-msgstr "Dashboarda ekle"
+msgstr "G?sterim Paneline ekle"
msgid "Added"
msgstr "Eklendi"
#, python-format
msgid "Added 1 new column to the virtual dataset"
msgid_plural "Added %s new columns to the virtual dataset"
-msgstr[0] ""
+msgstr[0] "%s Sanal veri kümesine 1 yeni sütun eklendi"
#, fuzzy, python-format
msgid "Added to 1 dashboard"
msgid_plural "Added to %s dashboards"
-msgstr[0] "1 Dashboarda eklendi"
+msgstr[0] "%s 1 G?sterim Paneline eklendi"
Review Comment:
**Suggestion:** This pluralized message hardcodes `1` in the dashboard text,
so values like `%s = 3` still show as if one dashboard was affected. Replace
the fixed `1` with a count-safe phrasing. [logic error]
<details>
<summary><b>Severity Level:</b> Major ⚠️</summary>
```mdx
- ⚠️ Turkish metadata bar misstates dashboards containing chart.
- ⚠️ Can mislead users managing chart–dashboard relationships.
```
</details>
<details>
<summary><b>Steps of Reproduction ✅ </b></summary>
```mdx
1. Open a saved chart in Explore, where the metadata bar is configured via
`useExploreMetadataBar`
(superset-frontend/src/explore/components/ExploreChartHeader/useExploreMetadataBar.tsx:7–26).
2. Ensure the chart is attached to multiple dashboards so that
`metadata.dashboards.length` is greater than 1 in the metadata response.
3. In this case, the hook renders the dash-count item title using `tn('Added
to 1
dashboard', 'Added to %s dashboards', metadata.dashboards.length,
metadata.dashboards.length)` at useExploreMetadataBar.tsx:11–17.
4. Under the Turkish locale, the translation in
superset/translations/tr/LC_MESSAGES/messages.po:1254–1256 defines a single
`msgstr[0] "%s
1 G?sterim Paneline eklendi"` with `Plural-Forms: nplurals=1; plural=0`, so
for a chart on
3 dashboards the label still says "1 G?sterim Paneline eklendi", incorrectly
indicating
only one dashboard.
```
</details>
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=eca923f78a8c45f9a2ecccdb271dcc6b&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
[](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt_id=eca923f78a8c45f9a2ecccdb271dcc6b&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
*(Use Cmd/Ctrl + Click for best experience)*
<details>
<summary><b>Prompt for AI Agent 🤖 </b></summary>
```mdx
This is a comment left during a code review.
**Path:** superset/translations/tr/LC_MESSAGES/messages.po
**Line:** 1254:1256
**Comment:**
*Logic Error: This pluralized message hardcodes `1` in the dashboard
text, so values like `%s = 3` still show as if one dashboard was affected.
Replace the fixed `1` with a count-safe phrasing.
Validate the correctness of the flagged issue. If correct, How can I resolve
this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask
user if the user wants to fix the rest of the comments as well. if said yes,
then fetch all the comments validate the correctness and implement a minimal fix
```
</details>
<a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=969a119169e1e1a48a3f30169dafb14a2b4b941e75a8ce935c8ab5cb0060d4ee&reaction=like'>👍</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=969a119169e1e1a48a3f30169dafb14a2b4b941e75a8ce935c8ab5cb0060d4ee&reaction=dislike'>👎</a>
##########
superset/translations/tr/LC_MESSAGES/messages.po:
##########
@@ -8476,7 +8853,7 @@ msgstr "Son düzenleme %s"
#, python-format
msgid "Modified 1 column in the virtual dataset"
msgid_plural "Modified %s columns in the virtual dataset"
-msgstr[0] ""
+msgstr[0] "%s Sanal veri kümesindeki 1 sütunu Değiştirdi"
Review Comment:
**Suggestion:** This pluralized translation also hardcodes `1 sütunu`, which
makes messages incorrect for counts other than 1. Use a neutral/count-driven
form so the same translation remains correct for every numeric value. [logic
error]
<details>
<summary><b>Severity Level:</b> Major ⚠️</summary>
```mdx
- ⚠️ Turkish toast misreports modified virtual dataset columns.
- ⚠️ Undermines trust in metadata sync feedback.
```
</details>
<details>
<summary><b>Steps of Reproduction ✅ </b></summary>
```mdx
1. In the dataset editor, trigger a metadata sync where existing columns
change type or
datetime-ness so that `updateColumns` marks them as modified
(superset-frontend/src/components/Datasource/utils/index.ts:150–22).
2. When at least one column is modified, `columnChanges.modified` is
populated, and the
toast at index.ts:35–43 calls `tn('Modified 1 column in the virtual
dataset', 'Modified %s
columns in the virtual dataset', columnChanges.modified.length,
columnChanges.modified.length)`.
3. For Turkish, the plural catalog entry at
superset/translations/tr/LC_MESSAGES/messages.po:8854–8856 sets `msgstr[0]
"%s Sanal veri
kümesindeki 1 sütunu Değiştirdi"` with `Plural-Forms: nplurals=1; plural=0`,
so this
single translation is used regardless of `columnChanges.modified.length`.
4. As a result, a case like `columnChanges.modified.length = 3` will show a
toast reading
"3 Sanal veri kümesindeki 1 sütunu Değiştirdi", mixing the correct count
placeholder with
a hardcoded "1 sütunu" and misrepresenting how many columns were actually
modified.
```
</details>
[](https://app.codeant.ai/fix-in-ide?tool=cursor&prompt_id=a0516a3a858f4432bee48edf5e37df31&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
[](https://app.codeant.ai/fix-in-ide?tool=vscode-claude&prompt_id=a0516a3a858f4432bee48edf5e37df31&service=github&base_url=https%3A%2F%2Fgithub.com&org=apache&repo=apache%2Fsuperset)
*(Use Cmd/Ctrl + Click for best experience)*
<details>
<summary><b>Prompt for AI Agent 🤖 </b></summary>
```mdx
This is a comment left during a code review.
**Path:** superset/translations/tr/LC_MESSAGES/messages.po
**Line:** 8854:8856
**Comment:**
*Logic Error: This pluralized translation also hardcodes `1 sütunu`,
which makes messages incorrect for counts other than 1. Use a
neutral/count-driven form so the same translation remains correct for every
numeric value.
Validate the correctness of the flagged issue. If correct, How can I resolve
this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask
user if the user wants to fix the rest of the comments as well. if said yes,
then fetch all the comments validate the correctness and implement a minimal fix
```
</details>
<a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=a781363cdeee8524f1fb65e5836104b736b1e2ad5728966cc48defd973ff31ae&reaction=like'>👍</a>
| <a
href='https://app.codeant.ai/feedback?pr_url=https%3A%2F%2Fgithub.com%2Fapache%2Fsuperset%2Fpull%2F39064&comment_hash=a781363cdeee8524f1fb65e5836104b736b1e2ad5728966cc48defd973ff31ae&reaction=dislike'>👎</a>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]