OpenFn / OpenFn/kit

Worker: ignore sentry errors `Credential environment mismatch`

Open Beginner friendly
#1,460 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
21
Forks
23
Avg merge
1d 22h
Merged PRs (30d)
17

Description

We're seeing another user error on sentry:

[fetch:credential] Credential environment mismatch.
This project is using 'geda' but credential 'Pius Git Token' does not have a matching environment. To fix:
  1. Go to https://app.openfn.org/projects/a36ac16e-3b46-4bfa-a9b8-4ad5975bafb0/settings#credentials
  2. Find 'Pius Git Token'
  3. Click 'Edit' and add an environment named 'geda'
Or change your project environment to match an existing credential environment.

This error is thrown in a projeect when you select a credential that does not have a value for a given environment. For example, you have a sandbox in dev but your credential only has a main

This is a perfectly OK and expected user error. It should be supressed from sentry. See #1440 for a reference fix

example error

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the worker's Sentry error-reporting path and use issue #1440 as the reference fix. Reproduce or inspect the Credential environment mismatch error, then verify that this expected user error is suppressed from Sentry while other errors remain reported.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend, observability
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.