Bug Fix: pyrollbar: No access_token provided.
Credentials and authentication issues preventing the rollbar agent in our backend from calling home.
1. Problem
Although the rollbar
access_tokenis configured with the python variablerollbar_access_token, the agent isn't calling home, and no data are coming through on the Rollbar side.

2. Analysis
Something must be wrong with the variable
rollbar_access_tokenin line 94 (in the above image).After good dozens of minutes, I finally figured out: there are multiple
access_tokensat varying levels in Rollbar - one at the project level (for each project) and the other at the account level.I was using the account level token where I have to input the project access token.
3. Solution

However, I still get the same error that the access_token is not provided. Well... the error message was quite stragithforward in fact. It's been telling me to "call" the rollbar.init() function.

Reorganise the Rollbar code.
Call
init_rollbar()underwith app.app_context():function (code fix here).
4. Result
The error message
pyrollbar: No access_token providedis gone.I check the Rollbar console and the spans are coming through.



Last updated