incident-bot icon indicating copy to clipboard operation
incident-bot copied to clipboard

[BUG] Unable to upload image by pinning it got an unexpected keyword argument 'incident_id'

Open pfallasro opened this issue 10 months ago • 0 comments

Describe the bug Unable to upload image by pinning it.

{
  "name": "root",
  "asctime": "2024-04-05 10:04:41,194",
  "levelname": "INFO",
  "filename": "flask.py",
  "message": "incidentbot.live.zenjob.io 127.0.0.6 [05/04/2024 10:04:41 UTC] \"GET /api/v1/incident/inc-202404050857-autortimje/pinned/13\" - Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/123.0.0.0 Safari/537.36 - HTTP/1.1 500 INTERNAL SERVER ERROR"
}

{
  "name": "bot.api.flask",
  "asctime": "2024-04-05 10:04:41,194",
  "levelname": "ERROR",
  "filename": "app.py",
  "message": "Exception on /api/v1/incident/inc-202404050857-autortimje/pinned/13 [GET]",
  "exc_info": "Traceback (most recent call last):\n  File \"/usr/local/lib/python3.11/site-packages/flask/app.py\", line 1463, in wsgi_app\n    response = self.full_dispatch_request()\n               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/local/lib/python3.11/site-packages/flask/app.py\", line 872, in full_dispatch_request\n    rv = self.handle_user_exception(e)\n         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/local/lib/python3.11/site-packages/flask_cors/extension.py\", line 176, in wrapped_function\n    return cors_after_request(app.make_response(f(*args, **kwargs)))\n                                                ^^^^^^^^^^^^^^^^^^\n  File \"/usr/local/lib/python3.11/site-packages/flask/app.py\", line 870, in full_dispatch_request\n    rv = self.dispatch_request()\n         ^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/local/lib/python3.11/site-packages/flask/app.py\", line 855, in dispatch_request\n    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)  # type: ignore[no-any-return]\n           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/local/lib/python3.11/site-packages/flask_jwt_extended/view_decorators.py\", line 170, in decorator\n    return current_app.ensure_sync(fn)(*args, **kwargs)\n           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nTypeError: get_patch_delete_item_by_id() got an unexpected keyword argument 'incident_id'"
}

Version Version v1.10.3

To Reproduce Steps to reproduce the behavior:

  1. Create an incident
  2. Add an image to slack channel
  3. Add pin emoji to image

Expected behavior An image should be uploaded to

Screenshots image

Environment (please complete the following information):

  • Platform: Kubernetes

Additional context Pinned messages seem to be working fine.

pfallasro avatar Apr 05 '24 09:04 pfallasro