)]}'
{"devstack/lib/ovn_agent":[{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"c216ffc0076cf311121cc7578a9715a8a2d0911d","unresolved":false,"context_lines":[{"line_number":165,"context_line":"            popd"},{"line_number":166,"context_line":"        fi"},{"line_number":167,"context_line":"    fi"},{"line_number":168,"context_line":"    return $is_new_ovn"},{"line_number":169,"context_line":"}"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"# NOTE(rtheis): Function copied from DevStack _neutron_ovs_base_setup_bridge"}],"source_content_type":"application/x-shellscript","patch_set":2,"id":"ff570b3c_67d2272a","line":168,"updated":"2020-05-20 09:55:02.000000000","message":"To avoid cloning OVN twice, what if we tested OVS instead ? We need to clone/compile OVS regardless of the version of OVN being used so we could check if the commit that deletes OVN is present in the OVS checkout, if so, it means that we need to clone OVN from the new repo.","commit_id":"794e6e01876f12ae8c7f4a9ba122507db9c55143"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"f7d5dd786a194a1aca335f595a443396c5a2428c","unresolved":false,"context_lines":[{"line_number":165,"context_line":"            popd"},{"line_number":166,"context_line":"        fi"},{"line_number":167,"context_line":"    fi"},{"line_number":168,"context_line":"    return $is_new_ovn"},{"line_number":169,"context_line":"}"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"# NOTE(rtheis): Function copied from DevStack _neutron_ovs_base_setup_bridge"}],"source_content_type":"application/x-shellscript","patch_set":2,"id":"ff570b3c_a7f27f98","line":168,"in_reply_to":"ff570b3c_67d2272a","updated":"2020-05-20 10:03:55.000000000","message":"I think this is a great idea! Thanks!","commit_id":"794e6e01876f12ae8c7f4a9ba122507db9c55143"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2d813b0d94ff9ef421a6f7a03b5e90ae9900ff1e","unresolved":false,"context_lines":[{"line_number":154,"context_line":"function use_new_ovn_repository {"},{"line_number":155,"context_line":"    if [ \"x$is_new_ovn\" \u003d\u003d \"x\" ]; then"},{"line_number":156,"context_line":"        local ovs_repo_dir\u003d$DEST/$OVS_REPO_NAME"},{"line_number":157,"context_line":"        if [ ! -d $ovs_repo_dir ] \u0026\u0026 clone_repository $OVS_REPO $ovs_repo_dir $OVS_BRANCH 2\u003e\u00261 | grep -q \"did not match any file\"; then"},{"line_number":158,"context_line":"            # The branch doesn\u0027t exist"},{"line_number":159,"context_line":"            is_new_ovn\u003d1"},{"line_number":160,"context_line":"        else"}],"source_content_type":"application/x-shellscript","patch_set":3,"id":"ff570b3c_473c432e","line":157,"range":{"start_line":157,"start_character":97,"end_line":157,"end_character":101},"updated":"2020-05-20 10:04:53.000000000","message":"now I\u0027m thinking this may not be working on non-english systems","commit_id":"e8b37995bd90378abfc4ce12e304975cc8f63b08"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"3b411ae14dd0c7a01a9d61f63f1f570d40420515","unresolved":false,"context_lines":[{"line_number":154,"context_line":"function use_new_ovn_repository {"},{"line_number":155,"context_line":"    if [ \"x$is_new_ovn\" \u003d\u003d \"x\" ]; then"},{"line_number":156,"context_line":"        local ovs_repo_dir\u003d$DEST/$OVS_REPO_NAME"},{"line_number":157,"context_line":"        if [ ! -d $ovs_repo_dir ] \u0026\u0026 clone_repository $OVS_REPO $ovs_repo_dir $OVS_BRANCH 2\u003e\u00261 | grep -q \"did not match any file\"; then"},{"line_number":158,"context_line":"            # The branch doesn\u0027t exist"},{"line_number":159,"context_line":"            is_new_ovn\u003d1"},{"line_number":160,"context_line":"        else"}],"source_content_type":"application/x-shellscript","patch_set":3,"id":"ff570b3c_871bfbc7","line":157,"range":{"start_line":157,"start_character":97,"end_line":157,"end_character":101},"in_reply_to":"ff570b3c_473c432e","updated":"2020-05-20 10:06:05.000000000","message":"it\u0027s not even needed with OVS_BRANCH","commit_id":"e8b37995bd90378abfc4ce12e304975cc8f63b08"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"4c19b70f81fc96c4cb8624583df3a733a901bfed","unresolved":false,"context_lines":[{"line_number":31,"context_line":"OVN_REPO_NAME\u003d$(basename ${OVN_REPO} | cut -f1 -d\u0027.\u0027)"},{"line_number":32,"context_line":"OVN_REPO_NAME\u003d${OVN_REPO_NAME:-ovn}"},{"line_number":33,"context_line":"OVN_BRANCH\u003d${OVN_BRANCH:-master}"},{"line_number":34,"context_line":"OVN_SPLIT_HASH\u003d05bf1dbb98b0635a51f75e268ef8aed27601401d"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"# Set variables for building OVS from source"},{"line_number":37,"context_line":"OVS_REPO\u003d${OVS_REPO:-https://github.com/openvswitch/ovs.git}"}],"source_content_type":"application/x-shellscript","patch_set":4,"id":"ff570b3c_7bb92213","line":34,"updated":"2020-05-20 13:06:44.000000000","message":"nit: Add a comment to explain what is this hash about :D","commit_id":"aa7eec72d382e0d9ea8106165eb92c183a446d54"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"1fe25e5935f060772637e44743aa293c308dfaed","unresolved":false,"context_lines":[{"line_number":31,"context_line":"OVN_REPO_NAME\u003d$(basename ${OVN_REPO} | cut -f1 -d\u0027.\u0027)"},{"line_number":32,"context_line":"OVN_REPO_NAME\u003d${OVN_REPO_NAME:-ovn}"},{"line_number":33,"context_line":"OVN_BRANCH\u003d${OVN_BRANCH:-master}"},{"line_number":34,"context_line":"OVN_SPLIT_HASH\u003d05bf1dbb98b0635a51f75e268ef8aed27601401d"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"# Set variables for building OVS from source"},{"line_number":37,"context_line":"OVS_REPO\u003d${OVS_REPO:-https://github.com/openvswitch/ovs.git}"}],"source_content_type":"application/x-shellscript","patch_set":4,"id":"ff570b3c_36f7bf8d","line":34,"in_reply_to":"ff570b3c_7bb92213","updated":"2020-05-20 14:05:53.000000000","message":"Done","commit_id":"aa7eec72d382e0d9ea8106165eb92c183a446d54"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"0bbcfb52da6cb0fbb9df95ef57d4970bbbfee74b","unresolved":false,"context_lines":[{"line_number":155,"context_line":"}"},{"line_number":156,"context_line":""},{"line_number":157,"context_line":"function use_new_ovn_repository {"},{"line_number":158,"context_line":"    if [ \"x$is_new_ovn\" \u003d\u003d \"x\" ]; then"},{"line_number":159,"context_line":"        local ovs_repo_dir\u003d$DEST/$OVS_REPO_NAME"},{"line_number":160,"context_line":"        if [ ! -d $ovs_repo_dir ]; then"},{"line_number":161,"context_line":"            clone_repository $OVS_REPO $ovs_repo_dir $OVS_BRANCH"}],"source_content_type":"application/x-shellscript","patch_set":6,"id":"ff570b3c_dc2f41a5","line":158,"range":{"start_line":158,"start_character":4,"end_line":158,"end_character":38},"updated":"2020-05-25 08:58:51.000000000","message":"nit: if \"is_new_ovn\" is set to \"\", this will pass too. To check if a variable is set (to blank string or anything else) [1]\n  if [ -z ${is_new_ovn+x} ];...\n\n[1]https://stackoverflow.com/questions/3601515/how-to-check-if-a-variable-is-set-in-bash","commit_id":"dcd2e79c001d2be4e869c1bb0fb72c51158c81e7"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"0bbcfb52da6cb0fbb9df95ef57d4970bbbfee74b","unresolved":false,"context_lines":[{"line_number":163,"context_line":"        # Check the split commit exists in the current branch"},{"line_number":164,"context_line":"        pushd $ovs_repo_dir"},{"line_number":165,"context_line":"        git log $OVS_BRANCH --pretty\u003dformat:\"%H\" | grep -q $OVN_SPLIT_HASH"},{"line_number":166,"context_line":"        is_new_ovn\u003d$?"},{"line_number":167,"context_line":"        popd"},{"line_number":168,"context_line":"    fi"},{"line_number":169,"context_line":"    return $is_new_ovn"}],"source_content_type":"application/x-shellscript","patch_set":6,"id":"ff570b3c_bf635fb1","line":166,"updated":"2020-05-25 08:58:51.000000000","message":"If L165 is correct, \"is_new_ovn\" will be 0. Is that correct?","commit_id":"dcd2e79c001d2be4e869c1bb0fb72c51158c81e7"},{"author":{"_account_id":11975,"name":"Slawek Kaplonski","email":"skaplons@redhat.com","username":"slaweq"},"change_message_id":"45f587d363f54e0a88c2fee8fc33f90f754981c1","unresolved":false,"context_lines":[{"line_number":163,"context_line":"        # Check the split commit exists in the current branch"},{"line_number":164,"context_line":"        pushd $ovs_repo_dir"},{"line_number":165,"context_line":"        git log $OVS_BRANCH --pretty\u003dformat:\"%H\" | grep -q $OVN_SPLIT_HASH"},{"line_number":166,"context_line":"        is_new_ovn\u003d$?"},{"line_number":167,"context_line":"        popd"},{"line_number":168,"context_line":"    fi"},{"line_number":169,"context_line":"    return $is_new_ovn"}],"source_content_type":"application/x-shellscript","patch_set":6,"id":"ff570b3c_ab5f8c0c","line":166,"in_reply_to":"ff570b3c_bf635fb1","updated":"2020-05-26 14:11:03.000000000","message":"according to how it worked in previous version it seems for me that this is correct and it should return 0 if new ovn repo should be used.","commit_id":"dcd2e79c001d2be4e869c1bb0fb72c51158c81e7"}]}
