)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"d2ae6083a5dbd6c788f4d024083111bb3156fb66","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"51935d73_dc5892fb","updated":"2023-11-09 15:22:15.000000000","message":"recheck","commit_id":"7a64552637451706db6395f7f28aef2d1091e846"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"b3408f93c789bed016ee03dfbed5742085fed0ba","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"1fa52fe3_f50ba6b5","updated":"2024-01-25 05:21:40.000000000","message":"recheck multiple failures","commit_id":"5ce687f2d1c643bde6ca438a15f3eb9bbe9b9d5b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"d5e596fe4f08906ef2281a26faab795843bf2b32","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"273c0b19_16f1b6ba","updated":"2024-02-01 06:07:50.000000000","message":"recheck ssh timeout, instance disappeared in between","commit_id":"5ce687f2d1c643bde6ca438a15f3eb9bbe9b9d5b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"820b9aeec00f33b8d247dceba0e117f9330b6e8f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"f8abf0b5_f0199fb5","updated":"2024-02-13 19:11:31.000000000","message":"Hi Dan,\nPlease refer the inline responses. Thank you for review!","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"1a2f4b6e_30ccf319","updated":"2024-02-14 18:25:38.000000000","message":"I must be missing something because it seems like all of the meat of the entire driver isn\u0027t tested. Just mocking out the meat and testing a few basically no-op things doesn\u0027t seem sufficient to me. I\u0027m guessing this will be somewhat covered in a tempest test near the end, but since we can\u0027t really validate that this is working in regular tempest, this seems to me to be very much lacking sufficient testing. If it\u0027s present in in the unit/functional in a later patch, please point me to it.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":15,"id":"8a956682_1a61c0d3","updated":"2024-02-14 19:33:01.000000000","message":"Thank you Dan for review. Please find inline responses for your comments.\n\n1. Functional test uses sqlite db and we are moving away from using sqlite db, but I can add those if you want.\n\n2. Unit tests uses simpleapi rather than actually calling sqlalchemy apis, so is it required to create in memory records and assert those based on simpleapi code?\n\n3. I am really depending on tempest tests and grenade job which I added towards end of these patch series to test it.\n\n4.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"2ef5486a990f3615fb6b6db1bf2b47ac25331a8a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"690d593d_22601d81","updated":"2024-02-14 10:02:57.000000000","message":"recheck failed to delete volume in given time","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"d9d6b81a2354b5d66eb8a3d00da37c1e41403fd3","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":15,"id":"9a763698_5fb27286","in_reply_to":"8a956682_1a61c0d3","updated":"2024-02-14 19:45:58.000000000","message":"All the code in the driver should be testable in unit tests. Obviously you can\u0027t test the actual mysql stuff without mysql, but all the filesystem manipulation should be exercised, IMHO, and the in-memory persistence should be fine for that. There are many lines in your driver that could have typos or other errors that we wouldn\u0027t even know about because they\u0027re never run.\n\nTempest tests are good, but we can\u0027t _validate_ that the stuff is actually working on the tempest jobs, which means it could be working, broken, or not even enabled. So, it\u0027s good to enable them in a job and exercise it, but it\u0027s not sufficient, IMHO.\n\nAlso, I don\u0027t remember if glance uses these, but you know that our jobs are configured to be able to use MySQL from unit/functional tests right? So-called \"opportunistic tests\", which run if/when MySQL is available.\n\nhttps://docs.openstack.org/oslo.db/latest/reference/api/oslo_db.sqlalchemy.html#oslo_db.sqlalchemy.test_fixtures.OpportunisticDBTestMixin","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"660b86468957704384b3032ef3b2d8947535b0e8","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":15,"id":"f52d920f_a0cf53e4","in_reply_to":"9a763698_5fb27286","updated":"2024-02-14 19:54:47.000000000","message":"Yes, I think glance has some tests of db migrations which runs if mysql is available. Will check for it. \n\nAlso will modify the unit tests, to create some in memory records and validate the calls.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"79c588d2_90c6bab1","in_reply_to":"f52d920f_a0cf53e4","updated":"2024-02-15 17:53:07.000000000","message":"Acknowledged","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"14992eaa_891f7b8e","updated":"2024-02-15 17:53:07.000000000","message":"Thank you for review Dan!!\nPlease have a look at new PS!!","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"98496a7b30f62b03d36b0ecd6536e054b284c78f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"1e232b1e_435a4b57","updated":"2024-02-20 14:59:58.000000000","message":"Seems pretty exhaustingly covered now. Thanks for doing that!","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"change_message_id":"5a5e2b8fee9b994484ac481c2671b27db6c1e93f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"0319d0bd_9ca10b5a","updated":"2024-02-27 14:59:22.000000000","message":"Some nitpicking because you left \"xattr\" in a docstring, but this can be addressed in a follow-up patch.\n\nI\u0027ll just +2 since the gate fails on the previous patch, feel free to +W if it is urgent to merge.\n\nAlso there is a lot of code that is common to multiple drivers, I wonder if we\u0027d want to refactor that a bit in the future.","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"change_message_id":"3cab942bddf93495633a86d6af5f760de4ee8c60","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"411d7ff1_ddd74e75","updated":"2024-02-27 17:54:44.000000000","message":"Sounds good to me!","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"132dd06a_aa8c46c5","updated":"2024-02-16 17:12:58.000000000","message":"Thank you for review Dan!!","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"02f62b61fbbe22914a720be15d42effde75f7ba3","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"8e4d462b_47b1f2d8","updated":"2024-02-26 20:38:04.000000000","message":"recheck","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"128b8b6307ca1a439a6d1b2bee42b2ef82ed10fc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"b02e16d4_c833aedf","updated":"2024-02-25 03:50:10.000000000","message":"recheck","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"dd31ffe6f2d8603b14b4d33687ae62f0aa8e42d4","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"c3bd1940_00e8711c","updated":"2024-02-23 20:03:51.000000000","message":"recheck","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":27615,"name":"Rajat Dhasmana","email":"rajatdhasmana@gmail.com","username":"whoami-rajat"},"change_message_id":"d10963a89c94e009bdf03af752217be2ff042d8f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"9ed8a145_3381b2e2","updated":"2024-02-26 18:30:26.000000000","message":"recheck cinder import job failed\nvolume wasn\u0027t in right state\n\nDetails: {\u0027code\u0027: 400, \u0027message\u0027: \u0027Invalid volume: Volume status must be available or error or error_restoring or error_extending or error_managing and must not be migrating, attached, belong to a group, have snapshots, awaiting a transfer, or be disassociated from snapshots after volume transfer.\u0027}","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"43c0c3bdf206b04141634daef7e48c122506df8a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"19b93995_50abe463","updated":"2024-02-23 10:41:03.000000000","message":"recheck nova-ceph job fixed","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"671284d0cdabdde378f5d769f45c47eb5e60c940","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"4db18e44_b7636c56","updated":"2024-02-26 22:47:27.000000000","message":"recheck reset volume failure","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"00b513981c8b26c0a17a8308a0fdcdcfa1bbdcad","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"729978e3_cd8bc048","in_reply_to":"0319d0bd_9ca10b5a","updated":"2024-02-27 17:42:49.000000000","message":"We can refactor that in next cycle.\nI will push a separate patch to fix the docstring on top of it.","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"}],"glance/image_cache/drivers/centralized_db.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d06b9022c8cf1a0a6ea1d19176d7f176c5d2408","unresolved":true,"context_lines":[{"line_number":177,"context_line":"        Removes all queued image files and any attributes about the images"},{"line_number":178,"context_line":"        \"\"\""},{"line_number":179,"context_line":"        files \u003d [f for f in self.get_cache_files(self.queue_dir)]"},{"line_number":180,"context_line":"        for file in files:"},{"line_number":181,"context_line":"            fileutils.delete_if_exists(file)"},{"line_number":182,"context_line":"        return len(files)"},{"line_number":183,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"8ae7c0d5_5e4c1d0d","line":180,"updated":"2024-02-13 19:00:36.000000000","message":"Why build the list by iterating and then iterate? Can we not just do:\n```\nfor file in self.get_cache_files(...):\n  ...\n```\n?","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"820b9aeec00f33b8d247dceba0e117f9330b6e8f","unresolved":true,"context_lines":[{"line_number":177,"context_line":"        Removes all queued image files and any attributes about the images"},{"line_number":178,"context_line":"        \"\"\""},{"line_number":179,"context_line":"        files \u003d [f for f in self.get_cache_files(self.queue_dir)]"},{"line_number":180,"context_line":"        for file in files:"},{"line_number":181,"context_line":"            fileutils.delete_if_exists(file)"},{"line_number":182,"context_line":"        return len(files)"},{"line_number":183,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"b1851c22_eb622ed8","line":180,"in_reply_to":"8ae7c0d5_5e4c1d0d","updated":"2024-02-13 19:11:31.000000000","message":"Just copied it from sqlite driver, will do the change.","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"044b8322303ae998528829eb25f1a193d00192fb","unresolved":false,"context_lines":[{"line_number":177,"context_line":"        Removes all queued image files and any attributes about the images"},{"line_number":178,"context_line":"        \"\"\""},{"line_number":179,"context_line":"        files \u003d [f for f in self.get_cache_files(self.queue_dir)]"},{"line_number":180,"context_line":"        for file in files:"},{"line_number":181,"context_line":"            fileutils.delete_if_exists(file)"},{"line_number":182,"context_line":"        return len(files)"},{"line_number":183,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"1ea0849a_060f82b6","line":180,"in_reply_to":"b1851c22_eb622ed8","updated":"2024-02-14 05:36:14.000000000","message":"Done","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d06b9022c8cf1a0a6ea1d19176d7f176c5d2408","unresolved":true,"context_lines":[{"line_number":295,"context_line":"        \"\"\""},{"line_number":296,"context_line":"        path \u003d self.get_image_filepath(image_id)"},{"line_number":297,"context_line":"        with open(path, \u0027rb\u0027) as cache_file:"},{"line_number":298,"context_line":"            yield cache_file"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":301,"context_line":"        self.db_api.update_hit_count("}],"source_content_type":"text/x-python","patch_set":14,"id":"46ce022a_0d4cb5e3","line":298,"updated":"2024-02-13 19:00:36.000000000","message":"If whatever uses us crashes we won\u0027t update hit count. Shouldn\u0027t we do:\n```\ntry:\n   with open(...) as cache_file:\n       yield cache_file\nfinally:\n    db.update_hit_count(...)\n```\n?\n\nJust because whatever tried to read the cache file aborted due to any other reason, I would think we\u0027d still want to update the count...","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"820b9aeec00f33b8d247dceba0e117f9330b6e8f","unresolved":true,"context_lines":[{"line_number":295,"context_line":"        \"\"\""},{"line_number":296,"context_line":"        path \u003d self.get_image_filepath(image_id)"},{"line_number":297,"context_line":"        with open(path, \u0027rb\u0027) as cache_file:"},{"line_number":298,"context_line":"            yield cache_file"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":301,"context_line":"        self.db_api.update_hit_count("}],"source_content_type":"text/x-python","patch_set":14,"id":"ac2512d6_e6025801","line":298,"in_reply_to":"46ce022a_0d4cb5e3","updated":"2024-02-13 19:11:31.000000000","message":"ack, tried to keep it similar to sqlite driver.","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"044b8322303ae998528829eb25f1a193d00192fb","unresolved":false,"context_lines":[{"line_number":295,"context_line":"        \"\"\""},{"line_number":296,"context_line":"        path \u003d self.get_image_filepath(image_id)"},{"line_number":297,"context_line":"        with open(path, \u0027rb\u0027) as cache_file:"},{"line_number":298,"context_line":"            yield cache_file"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":301,"context_line":"        self.db_api.update_hit_count("}],"source_content_type":"text/x-python","patch_set":14,"id":"4fd140b9_2ef54ea8","line":298,"in_reply_to":"ac2512d6_e6025801","updated":"2024-02-14 05:36:14.000000000","message":"Acknowledged","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d06b9022c8cf1a0a6ea1d19176d7f176c5d2408","unresolved":true,"context_lines":[{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        # Touch the file to add it to the queue"},{"line_number":329,"context_line":"        with open(path, \"w\"):"},{"line_number":330,"context_line":"            pass"},{"line_number":331,"context_line":""},{"line_number":332,"context_line":"        return True"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"939171d4_67298f0c","line":330,"updated":"2024-02-13 19:00:36.000000000","message":"I guess I\u0027m not sure why we need to do this since we have the database telling us which ones should be cached and we know which ones aren\u0027t on disk. What am I missing?","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4c6c44779f9602e534a77e630d052c2a60f8ea6a","unresolved":true,"context_lines":[{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        # Touch the file to add it to the queue"},{"line_number":329,"context_line":"        with open(path, \"w\"):"},{"line_number":330,"context_line":"            pass"},{"line_number":331,"context_line":""},{"line_number":332,"context_line":"        return True"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"839825de_b794d7c8","line":330,"in_reply_to":"284d1b9e_bb0ccab4","updated":"2024-02-13 19:17:59.000000000","message":"Okay, we can tell from just cached + DB, but we have to iterate them all I guess. Fair enough, it just seems weird to maintain state in two places as it becomes easier to get them out of sync and/or be confused about the state of the system from the outside. I obviously haven\u0027t looked at the design of the driver we\u0027re replacing, just trying to make sure the new thing is sane :)\n\nAnyway, just a comment, no need to change.","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"044b8322303ae998528829eb25f1a193d00192fb","unresolved":false,"context_lines":[{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        # Touch the file to add it to the queue"},{"line_number":329,"context_line":"        with open(path, \"w\"):"},{"line_number":330,"context_line":"            pass"},{"line_number":331,"context_line":""},{"line_number":332,"context_line":"        return True"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"5f524489_07eeae8c","line":330,"in_reply_to":"839825de_b794d7c8","updated":"2024-02-14 05:36:14.000000000","message":"Acknowledged","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"820b9aeec00f33b8d247dceba0e117f9330b6e8f","unresolved":true,"context_lines":[{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        # Touch the file to add it to the queue"},{"line_number":329,"context_line":"        with open(path, \"w\"):"},{"line_number":330,"context_line":"            pass"},{"line_number":331,"context_line":""},{"line_number":332,"context_line":"        return True"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"284d1b9e_bb0ccab4","line":330,"in_reply_to":"939171d4_67298f0c","updated":"2024-02-13 19:11:31.000000000","message":"we have queued directory inside cache_dir where we create empty file and then move it under cache directory. This is what how it is implemented in sqlite, also we don\u0027t have cache state column in db so can not decide it based on database.\n\nIf we decided to add new column to the centralized db then we can change this implementation, but I think this should be treated as further enhancement and should be carried out in next cycle?","commit_id":"ee6cc44bfc196b1f599a29baa965bbfd7b1c173b"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":63,"context_line":"        # NOTE(abhishekk): Record the node reference in the database for"},{"line_number":64,"context_line":"        # future use."},{"line_number":65,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":66,"context_line":"        if node_reference_url:"},{"line_number":67,"context_line":"            try:"},{"line_number":68,"context_line":"                self.db_api.node_reference_create("},{"line_number":69,"context_line":"                    self.context, node_reference_url)"}],"source_content_type":"text/x-python","patch_set":15,"id":"c1023429_43e89892","line":66,"updated":"2024-02-14 18:25:38.000000000","message":"It doesn\u0027t look like you set `self_reference_url` anywhere in your tests such that this actually gets run...","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":63,"context_line":"        # NOTE(abhishekk): Record the node reference in the database for"},{"line_number":64,"context_line":"        # future use."},{"line_number":65,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":66,"context_line":"        if node_reference_url:"},{"line_number":67,"context_line":"            try:"},{"line_number":68,"context_line":"                self.db_api.node_reference_create("},{"line_number":69,"context_line":"                    self.context, node_reference_url)"}],"source_content_type":"text/x-python","patch_set":15,"id":"c005f5e0_9c885931","line":66,"in_reply_to":"0117cc5d_317689dc","updated":"2024-02-15 21:42:25.000000000","message":"Unit test that mocks the create to raise Duplicate?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":63,"context_line":"        # NOTE(abhishekk): Record the node reference in the database for"},{"line_number":64,"context_line":"        # future use."},{"line_number":65,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":66,"context_line":"        if node_reference_url:"},{"line_number":67,"context_line":"            try:"},{"line_number":68,"context_line":"                self.db_api.node_reference_create("},{"line_number":69,"context_line":"                    self.context, node_reference_url)"}],"source_content_type":"text/x-python","patch_set":15,"id":"28aead17_47859e09","line":66,"in_reply_to":"c005f5e0_9c885931","updated":"2024-02-16 17:12:58.000000000","message":"test_node_reference_create_duplicate unit test","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":true,"context_lines":[{"line_number":63,"context_line":"        # NOTE(abhishekk): Record the node reference in the database for"},{"line_number":64,"context_line":"        # future use."},{"line_number":65,"context_line":"        node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":66,"context_line":"        if node_reference_url:"},{"line_number":67,"context_line":"            try:"},{"line_number":68,"context_line":"                self.db_api.node_reference_create("},{"line_number":69,"context_line":"                    self.context, node_reference_url)"}],"source_content_type":"text/x-python","patch_set":15,"id":"0117cc5d_317689dc","line":66,"in_reply_to":"c1023429_43e89892","updated":"2024-02-15 17:53:07.000000000","message":"Added test to check it is set but I didn\u0027t found way to test duplicate error!","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":176,"context_line":"        \"\"\""},{"line_number":177,"context_line":"        Removes all queued image files and any attributes about the images"},{"line_number":178,"context_line":"        \"\"\""},{"line_number":179,"context_line":"        files_deleted \u003d 0"},{"line_number":180,"context_line":"        for file in self.get_cache_files(self.queue_dir):"},{"line_number":181,"context_line":"            fileutils.delete_if_exists(file)"},{"line_number":182,"context_line":"            files_deleted +\u003d 1"}],"source_content_type":"text/x-python","patch_set":15,"id":"10862a8b_93a51566","line":179,"updated":"2024-02-14 18:25:38.000000000","message":"No need to change it, but you can use `enumerate` to avoid needing this separate variable:\n```\nfor i, f in enumerate(files):\n    delete_if...\nreturn i + 1\n```","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":false,"context_lines":[{"line_number":176,"context_line":"        \"\"\""},{"line_number":177,"context_line":"        Removes all queued image files and any attributes about the images"},{"line_number":178,"context_line":"        \"\"\""},{"line_number":179,"context_line":"        files_deleted \u003d 0"},{"line_number":180,"context_line":"        for file in self.get_cache_files(self.queue_dir):"},{"line_number":181,"context_line":"            fileutils.delete_if_exists(file)"},{"line_number":182,"context_line":"            files_deleted +\u003d 1"}],"source_content_type":"text/x-python","patch_set":15,"id":"df08ac67_1b2a47d0","line":179,"in_reply_to":"10862a8b_93a51566","updated":"2024-02-14 19:33:01.000000000","message":"Acknowledged","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":301,"context_line":"        finally:"},{"line_number":302,"context_line":"            node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":303,"context_line":"            self.db_api.update_hit_count("},{"line_number":304,"context_line":"                self.context, image_id, node_reference_url)"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"    def queue_image(self, image_id):"},{"line_number":307,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":15,"id":"597d50e5_d1cb6e41","line":304,"updated":"2024-02-14 18:25:38.000000000","message":"Where are either of these `open_for` methods actually tested?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":301,"context_line":"        finally:"},{"line_number":302,"context_line":"            node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":303,"context_line":"            self.db_api.update_hit_count("},{"line_number":304,"context_line":"                self.context, image_id, node_reference_url)"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"    def queue_image(self, image_id):"},{"line_number":307,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":15,"id":"2ff2f284_ea4b4076","line":304,"in_reply_to":"120088b1_6aba29be","updated":"2024-02-15 17:53:07.000000000","message":"Added functional + unit test to test both these methods!","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":301,"context_line":"        finally:"},{"line_number":302,"context_line":"            node_reference_url \u003d CONF.worker_self_reference_url"},{"line_number":303,"context_line":"            self.db_api.update_hit_count("},{"line_number":304,"context_line":"                self.context, image_id, node_reference_url)"},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"    def queue_image(self, image_id):"},{"line_number":307,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":15,"id":"120088b1_6aba29be","line":304,"in_reply_to":"597d50e5_d1cb6e41","updated":"2024-02-14 19:33:01.000000000","message":"these is tested in image-download case, 1st when you call image-download it caches the image, 2nd download call will be executing this open_for_read method and calls for update the hit count.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":219,"context_line":"        try:"},{"line_number":220,"context_line":"            file_info \u003d os.stat(path)"},{"line_number":221,"context_line":"            size \u003d file_info[stat.ST_SIZE]"},{"line_number":222,"context_line":"        except OSError:"},{"line_number":223,"context_line":"            size \u003d 0"},{"line_number":224,"context_line":"        return image_id, size"},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"b1121135_d80ce87b","line":222,"updated":"2024-02-15 21:42:25.000000000","message":"Am I missing where you hit this?","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"f89e540db7b2e3fa67de468064ed4b7eb71be103","unresolved":true,"context_lines":[{"line_number":219,"context_line":"        try:"},{"line_number":220,"context_line":"            file_info \u003d os.stat(path)"},{"line_number":221,"context_line":"            size \u003d file_info[stat.ST_SIZE]"},{"line_number":222,"context_line":"        except OSError:"},{"line_number":223,"context_line":"            size \u003d 0"},{"line_number":224,"context_line":"        return image_id, size"},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"51d032be_a5311440","line":222,"in_reply_to":"7f2f570c_2df4ddbe","updated":"2024-02-16 14:49:22.000000000","message":"Unit is fine if it\u0027s hard to do in functional. I\u0027m just saying, you\u0027re not showing that you do actually catch this and return zero in that scenario AFAICT.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":219,"context_line":"        try:"},{"line_number":220,"context_line":"            file_info \u003d os.stat(path)"},{"line_number":221,"context_line":"            size \u003d file_info[stat.ST_SIZE]"},{"line_number":222,"context_line":"        except OSError:"},{"line_number":223,"context_line":"            size \u003d 0"},{"line_number":224,"context_line":"        return image_id, size"},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"72a1d57d_bbc30dac","line":222,"in_reply_to":"7f2f570c_2df4ddbe","updated":"2024-02-16 17:12:58.000000000","message":"test_get_least_recently_accessed_os_error in test_image_cache.py","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"52072e9d2b17c256b1dc3717e1c9f45332e2731b","unresolved":true,"context_lines":[{"line_number":219,"context_line":"        try:"},{"line_number":220,"context_line":"            file_info \u003d os.stat(path)"},{"line_number":221,"context_line":"            size \u003d file_info[stat.ST_SIZE]"},{"line_number":222,"context_line":"        except OSError:"},{"line_number":223,"context_line":"            size \u003d 0"},{"line_number":224,"context_line":"        return image_id, size"},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7f2f570c_2df4ddbe","line":222,"in_reply_to":"b1121135_d80ce87b","updated":"2024-02-16 04:29:37.000000000","message":"do you mean in tests or in actual scenario when it will be raised?\nI will cover this in unit test.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":323,"context_line":""},{"line_number":324,"context_line":"        if self.is_queued(image_id):"},{"line_number":325,"context_line":"            LOG.info(_LI(\"Not queueing image \u0027%s\u0027. Already queued.\"), image_id)"},{"line_number":326,"context_line":"            return False"},{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        path \u003d self.get_image_filepath(image_id, \u0027queue\u0027)"},{"line_number":329,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"8b16e33f_29ca6110","line":326,"updated":"2024-02-15 21:42:25.000000000","message":"Are you hitting these three conditionals?","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":323,"context_line":""},{"line_number":324,"context_line":"        if self.is_queued(image_id):"},{"line_number":325,"context_line":"            LOG.info(_LI(\"Not queueing image \u0027%s\u0027. Already queued.\"), image_id)"},{"line_number":326,"context_line":"            return False"},{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        path \u003d self.get_image_filepath(image_id, \u0027queue\u0027)"},{"line_number":329,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"46d95ad9_786a7624","line":326,"in_reply_to":"1285528e_0c1844c5","updated":"2024-02-16 17:12:58.000000000","message":"test_queue in test_image_cache.py","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"52072e9d2b17c256b1dc3717e1c9f45332e2731b","unresolved":true,"context_lines":[{"line_number":323,"context_line":""},{"line_number":324,"context_line":"        if self.is_queued(image_id):"},{"line_number":325,"context_line":"            LOG.info(_LI(\"Not queueing image \u0027%s\u0027. Already queued.\"), image_id)"},{"line_number":326,"context_line":"            return False"},{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        path \u003d self.get_image_filepath(image_id, \u0027queue\u0027)"},{"line_number":329,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1285528e_0c1844c5","line":326,"in_reply_to":"8b16e33f_29ca6110","updated":"2024-02-16 04:29:37.000000000","message":"No, I will cover this unit/functional/both tests","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":354,"context_line":"                try:"},{"line_number":355,"context_line":"                    fileutils.delete_if_exists(path)"},{"line_number":356,"context_line":"                    LOG.info(_LI(\"Removed stalled cache file %s\"), path)"},{"line_number":357,"context_line":"                except Exception as e:"},{"line_number":358,"context_line":"                    msg \u003d (_LW(\"Failed to delete file %(path)s. \""},{"line_number":359,"context_line":"                               \"Got error: %(e)s\"),"},{"line_number":360,"context_line":"                           dict(path\u003dpath, e\u003de))"}],"source_content_type":"text/x-python","patch_set":16,"id":"84494bfe_53998854","line":357,"updated":"2024-02-15 21:42:25.000000000","message":"I still think the Exception path in this and the above invalid one aren\u0027t getting covered. Should be easy to do that with unit tests right?","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":354,"context_line":"                try:"},{"line_number":355,"context_line":"                    fileutils.delete_if_exists(path)"},{"line_number":356,"context_line":"                    LOG.info(_LI(\"Removed stalled cache file %s\"), path)"},{"line_number":357,"context_line":"                except Exception as e:"},{"line_number":358,"context_line":"                    msg \u003d (_LW(\"Failed to delete file %(path)s. \""},{"line_number":359,"context_line":"                               \"Got error: %(e)s\"),"},{"line_number":360,"context_line":"                           dict(path\u003dpath, e\u003de))"}],"source_content_type":"text/x-python","patch_set":16,"id":"5c674b88_6af0c2c9","line":357,"in_reply_to":"4a470b90_7c41ece3","updated":"2024-02-16 17:12:58.000000000","message":"Done","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"f89e540db7b2e3fa67de468064ed4b7eb71be103","unresolved":true,"context_lines":[{"line_number":354,"context_line":"                try:"},{"line_number":355,"context_line":"                    fileutils.delete_if_exists(path)"},{"line_number":356,"context_line":"                    LOG.info(_LI(\"Removed stalled cache file %s\"), path)"},{"line_number":357,"context_line":"                except Exception as e:"},{"line_number":358,"context_line":"                    msg \u003d (_LW(\"Failed to delete file %(path)s. \""},{"line_number":359,"context_line":"                               \"Got error: %(e)s\"),"},{"line_number":360,"context_line":"                           dict(path\u003dpath, e\u003de))"}],"source_content_type":"text/x-python","patch_set":16,"id":"21bb75da_eeed6aa2","line":357,"in_reply_to":"4a470b90_7c41ece3","updated":"2024-02-16 14:49:22.000000000","message":"I think both exception cases in `delete_stalled_files()` and `delete_invalid_files()` is untested.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"52072e9d2b17c256b1dc3717e1c9f45332e2731b","unresolved":true,"context_lines":[{"line_number":354,"context_line":"                try:"},{"line_number":355,"context_line":"                    fileutils.delete_if_exists(path)"},{"line_number":356,"context_line":"                    LOG.info(_LI(\"Removed stalled cache file %s\"), path)"},{"line_number":357,"context_line":"                except Exception as e:"},{"line_number":358,"context_line":"                    msg \u003d (_LW(\"Failed to delete file %(path)s. \""},{"line_number":359,"context_line":"                               \"Got error: %(e)s\"),"},{"line_number":360,"context_line":"                           dict(path\u003dpath, e\u003de))"}],"source_content_type":"text/x-python","patch_set":16,"id":"4a470b90_7c41ece3","line":357,"in_reply_to":"84494bfe_53998854","updated":"2024-02-16 04:29:37.000000000","message":"I will cover this in unit test, but which invalid one you are talking about, delete_invalid_files or something else?","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"change_message_id":"5a5e2b8fee9b994484ac481c2671b27db6c1e93f","unresolved":true,"context_lines":[{"line_number":42,"context_line":"class Driver(base.Driver):"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    \"\"\""},{"line_number":45,"context_line":"    Cache driver that uses xattr file tags and requires a filesystem"},{"line_number":46,"context_line":"    that has atimes set."},{"line_number":47,"context_line":"    \"\"\""},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":17,"id":"e38eaa1e_23804079","line":45,"updated":"2024-02-27 14:59:22.000000000","message":"This looks like a copy/paste from xattr.py","commit_id":"0bbaec2eeb489b1f362e066749c3f71d05e02602"}],"glance/tests/functional/image_cache/drivers/test_centralized_db.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":181,"context_line":"        self.assertEqual(1, len(self.driver.get_cached_images()))"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        # Verify that passing non-existing node will be"},{"line_number":184,"context_line":"        # returned as 0 cached images"},{"line_number":185,"context_line":"        self.config(worker_self_reference_url\u003d\"http://fake-worker\")"},{"line_number":186,"context_line":"        self.assertEqual(0, len(self.driver.get_cached_images()))"},{"line_number":187,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"a8996e9f_148617ae","line":184,"updated":"2024-02-15 21:42:25.000000000","message":"The code has a NotFound exception handler. Is that no longer needed? If it is needed, I don\u0027t think you\u0027re covering that here.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"52072e9d2b17c256b1dc3717e1c9f45332e2731b","unresolved":true,"context_lines":[{"line_number":181,"context_line":"        self.assertEqual(1, len(self.driver.get_cached_images()))"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        # Verify that passing non-existing node will be"},{"line_number":184,"context_line":"        # returned as 0 cached images"},{"line_number":185,"context_line":"        self.config(worker_self_reference_url\u003d\"http://fake-worker\")"},{"line_number":186,"context_line":"        self.assertEqual(0, len(self.driver.get_cached_images()))"},{"line_number":187,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"d9e8b0df_75339fcc","line":184,"in_reply_to":"a8996e9f_148617ae","updated":"2024-02-16 04:29:37.000000000","message":"Ack, will check and cover accordingly.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":181,"context_line":"        self.assertEqual(1, len(self.driver.get_cached_images()))"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        # Verify that passing non-existing node will be"},{"line_number":184,"context_line":"        # returned as 0 cached images"},{"line_number":185,"context_line":"        self.config(worker_self_reference_url\u003d\"http://fake-worker\")"},{"line_number":186,"context_line":"        self.assertEqual(0, len(self.driver.get_cached_images()))"},{"line_number":187,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"f1302d5c_44ab8292","line":184,"in_reply_to":"d9e8b0df_75339fcc","updated":"2024-02-16 17:12:58.000000000","message":"Removed, thank you!","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"0eeb786852a7db40ff4b4e73fd81df2978e0445a","unresolved":true,"context_lines":[{"line_number":348,"context_line":"        self.assertTrue(os.path.exists(incomplete_file_path))"},{"line_number":349,"context_line":""},{"line_number":350,"context_line":"        self.delay_inaccurate_clock()"},{"line_number":351,"context_line":"        self.driver.clean(stall_time\u003d0)"},{"line_number":352,"context_line":""},{"line_number":353,"context_line":"        self.assertFalse(os.path.exists(incomplete_file_path))"},{"line_number":354,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"129ea854_56786d6e","line":351,"updated":"2024-02-15 21:42:25.000000000","message":"This doesn\u0027t cover the \"if stall_time is None\" case.","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"52072e9d2b17c256b1dc3717e1c9f45332e2731b","unresolved":true,"context_lines":[{"line_number":348,"context_line":"        self.assertTrue(os.path.exists(incomplete_file_path))"},{"line_number":349,"context_line":""},{"line_number":350,"context_line":"        self.delay_inaccurate_clock()"},{"line_number":351,"context_line":"        self.driver.clean(stall_time\u003d0)"},{"line_number":352,"context_line":""},{"line_number":353,"context_line":"        self.assertFalse(os.path.exists(incomplete_file_path))"},{"line_number":354,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"fb8d3260_948daa2b","line":351,"in_reply_to":"129ea854_56786d6e","updated":"2024-02-16 04:29:37.000000000","message":"ack, will check and cover accordingly!","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"6733a9ae024514981867be54e7d2e96d007a29d5","unresolved":false,"context_lines":[{"line_number":348,"context_line":"        self.assertTrue(os.path.exists(incomplete_file_path))"},{"line_number":349,"context_line":""},{"line_number":350,"context_line":"        self.delay_inaccurate_clock()"},{"line_number":351,"context_line":"        self.driver.clean(stall_time\u003d0)"},{"line_number":352,"context_line":""},{"line_number":353,"context_line":"        self.assertFalse(os.path.exists(incomplete_file_path))"},{"line_number":354,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"55e4989b_b5ceeb49","line":351,"in_reply_to":"fb8d3260_948daa2b","updated":"2024-02-16 17:12:58.000000000","message":"Done","commit_id":"50cf2b0b00e0320b1bccd6759e94e721914a1727"}],"glance/tests/unit/image_cache/drivers/test_centralized_db.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":62,"context_line":"        self.driver.configure()"},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"    def test_get_cache_size(self):"},{"line_number":65,"context_line":"        self.assertIsNotNone(self.driver.get_cache_size)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def test_get_hit_count(self):"},{"line_number":68,"context_line":"        fake_image \u003d \"fake_image\""}],"source_content_type":"text/x-python","patch_set":15,"id":"ed3e9c13_711c2a82","line":65,"updated":"2024-02-14 18:25:38.000000000","message":"This doesn\u0027t actually run it because you\u0027re missing `()` so this will always be true because it\u0027s defined.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":false,"context_lines":[{"line_number":62,"context_line":"        self.driver.configure()"},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"    def test_get_cache_size(self):"},{"line_number":65,"context_line":"        self.assertIsNotNone(self.driver.get_cache_size)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def test_get_hit_count(self):"},{"line_number":68,"context_line":"        fake_image \u003d \"fake_image\""}],"source_content_type":"text/x-python","patch_set":15,"id":"4b15bb13_4f817ab8","line":65,"in_reply_to":"ed3e9c13_711c2a82","updated":"2024-02-14 19:33:01.000000000","message":"Acknowledged","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":71,"context_line":""},{"line_number":72,"context_line":"    def test_get_cached_images(self):"},{"line_number":73,"context_line":"        cached_images \u003d self.driver.get_cached_images()"},{"line_number":74,"context_line":"        self.assertEqual(0, len(cached_images))"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def test_is_queued(self):"},{"line_number":77,"context_line":"        self.assertFalse(self.driver.is_queued(\"fake-image\"))"}],"source_content_type":"text/x-python","patch_set":15,"id":"938353b0_0eaaf4c4","line":74,"updated":"2024-02-14 18:25:38.000000000","message":"Where\u0027s the test for a cached image that actually returns a nonzero hit count?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":71,"context_line":""},{"line_number":72,"context_line":"    def test_get_cached_images(self):"},{"line_number":73,"context_line":"        cached_images \u003d self.driver.get_cached_images()"},{"line_number":74,"context_line":"        self.assertEqual(0, len(cached_images))"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def test_is_queued(self):"},{"line_number":77,"context_line":"        self.assertFalse(self.driver.is_queued(\"fake-image\"))"}],"source_content_type":"text/x-python","patch_set":15,"id":"00e89ad1_228d0a10","line":74,"in_reply_to":"938353b0_0eaaf4c4","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":74,"context_line":"        self.assertEqual(0, len(cached_images))"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def test_is_queued(self):"},{"line_number":77,"context_line":"        self.assertFalse(self.driver.is_queued(\"fake-image\"))"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def test_delete_all_cached_images(self):"},{"line_number":80,"context_line":"        self.driver.get_cache_files \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":15,"id":"78b41773_9e3c0f67","line":77,"updated":"2024-02-14 18:25:38.000000000","message":"Where\u0027s the True case?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":74,"context_line":"        self.assertEqual(0, len(cached_images))"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def test_is_queued(self):"},{"line_number":77,"context_line":"        self.assertFalse(self.driver.is_queued(\"fake-image\"))"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def test_delete_all_cached_images(self):"},{"line_number":80,"context_line":"        self.driver.get_cache_files \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":15,"id":"f61b8b29_b6b09b7e","line":77,"in_reply_to":"78b41773_9e3c0f67","updated":"2024-02-14 19:33:01.000000000","message":"Ack, will add it, the problem is as soon as we call cache-queue it immediately start caching of that image, so the image does not remains in queue for long time.\n\nI will try to find out the way to check this.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":74,"context_line":"        self.assertEqual(0, len(cached_images))"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def test_is_queued(self):"},{"line_number":77,"context_line":"        self.assertFalse(self.driver.is_queued(\"fake-image\"))"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def test_delete_all_cached_images(self):"},{"line_number":80,"context_line":"        self.driver.get_cache_files \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":15,"id":"8990e082_70f575d5","line":77,"in_reply_to":"f61b8b29_b6b09b7e","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def test_delete_cached_image(self):"},{"line_number":87,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":88,"context_line":"        # exception as nothing is in db"},{"line_number":89,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":90,"context_line":"                          self.driver.delete_cached_image, \"fake-image\")"},{"line_number":91,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"70f442ac_6639d122","line":88,"updated":"2024-02-14 18:25:38.000000000","message":"Okay, but there\u0027s no test that actually tests the deletes...?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def test_delete_cached_image(self):"},{"line_number":87,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":88,"context_line":"        # exception as nothing is in db"},{"line_number":89,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":90,"context_line":"                          self.driver.delete_cached_image, \"fake-image\")"},{"line_number":91,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"06a29d83_c32a173f","line":88,"in_reply_to":"4a7cd4a0_810ea078","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def test_delete_cached_image(self):"},{"line_number":87,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":88,"context_line":"        # exception as nothing is in db"},{"line_number":89,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":90,"context_line":"                          self.driver.delete_cached_image, \"fake-image\")"},{"line_number":91,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"4a7cd4a0_810ea078","line":88,"in_reply_to":"70f442ac_6639d122","updated":"2024-02-14 19:33:01.000000000","message":"In later patches I\u0027m depending on tempest tests to validate these scenarios.\n\nThe issue here is our functional tests is using sqlite db and IMO if I need to write functional tests for this then I need to create and destroy db in mysql.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def test_delete_all_queued_images(self):"},{"line_number":93,"context_line":"        deleted \u003d self.driver.delete_all_queued_images()"},{"line_number":94,"context_line":"        self.assertEqual(0, deleted)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"    def test_delete_queued_image(self):"},{"line_number":97,"context_line":"        with mock.patch.object(fileutils, \u0027delete_if_exists\u0027) as mock_del:"}],"source_content_type":"text/x-python","patch_set":15,"id":"fa535216_14b9205c","line":94,"updated":"2024-02-14 18:25:38.000000000","message":"Same here, this is just a no-op?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def test_delete_all_queued_images(self):"},{"line_number":93,"context_line":"        deleted \u003d self.driver.delete_all_queued_images()"},{"line_number":94,"context_line":"        self.assertEqual(0, deleted)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"    def test_delete_queued_image(self):"},{"line_number":97,"context_line":"        with mock.patch.object(fileutils, \u0027delete_if_exists\u0027) as mock_del:"}],"source_content_type":"text/x-python","patch_set":15,"id":"35e1c337_7d7ceded","line":94,"in_reply_to":"b5e4950a_f72f1552","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def test_delete_all_queued_images(self):"},{"line_number":93,"context_line":"        deleted \u003d self.driver.delete_all_queued_images()"},{"line_number":94,"context_line":"        self.assertEqual(0, deleted)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"    def test_delete_queued_image(self):"},{"line_number":97,"context_line":"        with mock.patch.object(fileutils, \u0027delete_if_exists\u0027) as mock_del:"}],"source_content_type":"text/x-python","patch_set":15,"id":"b5e4950a_f72f1552","line":94,"in_reply_to":"fa535216_14b9205c","updated":"2024-02-14 19:33:01.000000000","message":"yes, I will explore more about it.\nThese are unit tests, which is using simpleapi which has hardcoded data store, so I didn\u0027t bothered to create the data and deleting it in memory. Just wanted to check the actual method is get called without any issue.","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":102,"context_line":"        with mock.patch.object(self.driver,"},{"line_number":103,"context_line":"                               \u0027delete_invalid_files\u0027) as mock_invalid:"},{"line_number":104,"context_line":"            with mock.patch.object(self.driver,"},{"line_number":105,"context_line":"                                   \u0027delete_stalled_files\u0027) as mock_stalled:"},{"line_number":106,"context_line":"                self.driver.clean(stall_time\u003d2)"},{"line_number":107,"context_line":"                self.assertEqual(1, mock_invalid.call_count)"},{"line_number":108,"context_line":"                self.assertEqual(1, mock_stalled.call_count)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ae84c6ff_1493755f","line":105,"updated":"2024-02-14 18:25:38.000000000","message":"Neither of these delete methods are ever tested AFAICT?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":102,"context_line":"        with mock.patch.object(self.driver,"},{"line_number":103,"context_line":"                               \u0027delete_invalid_files\u0027) as mock_invalid:"},{"line_number":104,"context_line":"            with mock.patch.object(self.driver,"},{"line_number":105,"context_line":"                                   \u0027delete_stalled_files\u0027) as mock_stalled:"},{"line_number":106,"context_line":"                self.driver.clean(stall_time\u003d2)"},{"line_number":107,"context_line":"                self.assertEqual(1, mock_invalid.call_count)"},{"line_number":108,"context_line":"                self.assertEqual(1, mock_stalled.call_count)"}],"source_content_type":"text/x-python","patch_set":15,"id":"62193ac3_ffdaf72f","line":105,"in_reply_to":"ae84c6ff_1493755f","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":105,"context_line":"                                   \u0027delete_stalled_files\u0027) as mock_stalled:"},{"line_number":106,"context_line":"                self.driver.clean(stall_time\u003d2)"},{"line_number":107,"context_line":"                self.assertEqual(1, mock_invalid.call_count)"},{"line_number":108,"context_line":"                self.assertEqual(1, mock_stalled.call_count)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"}],"source_content_type":"text/x-python","patch_set":15,"id":"62d54056_84795f1b","line":108,"updated":"2024-02-14 18:25:38.000000000","message":"Missing the case for `stall_time\u003dNone` to make sure it honors the config?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":105,"context_line":"                                   \u0027delete_stalled_files\u0027) as mock_stalled:"},{"line_number":106,"context_line":"                self.driver.clean(stall_time\u003d2)"},{"line_number":107,"context_line":"                self.assertEqual(1, mock_invalid.call_count)"},{"line_number":108,"context_line":"                self.assertEqual(1, mock_stalled.call_count)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"}],"source_content_type":"text/x-python","patch_set":15,"id":"2bb13554_1fb93815","line":108,"in_reply_to":"0c15196e_77952d48","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":105,"context_line":"                                   \u0027delete_stalled_files\u0027) as mock_stalled:"},{"line_number":106,"context_line":"                self.driver.clean(stall_time\u003d2)"},{"line_number":107,"context_line":"                self.assertEqual(1, mock_invalid.call_count)"},{"line_number":108,"context_line":"                self.assertEqual(1, mock_stalled.call_count)"},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"}],"source_content_type":"text/x-python","patch_set":15,"id":"0c15196e_77952d48","line":108,"in_reply_to":"62d54056_84795f1b","updated":"2024-02-14 19:33:01.000000000","message":"Right","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":112,"context_line":"        # exception as nothing is in db"},{"line_number":113,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":114,"context_line":"                          self.driver.get_least_recently_accessed)"},{"line_number":115,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"e7b6210b_32e64c5d","line":112,"updated":"2024-02-14 18:25:38.000000000","message":"...but again, none of the actual meat of the method is tested, where we get and return the size, default to zero if not cached, etc?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":112,"context_line":"        # exception as nothing is in db"},{"line_number":113,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":114,"context_line":"                          self.driver.get_least_recently_accessed)"},{"line_number":115,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"01ba4c1a_1c46bb1d","line":112,"in_reply_to":"03c44839_2fcb3b59","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"f68c8af4cae665c8894f7abe327ae9db6906d2f9","unresolved":true,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    def test_get_least_recently_accessed(self):"},{"line_number":111,"context_line":"        # Since we are mocking db calls, it will raise NotFound"},{"line_number":112,"context_line":"        # exception as nothing is in db"},{"line_number":113,"context_line":"        self.assertRaises(exception.NotFound,"},{"line_number":114,"context_line":"                          self.driver.get_least_recently_accessed)"},{"line_number":115,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"03c44839_2fcb3b59","line":112,"in_reply_to":"e7b6210b_32e64c5d","updated":"2024-02-14 19:33:01.000000000","message":"yep, I will explore about it. But same thing since unit tests are calling simpleapi should we really create data structure in memory?","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"2d8d00fb02c483f74a25536b8eb7754a6a47b1f9","unresolved":true,"context_lines":[{"line_number":119,"context_line":"        self.assertEqual(1, mock_open.call_count)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def test_get_queued_images(self):"},{"line_number":122,"context_line":"        # Since everything is mocked we will get empty list"},{"line_number":123,"context_line":"        queued_images \u003d self.driver.get_queued_images()"},{"line_number":124,"context_line":"        self.assertEqual(0, len(queued_images))"}],"source_content_type":"text/x-python","patch_set":15,"id":"9ce979df_08eb2237","line":122,"updated":"2024-02-14 18:25:38.000000000","message":"...","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"8e22d3b8fbe2093197df22946ab964ca3b85af77","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        self.assertEqual(1, mock_open.call_count)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def test_get_queued_images(self):"},{"line_number":122,"context_line":"        # Since everything is mocked we will get empty list"},{"line_number":123,"context_line":"        queued_images \u003d self.driver.get_queued_images()"},{"line_number":124,"context_line":"        self.assertEqual(0, len(queued_images))"}],"source_content_type":"text/x-python","patch_set":15,"id":"3bb2772f_65c87e6d","line":122,"in_reply_to":"9ce979df_08eb2237","updated":"2024-02-15 17:53:07.000000000","message":"Done","commit_id":"91e8fd90934985389f45a165ad3012bef28b4016"}]}
