OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Introduces the StorageFileAncestor as their ids are fake
Marcello Rochae5cbd5f57f2f
diff --git a/modules/storages/app/common/storages/adapters/adapter_types.rb b/modules/storages/app/common/storages/adapters/adapter_types.rbindex 2144c0191d1..419a281aeb3 100644--- a/modules/storages/app/common/storages/adapters/adapter_types.rb+++ b/modules/storages/app/common/storages/adapters/adapter_types.rb@@ -36,6 +36,7 @@ module Storages# We need to move the definition of ParentFolder to mean something like FolderLocation = AdapterTypes.Constructor(Peripherals::ParentFolder)StorageFileInstance = AdapterTypes.Instance(Results::StorageFile)+ FileAncestorInstance = AdapterTypes.Instance(Results::StorageFileAncestor)SemanticVersionType = AdapterTypes.Constructor(SemanticVersion, SemanticVersion.method(:parse))HTTPVerb = AdapterTypes::Nominal::Symbol.constrained(included_in: %i(post put))enddiff --git a/modules/storages/app/common/storages/adapters/providers/nextcloud/queries/files_query.rb b/modules/storages/app/common/storages/adapters/providers/nextcloud/queries/files_query.rbindex 43d503c4822..5ae2930b8a3 100644--- a/modules/storages/app/common/storages/adapters/providers/nextcloud/queries/files_query.rb+++ b/modules/storages/app/common/storages/adapters/providers/nextcloud/queries/files_query.rb@@ -106,14 +106,14 @@ module Storageslast = list.lastprefix = last.nil? || last.location[-1] != "/" ? "/" : ""location = "#{last&.location}#{prefix}#{item}"- list.append(forge_ancestor(location))+ list.append(forge_ancestor(CGI.unescape(location)))endend# The ancestors are simply derived objects from the parents location string. Until we have real information# from the nextcloud API about the path to the parent, we need to derive name, location and forge an ID.def forge_ancestor(location)- Results::StorageFile.new(id: Digest::SHA256.hexdigest(location), name: name(location), location:)+ Results::StorageFileAncestor.new(name: name(location), location:)enddef name(location)diff --git a/modules/storages/app/common/storages/adapters/providers/one_drive/queries/files_query.rb b/modules/storages/app/common/storages/adapters/providers/one_drive/queries/files_query.rbindex 05d9371f238..7df855c1056 100644--- a/modules/storages/app/common/storages/adapters/providers/one_drive/queries/files_query.rb+++ b/modules/storages/app/common/storages/adapters/providers/one_drive/queries/files_query.rb@@ -102,7 +102,8 @@ module Storages_, _, name = parent_reference[:path].gsub(/.*root:/, "").rpartition "/"if name.empty?- root(parent_reference[:id])+ Results::StorageFile.new(id: parent_reference[:id], name: "Root", location: "/",+ permissions: %i[readable writeable])else@transformer.parent_transform(id: parent_reference[:id], name:, location: parent_reference)end@@ -112,17 +113,13 @@ module Storagespath_elements = parent_reference[:path].gsub(/.+root:/, "").split("/")path_elements[0..-2].map do |component|- next root(Digest::SHA256.hexdigest("i_am_root")) if component.blank?+ next root if component.blank?- Results::StorageFile.new(- id: Digest::SHA256.hexdigest(component),- name: component,- location: UrlBuilder.path(component)- )+ Results::StorageFileAncestor.new(name: component, location: component)endend- def root(id) = Results::StorageFile.new(name: "Root", location: "/", id:, permissions: %i[readable writeable])+ def root = Results::StorageFileAncestor.new(name: "Root", location: "/")def children_url_for(folder)return UrlBuilder.url(base_uri, "/root/children") if folder.root?diff --git a/modules/storages/app/common/storages/adapters/providers/share_point/base.rb b/modules/storages/app/common/storages/adapters/providers/share_point/base.rbindex e21e9b4fb34..e35ed773154 100644--- a/modules/storages/app/common/storages/adapters/providers/share_point/base.rb+++ b/modules/storages/app/common/storages/adapters/providers/share_point/base.rb@@ -61,7 +61,7 @@ module StoragesURI(@storage.host)end- def drive_and_location(location)+ def split_identifier(location)drive_id, item_id = location.to_s.split(SharePointStorage::IDENTIFIER_SEPARATOR){ drive_id:, location: Peripherals::ParentFolder.new(item_id || "/") }enddiff --git a/modules/storages/app/common/storages/adapters/providers/share_point/queries/files_query.rb b/modules/storages/app/common/storages/adapters/providers/share_point/queries/files_query.rbindex 8e9aa1fe1e4..7b0ce13487b 100644--- a/modules/storages/app/common/storages/adapters/providers/share_point/queries/files_query.rb+++ b/modules/storages/app/common/storages/adapters/providers/share_point/queries/files_query.rb@@ -46,7 +46,7 @@ module Storagesif folder.root?Internal::ListsQuery.call(storage: @storage, http:)else- Internal::ChildrenQuery.call(storage: @storage, http:, **drive_and_location(folder))+ Internal::ChildrenQuery.call(storage: @storage, http:, **split_identifier(folder))endendenddiff --git a/modules/storages/app/common/storages/adapters/providers/share_point/queries/internal/children_query.rb b/modules/storages/app/common/storages/adapters/providers/share_point/queries/internal/children_query.rbindex 18a1d0a166f..7a1037cd950 100644--- a/modules/storages/app/common/storages/adapters/providers/share_point/queries/internal/children_query.rb+++ b/modules/storages/app/common/storages/adapters/providers/share_point/queries/internal/children_query.rb@@ -1,6 +1,31 @@# frozen_string_literal: true#-- copyright+# OpenProject is an open source project management software.+# Copyright (C) the OpenProject GmbH+#+# This program is free software; you can redistribute it and/or+# modify it under the terms of the GNU General Public License version 3.+#+# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:+# Copyright (C) 2006-2013 Jean-Philippe Lang+# Copyright (C) 2010-2013 the ChiliProject Team+#+# This program is free software; you can redistribute it and/or+# modify it under the terms of the GNU General Public License+# as published by the Free Software Foundation; either version 2+# of the License, or (at your option) any later version.+#+# This program is distributed in the hope that it will be useful,+# but WITHOUT ANY WARRANTY; without even the implied warranty of+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+# GNU General Public License for more details.+#+# You should have received a copy of the GNU General Public License+# along with this program; if not, write to the Free Software+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.+#+# See COPYRIGHT and LICENSE files for more details.#++module Storages@@ -22,7 +47,12 @@ module Storagesenddef call(http:, drive_id:, location:)- handle_response(http.get(request_uri(drive_id, location) + FIELDS)).bind { parse_response(it) }+ handle_response(http.get(request_uri(drive_id, location) + FIELDS)).bind do |json|+ files = json.fetch(:value, [])+ return empty_response(http, drive_id, location) if files.empty?++ parse_response(files)+ endendprivate@@ -31,16 +61,23 @@ module Storagesif location.root?UrlBuilder.url(base_uri, "/v1.0/drives/#{drive_id}/root/children")else- UrlBuilder.url(base_uri, "/v1.0/drives/#{drive_id}/items/#{location.path}/children")+ UrlBuilder.url(base_uri, "/v1.0/drives/#{drive_id}/root:#{UrlBuilder.path(location.path)}:/children")endend+ def folder_uri(drive_id, folder)+ base_url = UrlBuilder.url(base_uri, "/v1.0/drives/#{drive_id}/root")+ return base_url if folder.root?++ "#{base_url}:#{UrlBuilder.path(folder.path)}"+ end+def handle_response(response)error = Results::Error.new(source: self.class, payload: response)case responsein { status: 200..299 }- Success(response.json(symbolize_keys: true)[:value])+ Success(response.json(symbolize_keys: true))in { status: 400 }Failure(error.with(code: :request_error))in { status: 404 }@@ -61,40 +98,54 @@ module StoragesResults::StorageFileCollection.build(files:,parent: @transformer.parent_transform(entry),- ancestors: forge_ancestors(entry[:parentReference], entry[:webUrl])+ ancestors: build_ancestors(entry[:parentReference], entry[:webUrl]))end- def forge_ancestors(parent_reference, web_url)- # 1. This is a query on a drive, so we will always have the site root.- # 2. Then this can be a drive root or a folder query- # a. Drive Root we need to add it to the ancestors.+ def empty_response(http, drive_id, folder)+ handle_response(http.get(folder_uri(drive_id, folder) + FIELDS)).bind do |json|+ Results::StorageFileCollection.build(+ files: [],+ parent: @transformer.bare_transform(json),+ ancestors: build_empty_ancestors(json)+ )+ end+ end++ def build_ancestors(parent_reference, web_url)drive_name = CGI.unescape(web_url.gsub(/.*#{site_name}\//, "").split("/").first)list = parent_reference[:path].gsub(/.*root:/, "").split("/")[0..-2] # Last item is the parent+ forge_ancestors(list, drive_name)+ end++ def build_empty_ancestors(json)+ parent_reference = json[:parentReference]- list.each_with_object([site_root]) do |component, ancestors|+ drive_name = CGI.unescape(json[:webUrl].gsub(/.*#{site_name}\//, "").split("/").first)+ list = parent_reference[:path].gsub(/.*root:/, "").split("/")+ return [site_root, drive_root(drive_name)] if list.empty?++ forge_ancestors(list, drive_name)+ end++ def forge_ancestors(component_list, drive_name)+ component_list.each_with_object([site_root]) do |component, ancestors|if component.blank?- ancestors.unshift drive_root(parent_reference[:driveId], drive_name)+ ancestors.push(drive_root(drive_name))+ else+ ancestors.push(+ @transformer.build_ancestor(component, "#{CGI.unescape(ancestors.last.location)}/#{component}")+ )endendend- def drive_root(drive_id, name)- Results::StorageFile.new(- name:,- location: UrlBuilder.path("/#{name}"),- id: "#{drive_id}||",- permissions: %i[readable writeable]- )+ def drive_root(name)+ @transformer.build_ancestor(name, "/#{name}")enddef site_root- Results::StorageFile.new(- name: site_name,- location: "/",- id: Digest::SHA256.hexdigest("i_am_root"),- permissions: %i[readable writeable]- )+ @transformer.build_ancestor(site_name, "/")endendenddiff --git a/modules/storages/app/common/storages/adapters/providers/share_point/storage_file_transformer.rb b/modules/storages/app/common/storages/adapters/providers/share_point/storage_file_transformer.rbindex 4a011466215..c825183b925 100644--- a/modules/storages/app/common/storages/adapters/providers/share_point/storage_file_transformer.rb+++ b/modules/storages/app/common/storages/adapters/providers/share_point/storage_file_transformer.rb@@ -1,6 +1,31 @@# frozen_string_literal: true#-- copyright+# OpenProject is an open source project management software.+# Copyright (C) the OpenProject GmbH+#+# This program is free software; you can redistribute it and/or+# modify it under the terms of the GNU General Public License version 3.+#+# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:+# Copyright (C) 2006-2013 Jean-Philippe Lang+# Copyright (C) 2010-2013 the ChiliProject Team+#+# This program is free software; you can redistribute it and/or+# modify it under the terms of the GNU General Public License+# as published by the Free Software Foundation; either version 2+# of the License, or (at your option) any later version.+#+# This program is distributed in the hope that it will be useful,+# but WITHOUT ANY WARRANTY; without even the implied warranty of+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+# GNU General Public License for more details.+#+# You should have received a copy of the GNU General Public License+# along with this program; if not, write to the Free Software+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.+#+# See COPYRIGHT and LICENSE files for more details.#++module Storages@@ -38,6 +63,19 @@ module Storages)end+ def bare_transform(json)+ Results::StorageFile.new(+ name: json[:name],+ id: compose_id(json),+ location: extract_location(json),+ permissions: %i[readable writeable]+ )+ end++ def build_ancestor(name, location)+ Results::StorageFileAncestor.new(name:, location: CGI.unescape(location))+ end+privatedef mime_type(entry)diff --git a/modules/storages/app/common/storages/adapters/providers/share_point/commands/create_folder_command.rb b/modules/storages/app/common/storages/adapters/results/storage_file_ancestor.rbsimilarity index 54%rename from modules/storages/app/common/storages/adapters/providers/share_point/commands/create_folder_command.rbrename to modules/storages/app/common/storages/adapters/results/storage_file_ancestor.rbindex 67553364762..6fbf9f355fe 100644--- a/modules/storages/app/common/storages/adapters/providers/share_point/commands/create_folder_command.rb+++ b/modules/storages/app/common/storages/adapters/results/storage_file_ancestor.rb@@ -30,33 +30,13 @@module Storagesmodule Adapters- module Providers- module SharePoint- module Commands- class CreateFolderCommand < Base- # @param auth_strategy [Result(Input::Strategy)]- # @param input_data [Input::CreateFolder]- def call(auth_strategy:, input_data:)- Authentication[auth_strategy].call(storage: @storage) do |_http|- # Input data has: folder name, parent_location- # Parent Location here need to be eiter a Drive- # Or a pair of Drive + Parent Folder- Rails.logger.debug request_uri(**drive_and_location(input_data.parent_location))- end- end-- private-- def request_uri(drive_id:, location:)- last_fragment = if location.root?- ["/root/children"]- else- ["/items", parent_location.path, "/children"]- end-- UrlBuilder.url(base_uri, "/drives/", drive_id, *last_fragment)- end- end+ module Results+ class StorageFileAncestor < StorageFile+ def initialize(name:, location:)+ super(name:,+ location: UrlBuilder.path(location),+ id: Digest::SHA256.hexdigest(name),+ permissions: %i[readable writeable])endendenddiff --git a/modules/storages/app/common/storages/adapters/results/storage_file_collection_contract.rb b/modules/storages/app/common/storages/adapters/results/storage_file_collection_contract.rbindex 65158251015..3eed6200bfb 100644--- a/modules/storages/app/common/storages/adapters/results/storage_file_collection_contract.rb+++ b/modules/storages/app/common/storages/adapters/results/storage_file_collection_contract.rb@@ -35,7 +35,7 @@ module Storagesparams dorequired(:files).array(AdapterTypes::StorageFileInstance)required(:parent).filled(AdapterTypes::StorageFileInstance)- required(:ancestors).array(AdapterTypes::StorageFileInstance)+ required(:ancestors).array(AdapterTypes::FileAncestorInstance)endendenddiff --git a/modules/storages/app/models/storages/share_point_storage.rb b/modules/storages/app/models/storages/share_point_storage.rbindex a7b5550e262..3370cac228b 100644--- a/modules/storages/app/models/storages/share_point_storage.rb+++ b/modules/storages/app/models/storages/share_point_storage.rb@@ -62,6 +62,10 @@ module Storagesendend+ def configuration_checks+ { all: true }+ end+def uri@uri ||= URI("https://graph.microsoft.com").normalizeenddiff --git a/modules/storages/app/services/storages/storage_files_service.rb b/modules/storages/app/services/storages/storage_files_service.rbindex 9b8b7deb702..099bafdbcb7 100644--- a/modules/storages/app/services/storages/storage_files_service.rb+++ b/modules/storages/app/services/storages/storage_files_service.rb@@ -39,7 +39,6 @@ module Storagesauth_strategy = strategy(storage, user)info "Requesting all the files under folder #{folder} for #{storage.name}"- info "auth_strategy: #{auth_strategy}"input_data = Adapters::Input::Files.build(folder:).value_or { return add_validation_error(it) }diff --git a/modules/storages/spec/common/storages/adapters/providers/nextcloud/queries/files_query_spec.rb b/modules/storages/spec/common/storages/adapters/providers/nextcloud/queries/files_query_spec.rbindex 25944a959cb..fb839415e91 100644--- a/modules/storages/spec/common/storages/adapters/providers/nextcloud/queries/files_query_spec.rb+++ b/modules/storages/spec/common/storages/adapters/providers/nextcloud/queries/files_query_spec.rb@@ -55,7 +55,7 @@ module Storageslet(:files_result) do# FIXME: nextcloud files query currently does not correctly returns modifier and creation date.Results::StorageFileCollection.new(- [+ files: [Results::StorageFile.new(id: "555",name: "Folder",size: 232167,@@ -87,17 +87,17 @@ module Storageslocation: "/%c3%9cml%c3%a6%c3%bbts",permissions: %i[readable writeable])],- Results::StorageFile.new(id: "385",- name: "Root",- size: 252777,- mime_type: "application/x-op-directory",- created_at: nil,- last_modified_at: Time.zone.parse("2024-08-09T11:53:42Z"),- created_by_name: "Mara Jade",- last_modified_by_name: nil,- location: "/",- permissions: %i[readable writeable]),- []+ parent: Results::StorageFile.new(id: "385",+ name: "Root",+ size: 252777,+ mime_type: "application/x-op-directory",+ created_at: nil,+ last_modified_at: Time.zone.parse("2024-08-09T11:53:42Z"),+ created_by_name: "Mara Jade",+ last_modified_by_name: nil,+ location: "/",+ permissions: %i[readable writeable]),+ ancestors: [])end@@ -108,7 +108,7 @@ module Storageslet(:folder) { "/Folder/Nested Folder" }let(:files_result) doResults::StorageFileCollection.new(- [+ files: [Results::StorageFile.new(id: "603",name: "giphy.gif",size: 184726,@@ -140,23 +140,19 @@ module Storageslocation: "/Folder/Nested%20Folder/todo.txt",permissions: %i[readable writeable])],- Results::StorageFile.new(id: "601",- name: "Nested Folder",- size: 231045,- mime_type: "application/x-op-directory",- created_at: nil,- last_modified_at: Time.zone.parse("2024-08-09T11:53:42Z"),- created_by_name: "Mara Jade",- last_modified_by_name: nil,- location: "/Folder/Nested%20Folder",- permissions: %i[readable writeable]),- [- Results::StorageFile.new(id: "8a5edab282632443219e051e4ade2d1d5bbc671c781051bf1437897cbdfea0f1",- name: "Root",- location: "/"),- Results::StorageFile.new(id: "0da2f1cf70005eaeb08333802726c2928503d975e4a70cbdd1a28313cded20ae",- name: "Folder",- location: "/Folder")+ parent: Results::StorageFile.new(id: "601",+ name: "Nested Folder",+ size: 231045,+ mime_type: "application/x-op-directory",+ created_at: nil,+ last_modified_at: Time.zone.parse("2024-08-09T11:53:42Z"),+ created_by_name: "Mara Jade",+ last_modified_by_name: nil,+ location: "/Folder/Nested%20Folder",+ permissions: %i[readable writeable]),+ ancestors: [+ Results::StorageFileAncestor.new(name: "Root", location: "/"),+ Results::StorageFileAncestor.new(name: "Folder", location: "/Folder")])end@@ -168,24 +164,20 @@ module Storageslet(:folder) { "/Folder with spaces/very empty folder" }let(:files_result) doResults::StorageFileCollection.new(- [],- Results::StorageFile.new(id: "571",- name: "very empty folder",- size: 0,- mime_type: "application/x-op-directory",- created_at: nil,- last_modified_at: Time.zone.parse("2024-08-09T11:52:04Z"),- created_by_name: "Mara Jade",- last_modified_by_name: nil,- location: "/Folder%20with%20spaces/very%20empty%20folder",- permissions: %i[readable writeable]),- [- Results::StorageFile.new(id: "8a5edab282632443219e051e4ade2d1d5bbc671c781051bf1437897cbdfea0f1",- name: "Root",- location: "/"),- Results::StorageFile.new(id: "c8776f1f6dd36c023c6615d39f01a71d68dd1707b232115b7a4f58bc6da94e2e",- name: "Folder with spaces",- location: "/Folder%20with%20spaces")+ files: [],+ parent: Results::StorageFile.new(id: "571",+ name: "very empty folder",+ size: 0,+ mime_type: "application/x-op-directory",+ created_at: nil,+ last_modified_at: Time.zone.parse("2024-08-09T11:52:04Z"),+ created_by_name: "Mara Jade",+ last_modified_by_name: nil,+ location: "/Folder%20with%20spaces/very%20empty%20folder",+ permissions: %i[readable writeable]),+ ancestors: [+ Results::StorageFileAncestor.new(name: "Root", location: "/"),+ Results::StorageFileAncestor.new(name: "Folder with spaces", location: "/Folder with spaces")])end@@ -197,7 +189,7 @@ module Storageslet(:folder) { "/Ümlæûts" }let(:files_result) doResults::StorageFileCollection.new(- [+ files: [Results::StorageFile.new(id: "564",name: "Anrüchiges deutsches Dokument.docx",size: 19720,@@ -219,20 +211,18 @@ module Storageslocation: "/%c3%9cml%c3%a6%c3%bbts/data",permissions: %i[readable writeable])],- Results::StorageFile.new(id: "562",- name: "Ümlæûts",- size: 19720,- mime_type: "application/x-op-directory",- created_at: nil,- last_modified_at: Time.zone.parse("2024-08-09T11:51:48Z"),- created_by_name: "Mara Jade",- last_modified_by_name: nil,- location: "/%c3%9cml%c3%a6%c3%bbts",- permissions: %i[readable writeable]),- [- Results::StorageFile.new(id: "8a5edab282632443219e051e4ade2d1d5bbc671c781051bf1437897cbdfea0f1",- name: "Root",- location: "/")+ parent: Results::StorageFile.new(id: "562",+ name: "Ümlæûts",+ size: 19720,+ mime_type: "application/x-op-directory",+ created_at: nil,+ last_modified_at: Time.zone.parse("2024-08-09T11:51:48Z"),+ created_by_name: "Mara Jade",+ last_modified_by_name: nil,+ location: "/%c3%9cml%c3%a6%c3%bbts",+ permissions: %i[readable writeable]),+ ancestors: [+ Results::StorageFileAncestor.new(name: "Root", location: "/")])enddiff --git a/modules/storages/spec/common/storages/adapters/providers/one_drive/queries/files_query_spec.rb b/modules/storages/spec/common/storages/adapters/providers/one_drive/queries/files_query_spec.rbindex 846f6dfa29c..e069e0baa88 100644--- a/modules/storages/spec/common/storages/adapters/providers/one_drive/queries/files_query_spec.rb+++ b/modules/storages/spec/common/storages/adapters/providers/one_drive/queries/files_query_spec.rb@@ -122,13 +122,8 @@ module Storageslocation: "/Folder/Subfolder",permissions: %i[readable writeable]),ancestors: [- Results::StorageFile.new(id: "a1d45ff742d2175c095f0a7173f93fc3fc23664a953ceae6778fe15398818c2d",- name: "Root",- location: "/",- permissions: %i[readable writeable]),- Results::StorageFile.new(id: "74ccd43303847f2655300641a934959cdb11689ce171aa0f00faa92917fbd340",- name: "Folder",- location: "/Folder")+ Results::StorageFileAncestor.new(name: "Root", location: "/"),+ Results::StorageFileAncestor.new(name: "Folder", location: "/Folder")]).value!end@@ -146,13 +141,8 @@ module Storageslocation: "/Folder%20with%20spaces/very%20empty%20folder",permissions: %i[readable writeable]),ancestors: [- Results::StorageFile.new(id: "a1d45ff742d2175c095f0a7173f93fc3fc23664a953ceae6778fe15398818c2d",- name: "Root",- location: "/",- permissions: %i[readable writeable]),- Results::StorageFile.new(id: "58bde0c7931c8f95bb1bf525471146090630cb72827cb1e63dcaab3a9adce763",- name: "Folder with spaces",- location: "/Folder%20with%20spaces")+ Results::StorageFileAncestor.new(name: "Root", location: "/"),+ Results::StorageFileAncestor.new(name: "Folder with spaces", location: "/Folder with spaces")]).value!end@@ -183,13 +173,8 @@ module Storageslocation: "/Folder/%C3%9Cml%C3%A6%C3%BBts",permissions: %i[readable writeable]),ancestors: [- Results::StorageFile.new(id: "a1d45ff742d2175c095f0a7173f93fc3fc23664a953ceae6778fe15398818c2d",- name: "Root",- location: "/",- permissions: %i[readable writeable]),- Results::StorageFile.new(id: "74ccd43303847f2655300641a934959cdb11689ce171aa0f00faa92917fbd340",- name: "Folder",- location: "/Folder")+ Results::StorageFileAncestor.new(name: "Root", location: "/"),+ Results::StorageFileAncestor.new(name: "Folder", location: "/Folder")]).value!enddiff --git a/modules/storages/spec/common/storages/adapters/providers/share_point/queries/files_query_spec.rb b/modules/storages/spec/common/storages/adapters/providers/share_point/queries/files_query_spec.rbindex 26a8533f322..f991560f23a 100644--- a/modules/storages/spec/common/storages/adapters/providers/share_point/queries/files_query_spec.rb+++ b/modules/storages/spec/common/storages/adapters/providers/share_point/queries/files_query_spec.rb@@ -120,14 +120,14 @@ module Storagesendcontext "when requesting a drive", vcr: "share_point/files_query_drive" do- let(:folder) { "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||" }+ let(:folder) { "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||/" }let(:files_result) doResults::StorageFileCollection.new(files: [Results::StorageFile.new(id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S",name: "data",- size: 760,+ size: 12605,mime_type: "application/x-op-directory",created_at: Time.zone.parse("2025-04-07 12:02:26Z"),last_modified_at: Time.zone.parse("2025-04-07 12:02:26Z"),@@ -168,12 +168,7 @@ module Storagespermissions: %i[readable writeable]),ancestors: [- Results::StorageFile.new(- id: "a1d45ff742d2175c095f0a7173f93fc3fc23664a953ceae6778fe15398818c2d",- name: "OPTest",- location: "/",- permissions: %i[readable writeable]- )+ Results::StorageFileAncestor.new(name: "OPTest", location: "/")])end@@ -183,12 +178,24 @@ module Storagescontext "when requesting an folder", vcr: "share_point/files_query_folder" dolet(:folder) do- "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S"+ "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||data"endlet(:files_result) doResults::StorageFileCollection.new(files: [+ Results::StorageFile.new(+ id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W6DBDYX553L4REYNOMUI6XVMTO6",+ name: "subfolder",+ size: 11845,+ mime_type: "application/x-op-directory",+ location: "/Marcello%20VCR/data/subfolder",+ created_at: Time.zone.parse("2025-07-28 15:03:27.000000000 UTC +00:00"),+ last_modified_at: Time.zone.parse("2025-07-28 15:03:27.000000000 UTC +00:00"),+ created_by_name: "Eric Schubert",+ last_modified_by_name: "Eric Schubert",+ permissions: %i[readable writeable]+ ),Results::StorageFile.new(id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W26P5RNXU7V2JBKCVQQAGGTO46A",name: "edge one_drive_health_report_2025-07-22T16_03_25Z.txt",@@ -209,18 +216,69 @@ module Storagespermissions: %i[readable writeable]),ancestors: [+ Results::StorageFileAncestor.new(name: "OPTest", location: "/"),+ Results::StorageFileAncestor.new(name: "Marcello VCR", location: "/Marcello VCR")+ ]+ )+ end++ it_behaves_like "adapter files_query: successful files response"+ end++ context "when requesting a sub folder", vcr: "share_point/files_query_sub_folder" do+ let(:folder) do+ "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||data/subfolder"+ end+ let(:files_result) do+ Results::StorageFileCollection.new(+ files: [Results::StorageFile.new(- id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||",- name: "Marcello VCR",- location: "/Marcello%20VCR",- permissions: %i[readable writeable]- ),- Results::StorageFile.new(- id: "a1d45ff742d2175c095f0a7173f93fc3fc23664a953ceae6778fe15398818c2d",- name: "OPTest",- location: "/",+ id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W7MUYDYQAA3WVEYDJQNZVSKNPGD",+ name: "fw13-easy-effects.json",+ size: 11845,+ mime_type: "application/json",+ created_at: Time.zone.parse("2025-07-28 15:06:31.000000000 UTC +00:00"),+ last_modified_at: Time.zone.parse("2025-07-28 15:06:31.000000000 UTC +00:00"),+ created_by_name: "Eric Schubert",+ last_modified_by_name: "Eric Schubert",+ location: "/Marcello%20VCR/data/subfolder/fw13-easy-effects.json",permissions: %i[readable writeable])+ ],+ parent: Results::StorageFile.new(+ id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W6DBDYX553L4REYNOMUI6XVMTO6",+ name: "subfolder",+ location: "/Marcello%20VCR/data/subfolder",+ permissions: %i[readable writeable]+ ),+ ancestors: [+ Results::StorageFileAncestor.new(name: "OPTest", location: "/"),+ Results::StorageFileAncestor.new(name: "Marcello VCR", location: "/Marcello VCR"),+ Results::StorageFileAncestor.new(name: "data", location: "/Marcello VCR/data")+ ]+ )+ end++ it_behaves_like "adapter files_query: successful files response"+ end++ context "when requesting an empty folder", vcr: "share_point/files_query_empty_folder" do+ let(:folder) do+ "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||empty"+ end++ let(:files_result) do+ Results::StorageFileCollection.new(+ files: [],+ parent: Results::StorageFile.new(+ id: "b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW||01ANJ53W2MWJ6SKEZPHFGIAAB325KYYMPE",+ name: "empty",+ location: "/Marcello%20VCR/empty",+ permissions: %i[readable writeable]+ ),+ ancestors: [+ Results::StorageFileAncestor.new(name: "OPTest", location: "/"),+ Results::StorageFileAncestor.new(name: "Marcello VCR", location: "/Marcello VCR")])enddiff --git a/modules/storages/spec/factories/storage_factory.rb b/modules/storages/spec/factories/storage_factory.rbindex 31cfbfd45bd..a3edbca5036 100644--- a/modules/storages/spec/factories/storage_factory.rb+++ b/modules/storages/spec/factories/storage_factory.rb@@ -235,7 +235,6 @@ FactoryBot.define doendend-factory :share_point_dev_storage, parent: :storage, class: "::Storages::SharePointStorage" dotenant_id { ENV.fetch("SHARE_POINT_TEST_TENANT_ID", "e36f1dbc-fdae-427e-b61b-0d96ddfb81a4") }host { ENV.fetch("SHARE_POINT_TEST_HOST", "https://ymt6d.sharepoint.com/sites/OPTest") }diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive.ymlindex 512bd219535..6bf079c16db 100644--- a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive.yml+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive.yml@@ -37,13 +37,13 @@ http_interactions:P3p:- CP="DSP CUR OTPi IND OTRi ONL FIN"X-Ms-Request-Id:- - e5593e6d-10b8-42ee-8f15-ad820ac10500+ - 4ec08b8c-2cdf-48f6-bf34-fb9b9c080a00X-Ms-Ests-Server:- - 2.1.21415.7 - FRC ProdSlices+ - 2.1.21415.8 - WEULR1 ProdSlicesX-Ms-Srs:- 1.PContent-Security-Policy-Report-Only:- - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-OAM6X5AYz9ocAqYPChlwQw'+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-2ejqtDi2cHtAbTKF6HGh9g''unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.nethttps://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.comhttps://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net@@ -52,18 +52,18 @@ http_interactions:X-Xss-Protection:- '0'Set-Cookie:- - fpc=ArsDHMmFgLZOhbsMGLIx3LVZ-dCOAQAAAMkwGeAOAAAA; expires=Wed, 27-Aug-2025- 08:50:18 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ - fpc=AneMM3AJvplMqyQbGUyyx6lZ-dCOAQAAAKyAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:24 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;secure; samesite=none; httponlyDate:- - Mon, 28 Jul 2025 08:50:17 GMT+ - Tue, 29 Jul 2025 08:43:24 GMTContent-Length:- - '1927'+ - '1932'body:encoding: UTF-8string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'- recorded_at: Mon, 28 Jul 2025 08:50:18 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:24 GMT- request:method: geturi: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference@@ -94,26 +94,26 @@ http_interactions:Strict-Transport-Security:- max-age=31536000Request-Id:- - 60b70375-811f-401d-b92d-f9e890b2b95a+ - 51333f1f-b882-49a7-9c19-9feaa14a4087Client-Request-Id:- - 60b70375-811f-401d-b92d-f9e890b2b95a+ - 51333f1f-b882-49a7-9c19-9feaa14a4087X-Ms-Ags-Diagnostic:- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"002","RoleInstance":"FR3PEPF00000167"}}'+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF00000400"}}'Splogid:- - 6926b6a1-e079-0000-7566-ad884651cd18+ - 6a78b6a1-9046-0000-7534-c585c9f58701Date:- - Mon, 28 Jul 2025 08:50:18 GMT+ - Tue, 29 Jul 2025 08:43:24 GMTbody:encoding: UTF-8string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)","value":[{"@odata.etag":"\"{8DA9DCAF-43E4-419C-B52E-F1303A0D3372},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"id":"01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"name":"data","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W56Y2GOVW7725BZO354PWSELRRZ","name":"Marcello- VCR","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/data","fileSystemInfo":{"createdDateTime":"2025-04-07T12:02:26Z","lastModifiedDateTime":"2025-04-07T12:02:26Z"},"folder":{"childCount":1},"size":760},{"@odata.etag":"\"{257DB24C-2F13-4C39-8000-3BD7558C31E4},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ VCR","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/data","fileSystemInfo":{"createdDateTime":"2025-04-07T12:02:26Z","lastModifiedDateTime":"2025-04-07T12:02:26Z"},"folder":{"childCount":2},"size":12605},{"@odata.etag":"\"{257DB24C-2F13-4C39-8000-3BD7558C31E4},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"id":"01ANJ53W2MWJ6SKEZPHFGIAAB325KYYMPE","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"name":"empty","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W56Y2GOVW7725BZO354PWSELRRZ","name":"MarcelloVCR","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/empty","fileSystemInfo":{"createdDateTime":"2025-07-28T08:46:36Z","lastModifiedDateTime":"2025-07-28T08:46:36Z"},"folder":{"childCount":0},"size":0},{"@odata.etag":"\"{992C5835-AA54-4B71-B3AF-197B1F4578E8},2\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"id":"01ANJ53WZVLAWJSVFKOFF3HLYZPMPUK6HI","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"name":"simply_oidc.jpg","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W56Y2GOVW7725BZO354PWSELRRZ","name":"MarcelloVCR","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/simply_oidc.jpg","file":{"hashes":{"quickXorHash":"qzqT/ZJgJnvhu77aF+2RcdH62Sc="},"mimeType":"image/jpeg"},"fileSystemInfo":{"createdDateTime":"2025-04-07T12:02:42Z","lastModifiedDateTime":"2025-04-07T12:02:42Z"},"size":56483}]}'- recorded_at: Mon, 28 Jul 2025 08:50:18 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:25 GMTrecorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive_not_found.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive_not_found.ymlindex 852c2a71b7f..6248f860b41 100644--- a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive_not_found.yml+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_drive_not_found.yml@@ -37,13 +37,13 @@ http_interactions:P3p:- CP="DSP CUR OTPi IND OTRi ONL FIN"X-Ms-Request-Id:- - ff7ffdad-33a4-4cd2-8757-b3b10f337d00+ - c9505a9c-e667-4463-8ca7-b9a6a743b500X-Ms-Ests-Server:- - 2.1.21415.7 - FRC ProdSlices+ - 2.1.21415.7 - NEULR1 ProdSlicesX-Ms-Srs:- 1.PContent-Security-Policy-Report-Only:- - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-VdWfibjRfWm-a8iXEyCQBw'+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-cyQfIqqFLw_nwwr-5XGyNQ''unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.nethttps://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.comhttps://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net@@ -52,18 +52,18 @@ http_interactions:X-Xss-Protection:- '0'Set-Cookie:- - fpc=AmU5JebootlLq_w0JEw_Kv1Z-dCOAQAAAJlvGeAOAAAA; expires=Wed, 27-Aug-2025- 13:18:18 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ - fpc=AoG5mtQlIaJJtU0v5wR3ju5Z-dCOAQAAALKAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:31 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;secure; samesite=none; httponlyDate:- - Mon, 28 Jul 2025 13:18:18 GMT+ - Tue, 29 Jul 2025 08:43:30 GMTContent-Length:- - '1927'+ - '1935'body:encoding: UTF-8string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'- recorded_at: Mon, 28 Jul 2025 13:18:18 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:31 GMT- request:method: geturi: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvPoTaTO/root/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference@@ -95,17 +95,17 @@ http_interactions:Strict-Transport-Security:- max-age=31536000Request-Id:- - 04a7154e-197c-4ffc-b9ea-cfdc125ce2a4+ - 4bcaec8e-554a-4b1d-872a-eae53bc692b4Client-Request-Id:- - 04a7154e-197c-4ffc-b9ea-cfdc125ce2a4+ - 4bcaec8e-554a-4b1d-872a-eae53bc692b4X-Ms-Ags-Diagnostic:- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"008","RoleInstance":"FR3PEPF00000DD3"}}'+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF000001EE"}}'Splogid:- - bf35b6a1-603c-0000-7566-a3bc946874bc+ - 6b78b6a1-90ce-0000-7534-c35aeefe5ff5Date:- - Mon, 28 Jul 2025 13:18:18 GMT+ - Tue, 29 Jul 2025 08:43:30 GMTbody:encoding: UTF-8string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'- recorded_at: Mon, 28 Jul 2025 13:18:18 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:31 GMTrecorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_empty_folder.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_empty_folder.ymlnew file mode 100644index 00000000000..faf215b1332--- /dev/null+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_empty_folder.yml@@ -0,0 +1,156 @@+---+http_interactions:+- request:+ method: post+ uri: https://login.microsoftonline.com/e36f1dbc-fdae-427e-b61b-0d96ddfb81a4/oauth2/v2.0/token+ body:+ encoding: ASCII-8BIT+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=404e0567-19a1-4a64-b2d1-d3b0c99f2ed9&client_secret=QRB8Q%7Ei.1rID_.MC9FTfRGq-FTE5SgWYsoeLacWf+ headers:+ User-Agent:+ - httpx.rb/1.3.4+ Accept:+ - "*/*"+ Accept-Encoding:+ - gzip, deflate+ Content-Type:+ - application/x-www-form-urlencoded+ Content-Length:+ - '199'+ response:+ status:+ code: 200+ message: OK+ headers:+ Cache-Control:+ - no-store, no-cache+ Pragma:+ - no-cache+ Content-Type:+ - application/json; charset=utf-8+ Expires:+ - "-1"+ Strict-Transport-Security:+ - max-age=31536000; includeSubDomains+ X-Content-Type-Options:+ - nosniff+ P3p:+ - CP="DSP CUR OTPi IND OTRi ONL FIN"+ X-Ms-Request-Id:+ - c793650a-7cc1-42f4-b175-50636543f000+ X-Ms-Ests-Server:+ - 2.1.21415.7 - NEULR1 ProdSlices+ X-Ms-Srs:+ - 1.P+ Content-Security-Policy-Report-Only:+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-o3yU83OQvFJqBmxoqe4LjQ'+ 'unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.net+ https://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.com+ https://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net+ https://*.outlook.com https://*.office.com https://*.office365.com https://*.microsoft.com+ https://*.bing.com 'report-sample'; report-uri https://csp.microsoft.com/report/ESTS-UX-All+ X-Xss-Protection:+ - '0'+ Set-Cookie:+ - fpc=AlV2DsLJ-jBLn3oPM6k1qcJZ-dCOAQAAAK6AGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:26 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;+ secure; samesite=none; httponly+ Date:+ - Tue, 29 Jul 2025 08:43:25 GMT+ Content-Length:+ - '1935'+ body:+ encoding: UTF-8+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'+ recorded_at: Tue, 29 Jul 2025 08:43:26 GMT+- request:+ method: get+ uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/empty:/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference+ body:+ encoding: US-ASCII+ string: ''+ headers:+ User-Agent:+ - httpx.rb/1.3.4+ Accept:+ - "*/*"+ Accept-Encoding:+ - gzip, deflate+ Authorization:+ - Bearer <BEARER TOKEN>+ response:+ status:+ code: 200+ message: OK+ headers:+ Cache-Control:+ - no-store, no-cache+ Content-Type:+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;+ charset=utf-8+ Content-Encoding:+ - gzip+ Strict-Transport-Security:+ - max-age=31536000+ Request-Id:+ - 7d40873b-70fe-44e7-9227-c78c4cc5bc7a+ Client-Request-Id:+ - 7d40873b-70fe-44e7-9227-c78c4cc5bc7a+ X-Ms-Ags-Diagnostic:+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF000001EE"}}'+ Splogid:+ - 6a78b6a1-a0a9-0000-7534-c94564ab7f1c+ Date:+ - Tue, 29 Jul 2025 08:43:26 GMT+ body:+ encoding: UTF-8+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)","value":[]}'+ recorded_at: Tue, 29 Jul 2025 08:43:26 GMT+- request:+ method: get+ uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/empty?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference+ body:+ encoding: US-ASCII+ string: ''+ headers:+ User-Agent:+ - httpx.rb/1.3.4+ Accept:+ - "*/*"+ Accept-Encoding:+ - gzip, deflate+ Authorization:+ - Bearer <BEARER TOKEN>+ response:+ status:+ code: 200+ message: OK+ headers:+ Cache-Control:+ - no-cache+ Content-Type:+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;+ charset=utf-8+ Content-Encoding:+ - gzip+ Strict-Transport-Security:+ - max-age=31536000+ Request-Id:+ - 0fe7f69c-2896-4b5b-bd74-3549ed87ca96+ Client-Request-Id:+ - 0fe7f69c-2896-4b5b-bd74-3549ed87ca96+ X-Ms-Ags-Diagnostic:+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF000001EE"}}'+ Splogid:+ - 6a78b6a1-a0b5-0000-7534-cf59e5c2a115+ Date:+ - Tue, 29 Jul 2025 08:43:26 GMT+ body:+ encoding: UTF-8+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)/$entity","@odata.etag":"\"{257DB24C-2F13-4C39-8000-3BD7558C31E4},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"id":"01ANJ53W2MWJ6SKEZPHFGIAAB325KYYMPE","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"name":"empty","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W56Y2GOVW7725BZO354PWSELRRZ","name":"Marcello+ VCR","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/empty","fileSystemInfo":{"createdDateTime":"2025-07-28T08:46:36Z","lastModifiedDateTime":"2025-07-28T08:46:36Z"},"folder":{"childCount":0},"size":0}'+ recorded_at: Tue, 29 Jul 2025 08:43:27 GMT+recorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_file_not_found.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_file_not_found.ymlindex ad2b6dc0bca..dd326249093 100644--- a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_file_not_found.yml+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_file_not_found.yml@@ -37,13 +37,13 @@ http_interactions:P3p:- CP="DSP CUR OTPi IND OTRi ONL FIN"X-Ms-Request-Id:- - b2ce4ada-b8ef-46c7-8cf4-c9b83db6a500+ - e0ae382e-610b-4540-bf8e-b647a3c60100X-Ms-Ests-Server:- - 2.1.21415.7 - FRC ProdSlices+ - 2.1.21415.8 - SEC ProdSlicesX-Ms-Srs:- 1.PContent-Security-Policy-Report-Only:- - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-GFNiZX_zRLvj3WVU7ogLeQ'+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-8nuxlo41p8YUlOGBkvr0QA''unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.nethttps://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.comhttps://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net@@ -52,21 +52,21 @@ http_interactions:X-Xss-Protection:- '0'Set-Cookie:- - fpc=AkeDXHb9l0ZCgY-m-IGrBzhZ-dCOAQAAAG5tGeAOAAAA; expires=Wed, 27-Aug-2025- 13:09:03 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ - fpc=AgPm81TOrBRGsI8ii7mxCF5Z-dCOAQAAALCAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:28 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;secure; samesite=none; httponlyDate:- - Mon, 28 Jul 2025 13:09:02 GMT+ - Tue, 29 Jul 2025 08:43:27 GMTContent-Length:- - '1932'+ - '1927'body:encoding: UTF-8string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'- recorded_at: Mon, 28 Jul 2025 13:09:03 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:28 GMT- request:method: get- uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/items/POTATO/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference+ uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/POTATO:/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReferencebody:encoding: US-ASCIIstring: ''@@ -87,7 +87,8 @@ http_interactions:Cache-Control:- no-store, no-cacheContent-Type:- - application/json; charset=utf-8+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;+ charset=utf-8Content-Encoding:- gzipVary:@@ -95,17 +96,18 @@ http_interactions:Strict-Transport-Security:- max-age=31536000Request-Id:- - 8470c2a4-e9b1-480a-84c2-8abf72f91adf+ - 82303d0a-e686-47d0-a59d-4a1aa1aed489Client-Request-Id:- - 8470c2a4-e9b1-480a-84c2-8abf72f91adf+ - 82303d0a-e686-47d0-a59d-4a1aa1aed489X-Ms-Ags-Diagnostic:- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"008","RoleInstance":"FR3PEPF00000DD5"}}'+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF000001DD"}}'Splogid:- - 3735b6a1-60b6-0000-7566-a31011c0b744+ - 6b78b6a1-c0a3-0000-7534-c1315b3a5d62Date:- - Mon, 28 Jul 2025 13:09:03 GMT+ - Tue, 29 Jul 2025 08:43:30 GMTbody:encoding: UTF-8- string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'- recorded_at: Mon, 28 Jul 2025 13:09:03 GMT+ string: '{"error":{"code":"itemNotFound","message":"The resource could not be+ found."}}'+ recorded_at: Tue, 29 Jul 2025 08:43:30 GMTrecorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_folder.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_folder.ymlindex 921e59c1dc7..5424c31a3f6 100644--- a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_folder.yml+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_folder.yml@@ -37,13 +37,13 @@ http_interactions:P3p:- CP="DSP CUR OTPi IND OTRi ONL FIN"X-Ms-Request-Id:- - 6f542d99-7f2f-4466-952f-c400dbe06600+ - c12f7d67-2767-4164-958c-d4f8d09e0900X-Ms-Ests-Server:- - 2.1.21415.7 - WEULR1 ProdSlices+ - 2.1.21415.7 - FRC ProdSlicesX-Ms-Srs:- 1.PContent-Security-Policy-Report-Only:- - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-bFUy_yd93jzFa_VHsmlc9Q'+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-8T8VddmPKbxuBtV34nnbfg''unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.nethttps://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.comhttps://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net@@ -52,21 +52,21 @@ http_interactions:X-Xss-Protection:- '0'Set-Cookie:- - fpc=AkC9kJWBJE5Li_QcJSA9Au1Z-dCOAQAAAM4xGeAOAAAA; expires=Wed, 27-Aug-2025- 08:54:39 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ - fpc=AhLF2dL16qVCocHKKe9nTY5Z-dCOAQAAAKqAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:22 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;secure; samesite=none; httponlyDate:- - Mon, 28 Jul 2025 08:54:38 GMT+ - Tue, 29 Jul 2025 08:43:22 GMTContent-Length:- - '1937'+ - '1931'body:encoding: UTF-8string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'- recorded_at: Mon, 28 Jul 2025 08:54:39 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:22 GMT- request:method: get- uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/items/01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference+ uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/data:/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReferencebody:encoding: US-ASCIIstring: ''@@ -94,19 +94,21 @@ http_interactions:Strict-Transport-Security:- max-age=31536000Request-Id:- - 8a564d27-6add-4786-a344-17d748e93119+ - '09215f41-a3b7-4d85-a577-aeeb31269189'Client-Request-Id:- - 8a564d27-6add-4786-a344-17d748e93119+ - '09215f41-a3b7-4d85-a577-aeeb31269189'X-Ms-Ags-Diagnostic:- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"002","RoleInstance":"FR3PEPF00000350"}}'+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF00000CB7"}}'Splogid:- - a926b6a1-801c-0000-7566-a04034d05092+ - 6978b6a1-80ab-0000-7534-cc12511848cfDate:- - Mon, 28 Jul 2025 08:54:39 GMT+ - Tue, 29 Jul 2025 08:43:22 GMTbody:encoding: UTF-8- string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)","value":[{"@odata.etag":"\"{DB627F5E-F5D3-42D2-A156-10018D3773C0},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)","value":[{"@odata.etag":"\"{7EF108C3-6BF7-49E4-86B9-9447AF564DDE},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"id":"01ANJ53W6DBDYX553L4REYNOMUI6XVMTO6","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"name":"subfolder","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S","name":"data","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/data","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/data/subfolder","fileSystemInfo":{"createdDateTime":"2025-07-28T15:03:27Z","lastModifiedDateTime":"2025-07-28T15:03:27Z"},"folder":{"childCount":1},"size":11845},{"@odata.etag":"\"{DB627F5E-F5D3-42D2-A156-10018D3773C0},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"id":"01ANJ53W26P5RNXU7V2JBKCVQQAGGTO46A","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"name":"edge one_drive_health_report_2025-07-22T16_03_25Z.txt","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W5P3SUY3ZCDTRA3KLXRGA5A2M3S","name":"data","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/data","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/data/edge%20one_drive_health_report_2025-07-22T16_03_25Z.txt","file":{"hashes":{"quickXorHash":"dUZdSj55kRInUxY0kvoKq2xFSLk="},"mimeType":"text/plain"},"fileSystemInfo":{"createdDateTime":"2025-07-28T08:45:30Z","lastModifiedDateTime":"2025-07-28T08:45:30Z"},"size":760}]}'- recorded_at: Mon, 28 Jul 2025 08:54:39 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:22 GMTrecorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_root.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_root.ymlindex df80aa6b83d..160887dc630 100644--- a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_root.yml+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_root.yml@@ -37,13 +37,13 @@ http_interactions:P3p:- CP="DSP CUR OTPi IND OTRi ONL FIN"X-Ms-Request-Id:- - 94211292-5035-40b4-b9d5-2d3ec48a7e00+ - f3ad4781-1388-4b40-bb8b-2652a5c00100X-Ms-Ests-Server:- - 2.1.21415.7 - FRC ProdSlices+ - 2.1.21415.8 - SEC ProdSlicesX-Ms-Srs:- 1.PContent-Security-Policy-Report-Only:- - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-aKvJ90PEOpqPhZmq6TTwDg'+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-fH6wc7iK1SrI0ov5b3ye1Q''unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.nethttps://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.comhttps://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net@@ -52,18 +52,18 @@ http_interactions:X-Xss-Protection:- '0'Set-Cookie:- - fpc=AnUMhhQ9eI9EqAraBLDAbNRZ-dCOAQAAAMowGeAOAAAA; expires=Wed, 27-Aug-2025- 08:50:19 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ - fpc=AoAJXZgaqChJngrC4Q2zUZ5Z-dCOAQAAAKmAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:21 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;secure; samesite=none; httponlyDate:- - Mon, 28 Jul 2025 08:50:19 GMT+ - Tue, 29 Jul 2025 08:43:20 GMTContent-Length:- '1925'body:encoding: UTF-8string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'- recorded_at: Mon, 28 Jul 2025 08:50:19 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:21 GMT- request:method: geturi: https://graph.microsoft.com/v1.0/sites/ymt6d.sharepoint.com:/sites/OPTest:/lists?$expand=drive&$select=id,name,drive@@ -95,53 +95,53 @@ http_interactions:Strict-Transport-Security:- max-age=31536000Request-Id:- - d94669a4-95fb-4044-83e9-bb9677994772+ - fda8b138-8b1e-437d-bd5b-b3bb9b5deaa9Client-Request-Id:- - d94669a4-95fb-4044-83e9-bb9677994772+ - fda8b138-8b1e-437d-bd5b-b3bb9b5deaa9X-Ms-Ags-Diagnostic:- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"002","RoleInstance":"FR3PEPF00000DC1"}}'+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF000001DD"}}'Splogid:- - 6926b6a1-b0ac-0000-7534-cd98012d4302+ - 6978b6a1-5068-0000-7534-caba7f047892Odata-Version:- '4.0'Date:- - Mon, 28 Jul 2025 08:50:19 GMT+ - Tue, 29 Jul 2025 08:43:21 GMTbody:encoding: UTF-8string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(id,name,drive,drive())","value":[{"@odata.etag":"\"df897210-689b-48ba-a128-0a6b8662a40a,26\"","id":"df897210-689b-48ba-a128-0a6b8662a40a","name":"OpenProject","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''df897210-689b-48ba-a128-0a6b8662a40a'')/drive/$entity","drive":{"createdDateTime":"2024-02-02T13:53:33Z","description":"Enabledfor automatic management","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY8Qconfm2i6SKEoCmuGYqQK","lastModifiedDateTime":"2025-06-18T11:42:21Z","name":"OpenProject","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/OpenProject","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"7a76be3b-077e-41ef-a9d9-1d7f97080cb0,21\"","id":"7a76be3b-077e-41ef-a9d9-1d7f97080cb0","name":"Shared+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"7a76be3b-077e-41ef-a9d9-1d7f97080cb0,21\"","id":"7a76be3b-077e-41ef-a9d9-1d7f97080cb0","name":"SharedDocuments","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''7a76be3b-077e-41ef-a9d9-1d7f97080cb0'')/drive/$entity","drive":{"createdDateTime":"2023-12-10T00:27:16Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY87vnZ6fgfvQanZHX-XCAyw","lastModifiedDateTime":"2024-08-09T11:53:52Z","name":"Documents","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Shared%20Documents","driveType":"documentLibrary","createdBy":{"user":{"displayName":"SystemAccount"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"5cda990f-64f2-4035-9932-21b6d6409a25,4\"","id":"5cda990f-64f2-4035-9932-21b6d6409a25","name":"Selected+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"5cda990f-64f2-4035-9932-21b6d6409a25,4\"","id":"5cda990f-64f2-4035-9932-21b6d6409a25","name":"SelectedPermissions","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''5cda990f-64f2-4035-9932-21b6d6409a25'')/drive/$entity","drive":{"createdDateTime":"2024-08-12T13:14:43Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY8Pmdpc8mQ1QJkyIbbWQJol","lastModifiedDateTime":"2024-08-12T16:45:41Z","name":"SelectedPermissions","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Selected%20Permissions","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"ddbce65c-65fd-42a9-be30-253e244c3f36","displayName":"OPOwner"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"f5a7a0d8-fb24-48d8-9785-46ccb1e3317f,22\"","id":"f5a7a0d8-fb24-48d8-9785-46ccb1e3317f","name":"Chris+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"f5a7a0d8-fb24-48d8-9785-46ccb1e3317f,22\"","id":"f5a7a0d8-fb24-48d8-9785-46ccb1e3317f","name":"Chrisdocument library","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''f5a7a0d8-fb24-48d8-9785-46ccb1e3317f'')/drive/$entity","drive":{"createdDateTime":"2024-02-13T15:38:57Z","description":"Fortesting","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY_YoKf1JPvYSJeFRsyx4zF_","lastModifiedDateTime":"2024-05-21T12:58:12Z","name":"Chrisdocument library","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Chris%20document%20library","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5bbaa900-f913-41c9-9593-c3d03a14684b","displayName":"ChristopheBliard"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"87d67c02-fdaf-4504-8b39-920984585ad7,4\"","id":"87d67c02-fdaf-4504-8b39-920984585ad7","name":"Marcello+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"87d67c02-fdaf-4504-8b39-920984585ad7,4\"","id":"87d67c02-fdaf-4504-8b39-920984585ad7","name":"MarcelloAMPF","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''87d67c02-fdaf-4504-8b39-920984585ad7'')/drive/$entity","drive":{"createdDateTime":"2025-04-07T12:03:17Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY8CfNaHr_0ERYs5kgmEWFrX","lastModifiedDateTime":"2025-04-09T16:01:59Z","name":"Marcello(AMPF)","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20AMPF","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"587ba428-c078-4d0d-a857-952e781601e7,6\"","id":"587ba428-c078-4d0d-a857-952e781601e7","name":"Dominic","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''587ba428-c078-4d0d-a857-952e781601e7'')/drive/$entity","drive":{"createdDateTime":"2024-07-05T09:54:25Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY8opHtYeMANTahXlS54FgHn","lastModifiedDateTime":"2024-07-19T07:48:01Z","name":"Dominic","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Dominic","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"587ba428-c078-4d0d-a857-952e781601e7,6\"","id":"587ba428-c078-4d0d-a857-952e781601e7","name":"Dominic","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''587ba428-c078-4d0d-a857-952e781601e7'')/drive/$entity","drive":{"createdDateTime":"2024-07-05T09:54:25Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY8opHtYeMANTahXlS54FgHn","lastModifiedDateTime":"2024-07-19T07:48:01Z","name":"Dominic","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Dominic","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"6b0e0177-f280-47a8-bb4c-c29b29823f79,25\"","id":"6b0e0177-f280-47a8-bb4c-c29b29823f79","name":"Markus","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''6b0e0177-f280-47a8-bb4c-c29b29823f79'')/drive/$entity","drive":{"createdDateTime":"2024-05-13T14:53:56Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY93AQ5rgPKoR7tMwpspgj95","lastModifiedDateTime":"2025-05-19T13:28:22Z","name":"Markus","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Markus","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"6b0e0177-f280-47a8-bb4c-c29b29823f79,25\"","id":"6b0e0177-f280-47a8-bb4c-c29b29823f79","name":"Markus","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''6b0e0177-f280-47a8-bb4c-c29b29823f79'')/drive/$entity","drive":{"createdDateTime":"2024-05-13T14:53:56Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY93AQ5rgPKoR7tMwpspgj95","lastModifiedDateTime":"2025-05-19T13:28:22Z","name":"Markus","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Markus","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"ddbce65c-65fd-42a9-be30-253e244c3f36","displayName":"OPOwner"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"5ea9a363-3a24-4fab-b9ae-cef9a25a3156,20\"","id":"5ea9a363-3a24-4fab-b9ae-cef9a25a3156","name":"Marcello+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"5ea9a363-3a24-4fab-b9ae-cef9a25a3156,20\"","id":"5ea9a363-3a24-4fab-b9ae-cef9a25a3156","name":"MarcelloVCR","[email protected]":"https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.list)(''5ea9a363-3a24-4fab-b9ae-cef9a25a3156'')/drive/$entity","drive":{"createdDateTime":"2025-04-07T12:02:17Z","description":"","id":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","lastModifiedDateTime":"2025-07-28T08:46:36Z","name":"Marcello(VCR)","webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR","driveType":"documentLibrary","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"EricSchubert"}},"lastModifiedBy":{"user":{"email":"[email protected]","id":"a9023fd0-c421-4695-b83c-bb3ba67708d6","displayName":"OPMember"}},"owner":{"group":{"email":"[email protected]","id":"5dfb4269-d3e3-4c70-83f5-c4937ff6dcdb","displayName":"OP- Test Owners"}},"quota":{"deleted":0,"remaining":27487787097631,"state":"normal","total":27487790694400,"used":3596769}}},{"@odata.etag":"\"da53472d-ec9c-4fb1-b021-d89d3748c8a1,0\"","id":"da53472d-ec9c-4fb1-b021-d89d3748c8a1","name":"wte"},{"@odata.etag":"\"834449c8-dc24-44e0-a59a-e94f9128801c,8\"","id":"834449c8-dc24-44e0-a59a-e94f9128801c","name":"Access+ Test Owners"}},"quota":{"deleted":0,"remaining":27487787003556,"state":"normal","total":27487790694400,"used":3690844}}},{"@odata.etag":"\"da53472d-ec9c-4fb1-b021-d89d3748c8a1,0\"","id":"da53472d-ec9c-4fb1-b021-d89d3748c8a1","name":"wte"},{"@odata.etag":"\"834449c8-dc24-44e0-a59a-e94f9128801c,8\"","id":"834449c8-dc24-44e0-a59a-e94f9128801c","name":"AccessRequests"}]}'- recorded_at: Mon, 28 Jul 2025 08:50:19 GMT+ recorded_at: Tue, 29 Jul 2025 08:43:22 GMTrecorded_with: VCR 6.3.1diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_sub_folder.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_sub_folder.ymlnew file mode 100644index 00000000000..6cb9c871b96--- /dev/null+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/share_point/files_query_sub_folder.yml@@ -0,0 +1,112 @@+---+http_interactions:+- request:+ method: post+ uri: https://login.microsoftonline.com/e36f1dbc-fdae-427e-b61b-0d96ddfb81a4/oauth2/v2.0/token+ body:+ encoding: ASCII-8BIT+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=404e0567-19a1-4a64-b2d1-d3b0c99f2ed9&client_secret=QRB8Q%7Ei.1rID_.MC9FTfRGq-FTE5SgWYsoeLacWf+ headers:+ User-Agent:+ - httpx.rb/1.3.4+ Accept:+ - "*/*"+ Accept-Encoding:+ - gzip, deflate+ Content-Type:+ - application/x-www-form-urlencoded+ Content-Length:+ - '199'+ response:+ status:+ code: 200+ message: OK+ headers:+ Cache-Control:+ - no-store, no-cache+ Pragma:+ - no-cache+ Content-Type:+ - application/json; charset=utf-8+ Expires:+ - "-1"+ Strict-Transport-Security:+ - max-age=31536000; includeSubDomains+ X-Content-Type-Options:+ - nosniff+ P3p:+ - CP="DSP CUR OTPi IND OTRi ONL FIN"+ X-Ms-Request-Id:+ - 801e4994-fa65-4968-a322-34729db2c800+ X-Ms-Ests-Server:+ - 2.1.21415.7 - NEULR1 ProdSlices+ X-Ms-Srs:+ - 1.P+ Content-Security-Policy-Report-Only:+ - object-src 'none'; base-uri 'self'; script-src 'self' 'nonce-6D_qoNbKLX9JypzzRltl2A'+ 'unsafe-inline' 'unsafe-eval' https://*.msauth.net https://*.msftauth.net+ https://*.msftauthimages.net https://*.msauthimages.net https://*.msidentity.com+ https://*.microsoftonline-p.com https://*.microsoftazuread-sso.com https://*.azureedge.net+ https://*.outlook.com https://*.office.com https://*.office365.com https://*.microsoft.com+ https://*.bing.com 'report-sample'; report-uri https://csp.microsoft.com/report/ESTS-UX-All+ X-Xss-Protection:+ - '0'+ Set-Cookie:+ - fpc=AmHkd5Kz3HVGhrJsTCmkauRZ-dCOAQAAAKqAGuAOAAAA; expires=Thu, 28-Aug-2025+ 08:43:23 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;+ secure; samesite=none; httponly+ Date:+ - Tue, 29 Jul 2025 08:43:23 GMT+ Content-Length:+ - '1940'+ body:+ encoding: UTF-8+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'+ recorded_at: Tue, 29 Jul 2025 08:43:23 GMT+- request:+ method: get+ uri: https://graph.microsoft.com/v1.0/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/data/subfolder:/children?$select=id,name,size,webUrl,lastModifiedBy,createdBy,fileSystemInfo,file,folder,parentReference+ body:+ encoding: US-ASCII+ string: ''+ headers:+ User-Agent:+ - httpx.rb/1.3.4+ Accept:+ - "*/*"+ Accept-Encoding:+ - gzip, deflate+ Authorization:+ - Bearer <BEARER TOKEN>+ response:+ status:+ code: 200+ message: OK+ headers:+ Cache-Control:+ - no-store, no-cache+ Content-Type:+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;+ charset=utf-8+ Content-Encoding:+ - gzip+ Strict-Transport-Security:+ - max-age=31536000+ Request-Id:+ - f211d1e3-6605-48ca-a5c3-da65365cf64a+ Client-Request-Id:+ - f211d1e3-6605-48ca-a5c3-da65365cf64a+ X-Ms-Ags-Diagnostic:+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"001","RoleInstance":"FR2PEPF00000D30"}}'+ Splogid:+ - 6978b6a1-80e8-0000-7534-c9cde828a2ae+ Date:+ - Tue, 29 Jul 2025 08:43:23 GMT+ body:+ encoding: UTF-8+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)","value":[{"@odata.etag":"\"{8807A6EC-1B00-49B5-81A6-0DCD64A6BCC3},1\"","createdBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"id":"01ANJ53W7MUYDYQAA3WVEYDJQNZVSKNPGD","lastModifiedBy":{"user":{"email":"[email protected]","id":"5b5a7dc4-4539-41ba-9fa9-100f0a26acb7","displayName":"Eric+ Schubert"}},"name":"fw13-easy-effects.json","parentReference":{"driveType":"documentLibrary","driveId":"b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW","id":"01ANJ53W6DBDYX553L4REYNOMUI6XVMTO6","name":"subfolder","path":"/drives/b!FeOZEMfQx0eGQKqVBLcP__BG8mq-4-9FuRqOyk3MXY9jo6leJDqrT7muzvmiWjFW/root:/data/subfolder","siteId":"1099e315-d0c7-47c7-8640-aa9504b70fff"},"webUrl":"https://ymt6d.sharepoint.com/sites/OPTest/Marcello%20VCR/data/subfolder/fw13-easy-effects.json","file":{"hashes":{"quickXorHash":"eA5sv9rqGJI/2/SvuRJJKwFOOw8="},"mimeType":"application/json"},"fileSystemInfo":{"createdDateTime":"2025-07-28T15:06:31Z","lastModifiedDateTime":"2025-07-28T15:06:31Z"},"size":11845}]}'+ recorded_at: Tue, 29 Jul 2025 08:43:23 GMT+recorded_with: VCR 6.3.1