Skip to content

Points: Gracefully handle API failures #676

@Asartea

Description

@Asartea

Checks

  • I have thoroughly read and understand The Odin Project Contributing Guide
  • The title of this issue follows the command name: brief description of request format, e.g. /help: add optional @user parameter

Do you want to be assigned to this issue?

  • I would like to be assigned this issue to work on it

Description of the Feature Request

Currently running something related to points when developing crashes. For some reason, trying to assign points just silently fails, while trying any of the slash commands hardcrashes the app.

Pending resolution of #581 , we could at least catch the error and give a reply if it happens in development

Acceptance Criteria

  • The bot no longer crashes when running locally and doing anything related to points
  • Add a new ENV environment variable to config.js, and set it to development if running npm run dev
  • A nice message is returned, stating that the bot is unauthorized and that this is expected in development if the ENV variable is set to development, else return a nice message saying to contact the maintainers

Additional information

(open for alternate names for the variable)

Metadata

Metadata

Assignees

Labels

Status: In ProgressThis issue/PR has ongoing work being doneType: EnhancementInvolves a new feature or enhancement request

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions