Integrating New Relic with Tornado app with gunicorn as a process manager
Question: I want to use New Relic to monitor errors in my Async Tornado app with
gunicorn as a process manager.

When I try to make a request after integrating with New Relic I get the
following error File "/Library/Python/2.7/site-
packages/newrelic-2.10.1.9/newrelic/hooks/framework_tornado.py", line 30, in
request_environment result['REQUEST_URI'] = request.uri AttributeError: 'dict'
object has no attribute 'uri'

The app is hosted on Heroku requirements.txt

    
    
    # Analytics
    newrelic==2.10.1.9
    

Procfile

    
    
    web: newrelic-admin run-program gunicorn -k tornado --bind=0.0.0.0:$PORT opening_application.runserver
    


Answer: The workaround to eliminate the issue is to add the following to the agent
configuration file (newrelic.ini):

    
    
    [import-hook:gunicorn.app.base] 
    enabled = false
    

