)]}'
{"smaug/db/sqlalchemy/migrate_repo/versions/001_smaug_init.py":[{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"6d6f3037c8f18743c0075a67359a932d4a270db8","unresolved":false,"context_lines":[{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    if migrate_engine.name \u003d\u003d \"mysql\":"},{"line_number":155,"context_line":"        tables \u003d [\"migrate_version\","},{"line_number":156,"context_line":"                  \"services\"]"},{"line_number":157,"context_line":""},{"line_number":158,"context_line":"        migrate_engine.execute(\"SET foreign_key_checks \u003d 0\")"},{"line_number":159,"context_line":"        for table in tables:"}],"source_content_type":"text/x-python","patch_set":1,"id":"5a5ae5dd_5f269317","line":156,"range":{"start_line":156,"start_character":19,"end_line":156,"end_character":27},"updated":"2016-02-03 02:49:50.000000000","message":"Need put table name here to set CHARACTER SET of the table. The tables I commited have added in my patch. I will commited ASAP.","commit_id":"8f0a02b6df38f8ab8de348d6c203c9e585bcc06f"}],"smaug/db/sqlalchemy/models.py":[{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"f4da5526683ff2976a9c55b91d2a317e6f94692d","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        self.save(session\u003dsession)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def save(self, session\u003dNone):"},{"line_number":45,"context_line":"        from smaug.db.sqlalchemy import api"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        if session is None:"},{"line_number":48,"context_line":"            session \u003d api.get_session()"}],"source_content_type":"text/x-python","patch_set":4,"id":"5a5ae5dd_8d008003","line":45,"updated":"2016-02-08 15:37:16.000000000","message":"Is there a reason to do the import here and not above?","commit_id":"706883cf63a014c4ce7c8c0fc863d18fa3ba88f0"},{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"226decb0c90ff3dc7aa65df71b570785367afb7e","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        self.save(session\u003dsession)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def save(self, session\u003dNone):"},{"line_number":45,"context_line":"        from smaug.db.sqlalchemy import api"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        if session is None:"},{"line_number":48,"context_line":"            session \u003d api.get_session()"}],"source_content_type":"text/x-python","patch_set":4,"id":"dae33548_6cb090de","line":45,"in_reply_to":"5a5ae5dd_8d008003","updated":"2016-02-15 10:16:05.000000000","message":"because the api model is only used here. thanks for your comments.","commit_id":"706883cf63a014c4ce7c8c0fc863d18fa3ba88f0"},{"author":{"_account_id":13070,"name":"Eran Gampel","email":"eran@gampel.net","username":"Gampel"},"change_message_id":"3b6ae5cda1c1a17b2a4bb7cc33db44cc93a7b592","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        self.save(session\u003dsession)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def save(self, session\u003dNone):"},{"line_number":45,"context_line":"        from smaug.db.sqlalchemy import api"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        if session is None:"},{"line_number":48,"context_line":"            session \u003d api.get_session()"}],"source_content_type":"text/x-python","patch_set":6,"id":"dae33548_6d3057e9","line":45,"range":{"start_line":45,"start_character":19,"end_line":45,"end_character":21},"updated":"2016-02-16 10:47:23.000000000","message":"I do not see the advantage of this lazy imports.\nIMO it should be on TOP it is much more clear to someone reading the code as to the dependencies that this module has\n\nModule importing is quite fast, but not instant. This means that:\n\nPutting the imports at the top of the module is fine, because it\u0027s a trivial cost that\u0027s only paid once.\n\nPutting the imports within a function will cause calls to that function to take longer.","commit_id":"5b6af6d68898c8f6295f01a49a8cb76b6787f8ec"},{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"c2fbeecdebbc44a25bb86731669836a492826947","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    connection is lost and needs to be reestablished."},{"line_number":93,"context_line":"    \"\"\""},{"line_number":94,"context_line":"    from sqlalchemy import create_engine"},{"line_number":95,"context_line":"    models \u003d (Service,)"},{"line_number":96,"context_line":"    engine \u003d create_engine(CONF.database.connection, echo\u003dFalse)"},{"line_number":97,"context_line":"    for model in models:"},{"line_number":98,"context_line":"        model.metadata.create_all(engine)"}],"source_content_type":"text/x-python","patch_set":8,"id":"dae33548_9723aebc","line":95,"range":{"start_line":95,"start_character":14,"end_line":95,"end_character":21},"updated":"2016-02-18 09:04:09.000000000","message":"Considering add table name ScheduledOperationLog here.","commit_id":"78715cf1f8c18ef57f84968959b210f35d8aac84"},{"author":{"_account_id":17151,"name":"chenying","email":"chenyingko@gmail.com","username":"chenying"},"change_message_id":"f5b740594f7b29b202a0d028360a0944ec1d48d0","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    connection is lost and needs to be reestablished."},{"line_number":93,"context_line":"    \"\"\""},{"line_number":94,"context_line":"    from sqlalchemy import create_engine"},{"line_number":95,"context_line":"    models \u003d (Service,)"},{"line_number":96,"context_line":"    engine \u003d create_engine(CONF.database.connection, echo\u003dFalse)"},{"line_number":97,"context_line":"    for model in models:"},{"line_number":98,"context_line":"        model.metadata.create_all(engine)"}],"source_content_type":"text/x-python","patch_set":8,"id":"dae33548_3dec4129","line":95,"range":{"start_line":95,"start_character":14,"end_line":95,"end_character":21},"in_reply_to":"dae33548_9723aebc","updated":"2016-02-18 09:23:05.000000000","message":"https://review.openstack.org/#/c/276619/ I note that it have been added in this patch.","commit_id":"78715cf1f8c18ef57f84968959b210f35d8aac84"}],"smaug/tests/unit/db/test_models.py":[{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"f4da5526683ff2976a9c55b91d2a317e6f94692d","unresolved":false,"context_lines":[{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_scheduled_operation_log_create(self):"},{"line_number":109,"context_line":"        log_ref \u003d self._create_scheduled_operation_log()"},{"line_number":110,"context_line":"        self.assertEqual(log_ref[\u0027state\u0027], \u0027in_progress\u0027)"},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"    def test_scheduled_operation_log_delete(self):"},{"line_number":113,"context_line":"        log_ref \u003d self._create_scheduled_operation_log()"}],"source_content_type":"text/x-python","patch_set":4,"id":"5a5ae5dd_e06c9bd1","line":110,"updated":"2016-02-08 15:37:16.000000000","message":"There\u0027s been some effort in other projects to enforce the argument order for assertEqual. It expects (EXPECTED, ACTUAL) as arguments, so these would need to be reversed.\n\nNot a critical thing by any means, but I think the error message when the assert fails ends up making a little more sense if they are switched.","commit_id":"706883cf63a014c4ce7c8c0fc863d18fa3ba88f0"},{"author":{"_account_id":18266,"name":"zengchen","email":"chenzeng2@huawei.com","username":"zengchen"},"change_message_id":"226decb0c90ff3dc7aa65df71b570785367afb7e","unresolved":false,"context_lines":[{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_scheduled_operation_log_create(self):"},{"line_number":109,"context_line":"        log_ref \u003d self._create_scheduled_operation_log()"},{"line_number":110,"context_line":"        self.assertEqual(log_ref[\u0027state\u0027], \u0027in_progress\u0027)"},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"    def test_scheduled_operation_log_delete(self):"},{"line_number":113,"context_line":"        log_ref \u003d self._create_scheduled_operation_log()"}],"source_content_type":"text/x-python","patch_set":4,"id":"dae33548_ac545854","line":110,"in_reply_to":"5a5ae5dd_e06c9bd1","updated":"2016-02-15 10:16:05.000000000","message":"yes, you are right. thank you very much for your reminding. I will modify it. thanks again.","commit_id":"706883cf63a014c4ce7c8c0fc863d18fa3ba88f0"}]}
