aws-sdk-s3 1.233.1 → 1.235.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2a94f968574a4140131a94ed10f6e238db29a2cb3ceac5eaab1bccdda34efa4f
4
- data.tar.gz: 63bbf8c2512e03438f6e22c634bb9070cc52e0b06096d7a6945dc55100303631
3
+ metadata.gz: 222ecc56a1d529e21a3539d72a6065fa8b03a30f2a76cefe2b656464c003b094
4
+ data.tar.gz: bdb9c728982988008448f8fac5b571277b16896fc36521c678a8ddd48fe89053
5
5
  SHA512:
6
- metadata.gz: 46c2a374e3f4bbd446d32b3403f08e2b648f37dc5f1cfb1d1c2224a211b43e6450ebdaa9cc3bbf9c6fa3e2a5b0884671127baf13163391fb11647a339f34ae5f
7
- data.tar.gz: 564b1d9d422faa9180efc8e86f31803c517335608ff98eb05fa328094cc5de1a23cd22f13afeb09aa3e84aeb5f0e0f3b8a2e9a2f69437403efcbc3aa7bb2ebb2
6
+ metadata.gz: 7cfb285fdbcbb3fc493209736b5432a034b45fa4b0ce2f0ba14a16f18815e7519a04ade3c04072eb7218781974f323acf0ea5ee4e4a0df298f4e3c61a514240b
7
+ data.tar.gz: f385fab3dd0f2eb170755d3d8696db98d054dfbd346d56c3a940ee0fd366a802cbbd30a78dca6e9b9b179d13937831d8eb5fb645124a57738c067fbcbc3dcd76
data/CHANGELOG.md CHANGED
@@ -1,6 +1,27 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.235.0 (2026-10-20)
5
+ ------------------
6
+
7
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
8
+
9
+ * Feature - Add RBS signatures for `TransferManager`, `MultipartUploadError`, `Errors::NotFound` and `Errors::SlowDown`.
10
+
11
+ * Issue - Improve object key validation in `TransferManager#download_directory` on Windows.
12
+
13
+ 1.234.0 (2026-10-19)
14
+ ------------------
15
+
16
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
17
+
18
+ 1.233.2 (2026-10-06)
19
+ ------------------
20
+
21
+ * Issue - Fix `download_file` on `TransferManager` and `Aws::S3::Object` leaving a corrupt file at the destination when a part raises a non-`StandardError`, and leaving a temp file behind when a caller-provided executor rejects a part.
22
+
23
+ * Issue - Prevent `upload_directory` and `download_directory` on `TransferManager` from hanging when listing files or objects raises a non-`StandardError`, such as from a `:filter_callback`.
24
+
4
25
  1.233.1 (2026-10-01)
5
26
  ------------------
6
27
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.233.1
1
+ 1.235.0
@@ -255,13 +255,20 @@ module Aws::S3
255
255
  # the required types.
256
256
  #
257
257
  # @option options [Boolean] :correct_clock_skew (true)
258
- # Used only in `standard` and `adaptive` retry modes. Specifies whether to apply
259
- # a clock skew correction and retry requests with skewed client clocks.
258
+ # Used only in `standard` and `adaptive` retry modes. Specifies whether
259
+ # to apply a clock skew correction and retry requests with skewed client
260
+ # clocks. Takes effect only when `disable_clock_skew_correction` is not set.
260
261
  #
261
262
  # @option options [String] :defaults_mode ("legacy")
262
263
  # See {Aws::DefaultsModeConfiguration} for a list of the
263
264
  # accepted modes and the configuration defaults that are included.
264
265
  #
266
+ # @option options [Boolean] :disable_clock_skew_correction
267
+ # Used only in `standard` and `adaptive` retry modes. When `true`, the
268
+ # SDK does not apply a clock skew correction, does not update its stored
269
+ # skew from responses, and does not retry clock skew errors. Clock skew
270
+ # correction is enabled by default.
271
+ #
265
272
  # @option options [Boolean] :disable_host_prefix_injection (false)
266
273
  # When `true`, the SDK will not prepend the modeled host prefix to the endpoint.
267
274
  #
@@ -24209,7 +24216,7 @@ module Aws::S3
24209
24216
  tracer: tracer
24210
24217
  )
24211
24218
  context[:gem_name] = 'aws-sdk-s3'
24212
- context[:gem_version] = '1.233.1'
24219
+ context[:gem_version] = '1.235.0'
24213
24220
  Seahorse::Client::Request.new(handlers, context)
24214
24221
  end
24215
24222
 
@@ -148,8 +148,9 @@ module Aws
148
148
  stream_objects
149
149
  @object_queue << DONE_MARKER
150
150
  rescue ClosedQueueError
151
- # abort requested
152
- rescue StandardError => e
151
+ nil # abort requested
152
+ # Any error, or the consumer waits on the queue forever
153
+ rescue Exception => e # rubocop:disable Lint/RescueException
153
154
  close
154
155
  raise e
155
156
  end
@@ -208,7 +209,12 @@ module Aws
208
209
  end
209
210
 
210
211
  def validate_key(key)
211
- segments = key.split('/')
212
+ validation_key = key
213
+ if File::ALT_SEPARATOR
214
+ validation_key = key.gsub(File::ALT_SEPARATOR, File::SEPARATOR)
215
+ end
216
+
217
+ segments = validation_key.split(File::SEPARATOR)
212
218
  return unless segments.any? { |s| %w[. ..].include?(s) }
213
219
 
214
220
  DirectoryDownloadError.new("invalid key '#{key}': contains '.' or '..' path segments")
@@ -156,6 +156,10 @@ module Aws
156
156
  # encountered a traversal error, we must abort immediately
157
157
  close
158
158
  raise DirectoryUploadError, "Directory traversal failed for '#{@source_dir}': #{e.message}"
159
+ # Any other error, or the consumer waits on the queue forever
160
+ rescue Exception => e # rubocop:disable Lint/RescueException
161
+ close
162
+ raise e
159
163
  end
160
164
 
161
165
  while (file = @file_queue.shift) && file != DONE_MARKER
@@ -60,7 +60,7 @@ module Aws
60
60
  end
61
61
 
62
62
  def download_with_executor(part_list, total_size, opts)
63
- download_attempts = 0
63
+ queued_parts = 0
64
64
  completion_queue = Queue.new
65
65
  abort_download = false
66
66
  error = nil
@@ -69,24 +69,31 @@ module Aws
69
69
  while (part = part_list.shift)
70
70
  break if abort_download
71
71
 
72
- download_attempts += 1
73
- @executor.post(part) do |p|
74
- update_progress(progress, p)
75
- resp = @client.get_object(p.params)
76
- range = extract_range(resp.content_range)
77
- validate_range(range, p.params[:range]) if p.params[:range]
78
- write(resp.body, range, opts)
79
-
80
- execute_checksum_callback(resp, opts)
72
+ begin
73
+ @executor.post(part) do |p|
74
+ update_progress(progress, p)
75
+ resp = @client.get_object(p.params)
76
+ range = extract_range(resp.content_range)
77
+ validate_range(range, p.params[:range]) if p.params[:range]
78
+ write(resp.body, range, opts)
79
+
80
+ execute_checksum_callback(resp, opts)
81
+ # Any error, or a corrupt file replaces the destination
82
+ rescue Exception => e # rubocop:disable Lint/RescueException
83
+ abort_download = true
84
+ error = e
85
+ ensure
86
+ completion_queue << :done
87
+ end
88
+ queued_parts += 1
81
89
  rescue StandardError => e
82
- abort_download = true
90
+ # Rejected by the executor, wait for queued parts so none write after cleanup
83
91
  error = e
84
- ensure
85
- completion_queue << :done
92
+ break
86
93
  end
87
94
  end
88
95
 
89
- download_attempts.times { completion_queue.pop }
96
+ queued_parts.times { completion_queue.pop }
90
97
  raise error unless error.nil?
91
98
  end
92
99
 
@@ -169,7 +169,6 @@ module Aws
169
169
  queued_parts += 1
170
170
  rescue StandardError => e
171
171
  # Rejected by the executor; abort rather than orphan the upload.
172
- abort_upload = true
173
172
  errors << e
174
173
  break
175
174
  end
@@ -10,7 +10,7 @@ module Aws
10
10
  super(message)
11
11
  end
12
12
 
13
- # @return [Array<StandardError>] The list of errors encountered when uploading or aborting the upload.
13
+ # @return [Array<Exception>] The list of errors encountered when uploading or aborting the upload.
14
14
  attr_reader :errors
15
15
  end
16
16
  end
data/lib/aws-sdk-s3.rb CHANGED
@@ -75,7 +75,7 @@ module Aws::S3
75
75
  autoload :ObjectVersion, 'aws-sdk-s3/object_version'
76
76
  autoload :EventStreams, 'aws-sdk-s3/event_streams'
77
77
 
78
- GEM_VERSION = '1.233.1'
78
+ GEM_VERSION = '1.235.0'
79
79
 
80
80
  end
81
81
 
data/sig/client.rbs CHANGED
@@ -30,6 +30,7 @@ module Aws
30
30
  ?convert_params: bool,
31
31
  ?correct_clock_skew: bool,
32
32
  ?defaults_mode: String,
33
+ ?disable_clock_skew_correction: bool,
33
34
  ?disable_host_prefix_injection: bool,
34
35
  ?disable_request_compression: bool,
35
36
  ?disable_s3_express_session_auth: bool,
@@ -0,0 +1,17 @@
1
+ module Aws
2
+ module S3
3
+ module Errors
4
+ # Not modeled in the API. Defined at runtime by Aws::Errors::DynamicErrors.
5
+
6
+ # Raised for a 404 response without an error body (e.g. HEAD requests).
7
+ # https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadObject.html
8
+ class NotFound < ServiceError
9
+ end
10
+
11
+ # Raised when S3 returns a 503 Slow Down response because the request rate is too high.
12
+ # https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html#ErrorCodeList
13
+ class SlowDown < ServiceError
14
+ end
15
+ end
16
+ end
17
+ end
data/sig/errors.rbs CHANGED
@@ -11,47 +11,47 @@ module Aws
11
11
  class ServiceError < ::Aws::Errors::ServiceError
12
12
  end
13
13
 
14
- class AccessDenied < ::Aws::Errors::ServiceError
14
+ class AccessDenied < ServiceError
15
15
  end
16
- class AnnotationLimitExceeded < ::Aws::Errors::ServiceError
16
+ class AnnotationLimitExceeded < ServiceError
17
17
  end
18
- class AnnotationNameTooLong < ::Aws::Errors::ServiceError
18
+ class AnnotationNameTooLong < ServiceError
19
19
  end
20
- class BucketAlreadyExists < ::Aws::Errors::ServiceError
20
+ class BucketAlreadyExists < ServiceError
21
21
  end
22
- class BucketAlreadyOwnedByYou < ::Aws::Errors::ServiceError
22
+ class BucketAlreadyOwnedByYou < ServiceError
23
23
  end
24
- class EncryptionTypeMismatch < ::Aws::Errors::ServiceError
24
+ class EncryptionTypeMismatch < ServiceError
25
25
  end
26
- class IdempotencyParameterMismatch < ::Aws::Errors::ServiceError
26
+ class IdempotencyParameterMismatch < ServiceError
27
27
  end
28
- class InvalidAnnotationName < ::Aws::Errors::ServiceError
28
+ class InvalidAnnotationName < ServiceError
29
29
  end
30
- class InvalidObjectState < ::Aws::Errors::ServiceError
30
+ class InvalidObjectState < ServiceError
31
31
  def storage_class: () -> ::String
32
32
  def access_tier: () -> ::String
33
33
  end
34
- class InvalidPrefix < ::Aws::Errors::ServiceError
34
+ class InvalidPrefix < ServiceError
35
35
  end
36
- class InvalidRequest < ::Aws::Errors::ServiceError
36
+ class InvalidRequest < ServiceError
37
37
  end
38
- class InvalidWriteOffset < ::Aws::Errors::ServiceError
38
+ class InvalidWriteOffset < ServiceError
39
39
  end
40
- class NoSuchAnnotation < ::Aws::Errors::ServiceError
40
+ class NoSuchAnnotation < ServiceError
41
41
  end
42
- class NoSuchBucket < ::Aws::Errors::ServiceError
42
+ class NoSuchBucket < ServiceError
43
43
  end
44
- class NoSuchKey < ::Aws::Errors::ServiceError
44
+ class NoSuchKey < ServiceError
45
45
  end
46
- class NoSuchUpload < ::Aws::Errors::ServiceError
46
+ class NoSuchUpload < ServiceError
47
47
  end
48
- class ObjectAlreadyInActiveTierError < ::Aws::Errors::ServiceError
48
+ class ObjectAlreadyInActiveTierError < ServiceError
49
49
  end
50
- class ObjectNotInActiveTierError < ::Aws::Errors::ServiceError
50
+ class ObjectNotInActiveTierError < ServiceError
51
51
  end
52
- class TooManyParts < ::Aws::Errors::ServiceError
52
+ class TooManyParts < ServiceError
53
53
  end
54
- class UnsupportedMediaType < ::Aws::Errors::ServiceError
54
+ class UnsupportedMediaType < ServiceError
55
55
  end
56
56
  end
57
57
  end
@@ -0,0 +1,9 @@
1
+ module Aws
2
+ module S3
3
+ class MultipartUploadError < StandardError
4
+ def initialize: (String message, ?Array[Exception] errors) -> void
5
+
6
+ attr_reader errors: Array[Exception]
7
+ end
8
+ end
9
+ end
data/sig/resource.rbs CHANGED
@@ -30,6 +30,7 @@ module Aws
30
30
  ?convert_params: bool,
31
31
  ?correct_clock_skew: bool,
32
32
  ?defaults_mode: String,
33
+ ?disable_clock_skew_correction: bool,
33
34
  ?disable_host_prefix_injection: bool,
34
35
  ?disable_request_compression: bool,
35
36
  ?disable_s3_express_session_auth: bool,
@@ -0,0 +1,31 @@
1
+ module Aws
2
+ module S3
3
+ class TransferManager
4
+ type download_result = { completed_downloads: Integer, failed_downloads: Integer, ?errors: Array[StandardError] }
5
+ type upload_result = { completed_uploads: Integer, failed_uploads: Integer, ?errors: Array[StandardError] }
6
+ type upload_response = Client::_PutObjectResponseSuccess | Client::_CompleteMultipartUploadResponseSuccess
7
+
8
+ def initialize: (?client: Client, ?executor: untyped, ?logger: untyped) -> void
9
+
10
+ attr_reader client: Client
11
+ attr_reader executor: untyped
12
+ attr_reader logger: untyped
13
+
14
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/TransferManager.html#download_directory-instance_method
15
+ def download_directory: (String destination, bucket: String, **untyped options) -> download_result
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/TransferManager.html#download_file-instance_method
18
+ def download_file: (untyped destination, bucket: String, key: String, **untyped options) -> true
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/TransferManager.html#upload_directory-instance_method
21
+ def upload_directory: (String | Pathname source, bucket: String, **untyped options) -> upload_result
22
+
23
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/TransferManager.html#upload_file-instance_method
24
+ def upload_file: (untyped source, bucket: String, key: String, **untyped options)
25
+ ?{ (upload_response response) -> void } -> true
26
+
27
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/TransferManager.html#upload_stream-instance_method
28
+ def upload_stream: (bucket: String, key: String, **untyped options) { (IO write_stream) -> void } -> true
29
+ end
30
+ end
31
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-s3
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.233.1
4
+ version: 1.235.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
@@ -46,7 +46,7 @@ dependencies:
46
46
  version: '3'
47
47
  - - ">="
48
48
  - !ruby/object:Gem::Version
49
- version: 3.256.0
49
+ version: 3.258.0
50
50
  type: :runtime
51
51
  prerelease: false
52
52
  version_requirements: !ruby/object:Gem::Requirement
@@ -56,7 +56,7 @@ dependencies:
56
56
  version: '3'
57
57
  - - ">="
58
58
  - !ruby/object:Gem::Version
59
- version: 3.256.0
59
+ version: 3.258.0
60
60
  description: Official AWS Ruby gem for Amazon Simple Storage Service (Amazon S3).
61
61
  This gem is part of the AWS SDK for Ruby.
62
62
  email:
@@ -208,10 +208,12 @@ files:
208
208
  - sig/bucket_website.rbs
209
209
  - sig/client.rbs
210
210
  - sig/customizations/bucket.rbs
211
+ - sig/customizations/errors.rbs
211
212
  - sig/customizations/object.rbs
212
213
  - sig/customizations/object_summary.rbs
213
214
  - sig/errors.rbs
214
215
  - sig/multipart_upload.rbs
216
+ - sig/multipart_upload_error.rbs
215
217
  - sig/multipart_upload_part.rbs
216
218
  - sig/object.rbs
217
219
  - sig/object_acl.rbs
@@ -219,6 +221,7 @@ files:
219
221
  - sig/object_version.rbs
220
222
  - sig/params.rbs
221
223
  - sig/resource.rbs
224
+ - sig/transfer_manager.rbs
222
225
  - sig/types.rbs
223
226
  - sig/waiters.rbs
224
227
  homepage: https://github.com/aws/aws-sdk-ruby