File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change 2323from flask .views import MethodView
2424from flask_sqlalchemy import SQLAlchemy
2525from decouple import config
26+ import rollbar
2627
2728
2829DEBUG = config ("DEBUG" , default = False )
3839else :
3940 warnings .warn ("GITHUB_AUTH_TOKEN is NOT available. Worry about rate limits." )
4041
42+ ROLLBAR_ACCESS_TOKEN = config ("ROLLBAR_ACCESS_TOKEN" , default = None )
43+ if ROLLBAR_ACCESS_TOKEN :
44+ rollbar .init (ROLLBAR_ACCESS_TOKEN )
45+ rollbar .report_message ("Rollbar is configured correctly" )
46+ print ("Rollbar enabled." )
47+ else :
48+ print ("Rollbar NOT enabled." )
49+
4150# Set static_folder=None to suppress the standard static server
4251app = Flask (__name__ , static_folder = None )
4352app .config ["SQLALCHEMY_DATABASE_URI" ] = config (
Original file line number Diff line number Diff line change @@ -45,3 +45,5 @@ python-decouple==3.3 \
4545python-dotenv == 0.12.0 \
4646 --hash =sha256:81822227f771e0cab235a2939f0f265954ac4763cafd806d845801c863bf372f \
4747 --hash =sha256:92b3123fb2d58a284f76cc92bfe4ee6c502c32ded73e8b051c4f6afc8b6751ed
48+ rollbar == 0.15.1 \
49+ --hash =sha256:96b63df27a47232aa16a142d2f5812073f8bf7db2b81c5f7981b9a4d4659468c
You can’t perform that action at this time.
0 commit comments