korbit-ai[bot] commented on code in PR #32366:
URL: https://github.com/apache/superset/pull/32366#discussion_r1968496671
##########
superset/commands/report/execute.py:
##########
@@ -363,6 +364,8 @@
def _get_csv_data(self) -> bytes:
url = self._get_url(result_format=ChartDataResultFormat.CSV)
+ if not self._report_schedule.include_index:
+ url = remove_post_processed(url)
Review Comment:
### Post-processing removal affects more than index column <sub></sub>
<details>
<summary>Tell me more</summary>
###### What is the issue?
The code removes the post-processed data when `include_index` is False, but
this actually drops the entire post-processing result, not just the index
column.
###### Why this matters
Users will lose all post-processing results (like sorting, filtering,
pivoting) when they choose to exclude the index column, which is more than they
intended.
###### Suggested change ∙ *Feature Preview*
Create a new utility function that only removes the index column from the
post-processed data while preserving other post-processing results. Example:
```python
def remove_index_from_csv(url: str) -> str:
# Modify URL parameters to only exclude index column
# while keeping other post-processing results
return modified_url
```
</details>
<sub>
[](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/d5144031-eb6e-4d3f-844f-6babd2f3620f?suggestedFixEnabled=true)
💬 Chat with Korbit by mentioning @korbit-ai.
</sub>
<!--- korbi internal id:bf55445a-fe78-424c-a1de-7d0393ae5490 -->
--
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]