)]}'
{"qinling/api/controllers/v1/function.py":[{"author":{"_account_id":21781,"name":"Hunt Xu","email":"mhuntxu@gmail.com","username":"huntxu"},"change_message_id":"9bcdf71d559683f5926e1e8e7ec43137a22b83e0","unresolved":false,"context_lines":[{"line_number":278,"context_line":"                    \u0027Function can only be deleted by its owner.\u0027"},{"line_number":279,"context_line":"                )"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"            for version_db in func_db.versions:"},{"line_number":282,"context_line":"                version_jobs \u003d db_api.get_jobs("},{"line_number":283,"context_line":"                    function_id\u003dversion_db.function_id,"},{"line_number":284,"context_line":"                    function_version\u003dversion_db.version_number,"},{"line_number":285,"context_line":"                    status\u003d{\u0027nin\u0027: [\u0027done\u0027, \u0027cancelled\u0027]}"},{"line_number":286,"context_line":"                )"},{"line_number":287,"context_line":"                if len(version_jobs) \u003e 0:"},{"line_number":288,"context_line":"                    raise exc.NotAllowedException("},{"line_number":289,"context_line":"                        \u0027The function version is still associated with \u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"9f6a8fd7_3c0fa288","line":286,"range":{"start_line":281,"start_character":0,"end_line":286,"end_character":17},"updated":"2018-04-26 03:53:21.000000000","message":"For jobs using different versions of the same function, the function_id is the same, so would it be enough to use only one db_api.get_jobs() call using the function_id as the filter? Then we don\u0027t have to iterate all the function versions.","commit_id":"b562d0596bd5f14e1cd44c273ab919bac914aabf"},{"author":{"_account_id":6732,"name":"Lingxian Kong","email":"anlin.kong@gmail.com","username":"kong"},"change_message_id":"92565a53554cbbee903e2ea369dd7868441f6e0f","unresolved":false,"context_lines":[{"line_number":278,"context_line":"                    \u0027Function can only be deleted by its owner.\u0027"},{"line_number":279,"context_line":"                )"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"            for version_db in func_db.versions:"},{"line_number":282,"context_line":"                version_jobs \u003d db_api.get_jobs("},{"line_number":283,"context_line":"                    function_id\u003dversion_db.function_id,"},{"line_number":284,"context_line":"                    function_version\u003dversion_db.version_number,"},{"line_number":285,"context_line":"                    status\u003d{\u0027nin\u0027: [\u0027done\u0027, \u0027cancelled\u0027]}"},{"line_number":286,"context_line":"                )"},{"line_number":287,"context_line":"                if len(version_jobs) \u003e 0:"},{"line_number":288,"context_line":"                    raise exc.NotAllowedException("},{"line_number":289,"context_line":"                        \u0027The function version is still associated with \u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"9f6a8fd7_3ca00242","line":286,"range":{"start_line":281,"start_character":0,"end_line":286,"end_character":17},"in_reply_to":"9f6a8fd7_3c0fa288","updated":"2018-04-26 03:57:47.000000000","message":"Yes, you are right! My mind is full of mess...","commit_id":"b562d0596bd5f14e1cd44c273ab919bac914aabf"},{"author":{"_account_id":21781,"name":"Hunt Xu","email":"mhuntxu@gmail.com","username":"huntxu"},"change_message_id":"9bcdf71d559683f5926e1e8e7ec43137a22b83e0","unresolved":false,"context_lines":[{"line_number":290,"context_line":"                        \u0027running job(s).\u0027"},{"line_number":291,"context_line":"                    )"},{"line_number":292,"context_line":""},{"line_number":293,"context_line":"                version_webhook \u003d db_api.get_webhooks("},{"line_number":294,"context_line":"                    function_id\u003dversion_db.function_id,"},{"line_number":295,"context_line":"                    function_version\u003dversion_db.version_number,"},{"line_number":296,"context_line":"                )"},{"line_number":297,"context_line":"                if len(version_webhook) \u003e 0:"},{"line_number":298,"context_line":"                    raise exc.NotAllowedException("},{"line_number":299,"context_line":"                        \u0027The function versioin is still associated with \u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"9f6a8fd7_dc29c6e5","line":296,"range":{"start_line":293,"start_character":0,"end_line":296,"end_character":17},"updated":"2018-04-26 03:53:21.000000000","message":"ditto for webhooks.","commit_id":"b562d0596bd5f14e1cd44c273ab919bac914aabf"},{"author":{"_account_id":21781,"name":"Hunt Xu","email":"mhuntxu@gmail.com","username":"huntxu"},"change_message_id":"9bcdf71d559683f5926e1e8e7ec43137a22b83e0","unresolved":false,"context_lines":[{"line_number":315,"context_line":"                    id,"},{"line_number":316,"context_line":"                    version\u003dversion_db.version_number"},{"line_number":317,"context_line":"                )"},{"line_number":318,"context_line":"                # Delete function version packages."},{"line_number":319,"context_line":"                self.storage_provider.delete("},{"line_number":320,"context_line":"                    func_db.project_id,"},{"line_number":321,"context_line":"                    id,"}],"source_content_type":"text/x-python","patch_set":3,"id":"9f6a8fd7_fc692a24","line":318,"updated":"2018-04-26 03:53:21.000000000","message":"For now the versioning feature is only allowed for package type function so the deletion is fine. Do you think it is needed to add a comment here that we might later have to do the source check before deleting the package data.","commit_id":"b562d0596bd5f14e1cd44c273ab919bac914aabf"},{"author":{"_account_id":6732,"name":"Lingxian Kong","email":"anlin.kong@gmail.com","username":"kong"},"change_message_id":"92565a53554cbbee903e2ea369dd7868441f6e0f","unresolved":false,"context_lines":[{"line_number":315,"context_line":"                    id,"},{"line_number":316,"context_line":"                    version\u003dversion_db.version_number"},{"line_number":317,"context_line":"                )"},{"line_number":318,"context_line":"                # Delete function version packages."},{"line_number":319,"context_line":"                self.storage_provider.delete("},{"line_number":320,"context_line":"                    func_db.project_id,"},{"line_number":321,"context_line":"                    id,"}],"source_content_type":"text/x-python","patch_set":3,"id":"9f6a8fd7_dc8a26bd","line":318,"in_reply_to":"9f6a8fd7_fc692a24","updated":"2018-04-26 03:57:47.000000000","message":"Good idea","commit_id":"b562d0596bd5f14e1cd44c273ab919bac914aabf"}]}
