Skip to content

ENG-2523: Skip manual task API requests for non-manual-task integrations#7728

Merged
nreyes-dev merged 2 commits intomainfrom
nreyes/eng-2523
Mar 24, 2026
Merged

ENG-2523: Skip manual task API requests for non-manual-task integrations#7728
nreyes-dev merged 2 commits intomainfrom
nreyes/eng-2523

Conversation

@nreyes-dev
Copy link
Copy Markdown
Contributor

@nreyes-dev nreyes-dev commented Mar 23, 2026

Ticket ENG-2523

Description Of Changes

Skip unnecessary /manual-fields and /manual-task API requests for non-manual-task integrations. These requests were firing on every integration detail page, returning 400/404 errors unnecessarily.

Code Changes

  • Added connectionOption?.identifier !== ConnectionType.MANUAL_TASK to the skip condition in useAddManualTaskStep and useAssignTasksToUsersStep so the RTK Query hooks don't fire for non-manual-task integrations.

Steps to Confirm

  1. Open a non-manual-task integration (e.g., a website monitor)
  2. Confirm no requests to /manual-fields or /manual-task appear in the network tab
  3. Open a manual task integration and confirm the setup steps still load correctly

Pre-Merge Checklist

  • Issue requirements met
  • All CI pipelines succeeded
  • CHANGELOG.md updated
    • Add a db-migration This indicates that a change includes a database migration label to the entry if your change includes a DB migration
    • Add a high-risk This issue suggests changes that have a high-probability of breaking existing code label to the entry if your change includes a high-risk change (i.e. potential for performance impact or unexpected regression) that should be flagged
    • Updates unreleased work already in Changelog, no new entry necessary
  • UX feedback:
    • All UX related changes have been reviewed by a designer
    • No UX review needed
  • Followup issues:
    • Followup issues created
    • No followup issues
  • Database migrations:
    • Ensure that your downrev is up to date with the latest revision on main
    • Ensure that your downgrade() migration is correct and works
      • If a downgrade migration is not possible for this change, please call this out in the PR description!
    • No migrations
  • Documentation:
    • Documentation complete, PR opened in fidesdocs
    • Documentation issue created in fidesdocs
    • If there are any new client scopes created as part of the pull request, remember to update public-facing documentation that references our scope registry
    • No documentation updates required

@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Mar 23, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
fides-plus-nightly Ready Ready Preview, Comment Mar 23, 2026 2:37pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
fides-privacy-center Ignored Ignored Mar 23, 2026 2:37pm

Request Review

@nreyes-dev nreyes-dev marked this pull request as ready for review March 23, 2026 14:37
@nreyes-dev nreyes-dev requested a review from a team as a code owner March 23, 2026 14:37
@nreyes-dev nreyes-dev requested review from jpople and removed request for a team March 23, 2026 14:37
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Mar 23, 2026

Greptile Summary

This PR fixes unnecessary API calls (/manual-fields and /manual-task) that were firing on every integration detail page regardless of the integration type, producing 400/404 errors in the network log. The fix adds a connectionOption?.identifier !== ConnectionType.MANUAL_TASK guard to the skip option in both useAddManualTaskStep and useAssignTasksToUsersStep, preventing the RTK Query hooks from issuing those requests for non-manual-task integrations.

  • The change is tightly scoped and logically correct: both hooks already contain an early-return guard (if (connectionOption?.identifier !== ConnectionType.MANUAL_TASK) return null) that prevented the hooks from producing a setup step for non-manual-task connections. Adding the same check to the skip condition simply eliminates the now-redundant API round-trips.
  • As a minor secondary effect, the query is also skipped when connectionOption is undefined (e.g., still loading). Previously the query would have fired as long as connection existed. This is a strictly better behavior since the hook would have returned null anyway at the early-return check.
  • No business logic, data shapes, or API contracts were changed.

Confidence Score: 5/5

  • This PR is safe to merge — it eliminates unnecessary network requests without touching any business logic or data contracts.
  • The change is minimal and precisely targeted: two one-line additions to skip conditions in RTK Query hooks, each of which already has a matching early-return guard ensuring the hook has no effect for non-manual-task integrations. There is no risk of regression for manual-task integrations, and non-manual-task integrations only benefit from the removal of the spurious API calls.
  • No files require special attention.

Important Files Changed

Filename Overview
clients/admin-ui/src/features/integrations/setup-steps/hooks/useAddManualTaskStep.ts Adds connectionOption?.identifier !== ConnectionType.MANUAL_TASK to the skip condition so the useGetManualFieldsQuery RTK Query call is skipped for non-manual-task integrations. Consistent with the existing early-return guard already present in the hook.
clients/admin-ui/src/features/integrations/setup-steps/hooks/useAssignTasksToUsersStep.ts Same targeted fix as useAddManualTaskStep — adds the MANUAL_TASK identifier check to the skip condition so useGetManualTaskConfigQuery no longer fires for non-manual-task integrations.
changelog/7728-skip-manual-task-requests.yaml Standard changelog entry — type Fixed, correct PR number, no issues.

Reviews (1): Last reviewed commit: "changelog" | Re-trigger Greptile

@nreyes-dev nreyes-dev added this pull request to the merge queue Mar 24, 2026
Merged via the queue into main with commit 32b0836 Mar 24, 2026
46 of 47 checks passed
@nreyes-dev nreyes-dev deleted the nreyes/eng-2523 branch March 24, 2026 19:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants