bito-code-review[bot] commented on code in PR #38033:
URL: https://github.com/apache/superset/pull/38033#discussion_r2980655256
##########
superset-frontend/src/explore/exploreUtils/index.ts:
##########
@@ -373,7 +373,7 @@ export const exportChart = async ({
});
payload = formData;
} else {
- url = ensureAppRoot('/api/v1/chart/data');
+ url = '/api/v1/chart/data';
Review Comment:
<div>
<div id="suggestion">
<div id="issue"><b>API URL missing app root prefix</b></div>
<div id="fix">
Removing ensureAppRoot from the API URL will cause chart data export to fail
in subdirectory deployments where Superset is mounted under a path like
/superset, since '/api/v1/chart/data' resolves to the wrong endpoint. The
legacy API path correctly uses ensureAppRoot via getExploreUrl.
</div>
<details>
<summary>
<b>Code suggestion</b>
</summary>
<blockquote>Check the AI-generated fix before applying</blockquote>
<div id="code">
````suggestion
url = ensureAppRoot('/api/v1/chart/data');
````
</div>
</details>
</div>
<small><i>Code Review Run #ee3956</i></small>
</div>
---
Should Bito avoid suggestions like this for future reviews? (<a
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
- [ ] Yes, avoid them
--
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]