Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Print message after init_db command finishes #443

Merged
merged 1 commit into from Oct 29, 2018

Conversation

kartikeyaSh
Copy link
Contributor

Summary

  • This is a…
    • Bug fix
    • Feature addition
    • Refactoring
    • Minor / simple change (like a typo)
    • Other
  • Describe this change in 1-2 sentences:
    The docker-compose -f docker/docker-compose.yml -p listenbrainz run --rm web python3 manage.py init_db --create-db command in the end doesn't print a "Done" message and prints "Creating indexes..." as the last message which might confuse someone to think that it aborted before completion. And we do print a "Done" message for other init_db commands. So, it makes sense to do that here.
Starting listenbrainz_rabbitmq_1 ... 
Starting listenbrainz_redis_1 ... 
Starting listenbrainz_rabbitmq_1
Starting listenbrainz_redis_1
Starting listenbrainz_db_1 ... 
Starting listenbrainz_influx_1 ... 
Starting listenbrainz_db_1
Starting listenbrainz_redis_1 ... done
Connection to db established!
Creating user and a database...
Creating database extensions...
Starting metabrainz service with  environment.
Configuration values are as follows: 
{   'API_URL': 'https://api.listenbrainz.org',
    'APPLICATION_ROOT': None,
    'BIGQUERY_DATASET_ID': 'listenbrainz_test',
    'BIGQUERY_PROJECT_ID': 'listenbrainz',
    'BIGQUERY_TABLE_ID': 'listen',
    'COMPILE_LESS': True,
    'DEBUG': True,
    'DEBUG_TB_ENABLED': True,
    'DEBUG_TB_HOSTS': (),
    'DEBUG_TB_INTERCEPT_REDIRECTS': True,
    'DEBUG_TB_PANELS': (   'flask_debugtoolbar.panels.versions.VersionDebugPanel',
                           'flask_debugtoolbar.panels.timer.TimerDebugPanel',
                           'flask_debugtoolbar.panels.headers.HeaderDebugPanel',
                           'flask_debugtoolbar.panels.request_vars.RequestVarsDebugPanel',
                           'flask_debugtoolbar.panels.config_vars.ConfigVarsDebugPanel',
                           'flask_debugtoolbar.panels.template.TemplateDebugPanel',
                           'flask_debugtoolbar.panels.sqlalchemy.SQLAlchemyDebugPanel',
                           'flask_debugtoolbar.panels.logger.LoggingPanel',
                           'flask_debugtoolbar.panels.route_list.RouteListDebugPanel',
                           'flask_debugtoolbar.panels.profiler.ProfilerDebugPanel'),
    'EXPLAIN_TEMPLATE_LOADING': False,
    'INFLUX_DB_NAME': 'listenbrainz',
    'INFLUX_HOST': 'influx',
    'INFLUX_PORT': 8086,
    'JSONIFY_MIMETYPE': 'application/json',
    'JSONIFY_PRETTYPRINT_REGULAR': True,
    'JSON_AS_ASCII': True,
    'JSON_SORT_KEYS': True,
    'LASTFM_API_KEY': 'e5b650429d485857e68e0c5bf2874525',
    'LASTFM_API_URL': 'https://ws.audioscrobbler.com/2.0/',
    'LASTFM_PROXY_URL': 'http://0.0.0.0:8080/',
    'LOGGER_HANDLER_POLICY': 'always',
    'LOGGER_NAME': 'listenbrainz.webserver',
    'MAX_CONTENT_LENGTH': 16777216,
    'MAX_POSTGRES_LISTEN_HISTORY': '-1',
    'MESSYBRAINZ_SQLALCHEMY_DATABASE_URI': 'postgresql://messybrainz:messybrainz@db:5432/messybrainz',
    'MUSICBRAINZ_CLIENT_ID': '2LXvDjyab0KGaZ9HHH4eJw',
    'MUSICBRAINZ_CLIENT_SECRET': '0yqMqBYQZKG20FblBpvBJQ',
    'PERMANENT_SESSION_LIFETIME': datetime.timedelta(31),
    'PG_ASYNC_LISTEN_COMMIT': False,
    'PG_QUERY_TIMEOUT': '3000',
    'PLAYING_NOW_MAX_DURATION': 600,
    'POSTGRES_ADMIN_URI': 'postgresql://postgres@db/template1',
    'PREFERRED_URL_SCHEME': 'http',
    'PRESERVE_CONTEXT_ON_EXCEPTION': None,
    'PROPAGATE_EXCEPTIONS': None,
    'RABBITMQ_HOST': 'rabbitmq',
    'RABBITMQ_PASSWORD': 'guest',
    'RABBITMQ_PORT': 5672,
    'RABBITMQ_USERNAME': 'guest',
    'RABBITMQ_VHOST': '/',
    'REDIS_HOST': 'redis',
    'REDIS_NAMESPACE': 'listenbrainz',
    'REDIS_PORT': 6379,
    'SECRET_KEY': 'CHANGE_ME',
    'SEND_FILE_MAX_AGE_DEFAULT': datetime.timedelta(0, 43200),
    'SERVER_NAME': None,
    'SESSION_COOKIE_DOMAIN': None,
    'SESSION_COOKIE_HTTPONLY': True,
    'SESSION_COOKIE_NAME': 'session',
    'SESSION_COOKIE_PATH': None,
    'SESSION_COOKIE_SECURE': False,
    'SESSION_REFRESH_EACH_REQUEST': True,
    'SQLALCHEMY_DATABASE_URI': 'postgresql://listenbrainz:listenbrainz@db:5432/listenbrainz',
    'STATS_CALCULATION_INTERVAL': 7,
    'STATS_CALCULATION_LOGIN_TIME': 30,
    'STATS_ENTITY_LIMIT': 100,
    'TEMPLATES_AUTO_RELOAD': None,
    'TESTING': False,
    'TRAP_BAD_REQUEST_ERRORS': False,
    'TRAP_HTTP_EXCEPTIONS': False,
    'UPLOAD_FOLDER': '/tmp/lastfm-backup-upload',
    'USE_X_SENDFILE': False,
    'WRITE_TO_BIGQUERY': False}
Unable to retrieve git commit. Error: %s [Errno 2] No such file or directory: '.git-version'
--------------------------------------------------------------------------------
INFO in redis_connection [/code/listenbrainz/listenbrainz/webserver/redis_connection.py:15]:
Connecting to redis redis:6379
--------------------------------------------------------------------------------
2018-10-27 11:27:09,123 INFO Connecting to redis: redis:6379
--------------------------------------------------------------------------------
INFO in influx_connection [/code/listenbrainz/listenbrainz/webserver/influx_connection.py:17]:
Successfully created InfluxListenStore instance!
--------------------------------------------------------------------------------
Connection to db established!
Connection to db established
/usr/local/lib/python3.6/site-packages/flask_sqlalchemy/__init__.py:778: FSADeprecationWarning: SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and will be disabled by default in the future.  Set it to True or False to suppress this warning.
  'SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and '
Creating schema...
Creating tables...
Creating primary and foreign keys...
Creating indexes...

Copy link
Collaborator

@paramsingh paramsingh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@paramsingh paramsingh merged commit 1730000 into metabrainz:master Oct 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants