[arvados] updated: 2.5.0-268-geffb6e13d

git repository hosting git at public.arvados.org
Fri Mar 10 18:24:47 UTC 2023


Summary of changes:
 .../api/app/controllers/arvados/v1/collections_controller.rb   | 10 +++++-----
 services/api/app/models/container.rb                           |  2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

       via  effb6e13d6a4d024243138cacfeb582efba5e24a (commit)
      from  ad18aa8b7f032e5acf356bd97e1d62684c24e891 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit effb6e13d6a4d024243138cacfeb582efba5e24a
Author: Peter Amstutz <peter.amstutz at curii.com>
Date:   Fri Mar 10 13:24:25 2023 -0500

    20223: Need to use each_record instead of each
    
    Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>

diff --git a/services/api/app/controllers/arvados/v1/collections_controller.rb b/services/api/app/controllers/arvados/v1/collections_controller.rb
index 1d6800636..225c05462 100644
--- a/services/api/app/controllers/arvados/v1/collections_controller.rb
+++ b/services/api/app/controllers/arvados/v1/collections_controller.rb
@@ -183,11 +183,11 @@ class Arvados::V1::CollectionsController < ApplicationController
           end
         end
 
-        Container.readable_by(*@read_users).where(output: loc.to_s).in_batches(of: 15).each do |c|
+        Container.readable_by(*@read_users).where(output: loc.to_s).in_batches(of: 15).each_record do |c|
           search_edges(visited, c.uuid, :search_up)
         end
 
-        Container.readable_by(*@read_users).where(log: loc.to_s).in_batches(of: 15).each do |c|
+        Container.readable_by(*@read_users).where(log: loc.to_s).in_batches(of: 15).each_record do |c|
           search_edges(visited, c.uuid, :search_up)
         end
       elsif direction == :search_down
@@ -207,7 +207,7 @@ class Arvados::V1::CollectionsController < ApplicationController
           end
         end
 
-        Container.readable_by(*@read_users).where([Container.full_text_trgm + " like ?", "%#{loc.to_s}%"]).in_batches(of: 15).each do |c|
+        Container.readable_by(*@read_users).where([Container.full_text_trgm + " like ?", "%#{loc.to_s}%"]).in_batches(of: 15).each_record do |c|
           if c.output != loc.to_s && c.log != loc.to_s
             search_edges(visited, c.uuid, :search_down)
           end
@@ -276,11 +276,11 @@ class Arvados::V1::CollectionsController < ApplicationController
               end
             end
 
-            ContainerRequest.readable_by(*@read_users).where(output_uuid: uuid).in_batches(of: 15).each do |cr|
+            ContainerRequest.readable_by(*@read_users).where(output_uuid: uuid).in_batches(of: 15).each_record do |cr|
               search_edges(visited, cr.uuid, :search_up)
             end
 
-            ContainerRequest.readable_by(*@read_users).where(log_uuid: uuid).in_batches(of: 15).each do |cr|
+            ContainerRequest.readable_by(*@read_users).where(log_uuid: uuid).in_batches(of: 15).each_record do |cr|
               search_edges(visited, cr.uuid, :search_up)
             end
           elsif direction == :search_down
diff --git a/services/api/app/models/container.rb b/services/api/app/models/container.rb
index 146cc16ec..0eaf640b6 100644
--- a/services/api/app/models/container.rb
+++ b/services/api/app/models/container.rb
@@ -831,7 +831,7 @@ class Container < ArvadosModel
           ContainerRequest.
             where(requesting_container_uuid: uuid,
                   state: ContainerRequest::Committed).
-            in_batches(of: 15).each do |cr|
+            in_batches(of: 15).each_record do |cr|
             leave_modified_by_user_alone do
               cr.set_priority_zero
               container_state = Container.where(uuid: cr.container_uuid).pluck(:state).first

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list