You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "jaymasiwal (via GitHub)" <gi...@apache.org> on 2026/03/06 22:27:15 UTC

[PR] fix(ui): show permission error when triggering DAG without permission [airflow]

jaymasiwal opened a new pull request, #63018:
URL: https://github.com/apache/airflow/pull/63018

   ### What this PR does
   
   Improves error handling when triggering a DAG without sufficient permissions.
   
   Previously the UI displayed a generic "Forbidden" error message when the backend returned a 403 response.  
   This change detects the 403 response and shows a clearer permission-related message in the UI toast.
   
   ### Changes
   
   - Detect 403 responses in `useTrigger`
   - Show `triggerDag.permissionDenied` message instead of generic error
   - Added missing i18n key for the permission error message
   
   ### How it was tested
   
   - Ran Airflow locally using Breeze
   - Triggered a DAG as a user without permission
   - Verified that the UI now shows a clear permission error message
   - Verified UI builds successfully (`pnpm build`)
   - Verified lint passes (`pnpm lint`)


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "Srabasti (via GitHub)" <gi...@apache.org>.
Srabasti commented on PR #63018:
URL: https://github.com/apache/airflow/pull/63018#issuecomment-4021031525

   Static checks are failing due to improper indentation for lines 65 through 86. 
   Please run prek locally in your branch before pushing to main @jaymasiwal !


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on PR #63018:
URL: https://github.com/apache/airflow/pull/63018#issuecomment-4178913754

   There are conflicts to resolve 


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "pierrejeambrun (via GitHub)" <gi...@apache.org>.
pierrejeambrun closed pull request #63018: fix(ui): show permission error when triggering DAG without permission
URL: https://github.com/apache/airflow/pull/63018


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "pierrejeambrun (via GitHub)" <gi...@apache.org>.
pierrejeambrun commented on PR #63018:
URL: https://github.com/apache/airflow/pull/63018#issuecomment-4184206106

   This was fixed, closing.
   
   <img width="1846" height="942" alt="Screenshot 2026-04-03 at 18 39 54" src="https://github.com/user-attachments/assets/44746648-3870-43d4-97cd-befc4f0849db" />
   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "XD-DENG (via GitHub)" <gi...@apache.org>.
XD-DENG commented on code in PR #63018:
URL: https://github.com/apache/airflow/pull/63018#discussion_r2898296002


##########
airflow-core/src/airflow/ui/public/i18n/locales/ar/components.json:
##########
@@ -168,6 +168,7 @@
     "intervalStart": "البداية",
     "loading": "جارٍ تحميل معلومات Dag...",
     "loadingFailed": "فشل تحميل معلومات Dag. يرجى المحاولة مرة أخرى.",
+    "permissionDenied": "You do not have permission to trigger this DAG.",

Review Comment:
   This one is obviously in wrong place ;-) This is the locale file for Arabic translation.



-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "jaymasiwal (via GitHub)" <gi...@apache.org>.
jaymasiwal commented on PR #63018:
URL: https://github.com/apache/airflow/pull/63018#issuecomment-4017125986

   Good catch, thanks!
   
   I removed the English message from the Arabic locale file and removed the incorrect English locale file I added earlier. The PR has been updated.


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(ui): show permission error when triggering DAG without permission [airflow]

Posted by "jason810496 (via GitHub)" <gi...@apache.org>.
jason810496 commented on PR #63018:
URL: https://github.com/apache/airflow/pull/63018#issuecomment-4022534337

   @jaymasiwal This PR has been converted to **draft** because it does not yet meet our [Pull Request quality criteria](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#pull-request-quality-criteria).
   
   **Issues found:**
   - :x: **Pre-commit / static checks**: Failing: CI image checks / Static checks. Run `prek run --from-ref main` locally to find and fix issues. See [Pre-commit / static checks docs](https://github.com/apache/airflow/blob/main/contributing-docs/08_static_code_checks.rst).
   
   > **Note:** Your branch is **93 commits behind `main`**. Some check failures may be caused by changes in the base branch rather than by your PR. Please rebase your branch and push again to get up-to-date CI results.
   
   **What to do next:**
   - The comment informs you what you need to do.
   - Fix each issue, then mark the PR as "Ready for review" in the GitHub UI - but only after making sure that all the issues are fixed.
   - Maintainers will then proceed with a normal review.
   
   Converting a PR to draft is **not** a rejection — it is an invitation to bring the PR up to the project's standards so that maintainer review time is spent productively. If you have questions, feel free to ask on the [Airflow Slack](https://s.apache.org/airflow-slack).


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org