Skip to content

Commit

Permalink
fix(services/feeds): only check for standard cap spec by ext job id (#…
Browse files Browse the repository at this point in the history
…16366)

* fix(services/feeds): only check for standard cap spec by ext job id

* adds changeset
  • Loading branch information
MStreet3 authored Feb 14, 2025
1 parent 2724ef8 commit 4704eb5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/pink-singers-greet.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": patch
---

fixes inability to approve multiple jobs with same command for standard capabilities
8 changes: 2 additions & 6 deletions core/services/feeds/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -894,12 +894,8 @@ func (s *service) ApproveSpec(ctx context.Context, id int64, force bool) error {
return fmt.Errorf("failed while checking for existing ccip job: %w", txerr)
}
case job.StandardCapabilities:
existingJobID, txerr = tx.jobORM.FindStandardCapabilityJobID(ctx, *j.StandardCapabilitiesSpec)
// Return an error if the repository errors. If there is a not found
// error we want to continue with approving the job.
if txerr != nil && !errors.Is(txerr, sql.ErrNoRows) {
return fmt.Errorf("failed while checking for existing standard capabilities job: %w", txerr)
}
// Only possible to match standard capabilities by external job id
// no-op
case job.Gateway:
existingJobID, txerr = tx.jobORM.FindGatewayJobID(ctx, *j.GatewaySpec)
// Return an error if the repository errors. If there is a not found
Expand Down

0 comments on commit 4704eb5

Please sign in to comment.