kabosu 0.6.11.3-x86_64-linux → 0.6.11.4-x86_64-linux

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: 6c7a3e920238fcea4e26f16ebbdb2c133ec3ac0a93f20c1b2e622a301efc04bb
4
- data.tar.gz: e7a38a4d705a4891157f6b45909813eca3456d452f28ab5929b63b16b1db2602
3
+ metadata.gz: 35471381b6629c0d31472aacae162470842a8156c2391b2b1ccb2861685189e0
4
+ data.tar.gz: 5382f364f3eae050ecff3d11eabeb949307d7da5e029cc7e886fd46ea8978dd3
5
5
  SHA512:
6
- metadata.gz: 70ada36b1c9d22b027d24df8c0e630ac2a843f18604af66adc2d03f98fbcdc4a9223bd09cbfbce03e4024225809500fa5911a9d76aedf66bbc502cf9c9a4cfb0
7
- data.tar.gz: 49e631281970c008e1eae4a03a0f677976da9c5b2a3a7f174ba5b7b9c3b9b56ef6872cebb69bac419580d0ef6158a2237adab25fa4c7abdba5fcd07277c5c6cd
6
+ metadata.gz: 9e3f125d078556fb0333f9e2b7c8ac83a37b71fe1b8666dfd89824b12711cb94c09e70ac75d9cb88d2705390663ab53b9f172532d16222be0035d36cb1bcef4a
7
+ data.tar.gz: 95a24438309c088ff6ad2d8fc872e50ec7223486cad81ad4fe3fa09c87d2910899c0697977f7a3a5594da2700c87af8e10ce126549d2a686d834191a38228174
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -58,19 +58,17 @@ module Kabosu
58
58
  raise DownloadError, "No downloadable assets for #{version}/#{edition}" if sources.empty?
59
59
 
60
60
  sources.each do |source|
61
- begin
62
- download(source.fetch(:url), source.fetch(:archive_path))
63
- extract(source.fetch(:archive_path), dest_dir, edition: edition)
64
- FileUtils.rm_f(source.fetch(:archive_path))
65
- break
66
- rescue DownloadError => e
67
- FileUtils.rm_f(source.fetch(:archive_path)) if File.exist?(source.fetch(:archive_path))
68
- # Try the next candidate (e.g. wheel if the zip 404s). If this was
69
- # the last one, surface the original error.
70
- raise if sources.last.equal?(source)
71
-
72
- warn " falling back: #{e.message}"
73
- end
61
+ download(source.fetch(:url), source.fetch(:archive_path))
62
+ extract(source.fetch(:archive_path), dest_dir, edition: edition)
63
+ FileUtils.rm_f(source.fetch(:archive_path))
64
+ break
65
+ rescue DownloadError => e
66
+ FileUtils.rm_f(source.fetch(:archive_path))
67
+ # Try the next candidate (e.g. wheel if the zip 404s). If this was
68
+ # the last one, surface the original error.
69
+ raise if sources.last.equal?(source)
70
+
71
+ warn " falling back: #{e.message}"
74
72
  end
75
73
 
76
74
  raise DownloadError, "Expected #{dic_path} after extraction, but file not found" unless File.exist?(dic_path)
@@ -214,7 +212,8 @@ module Kabosu
214
212
  def pick_release_sources(version, edition)
215
213
  candidates = []
216
214
  zip = release_asset_url(version, edition)
217
- candidates << { url: zip, archive_path: File.join(@dir, "sudachi-dictionary-#{version}-#{edition}.zip"), format: :zip }
215
+ candidates << { url: zip, archive_path: File.join(@dir, "sudachi-dictionary-#{version}-#{edition}.zip"),
216
+ format: :zip }
218
217
 
219
218
  begin
220
219
  release = fetch_release(version)
@@ -337,14 +336,8 @@ module Kabosu
337
336
 
338
337
  next if entry.directory?
339
338
 
340
- target = File.join(dest_dir, target_name)
341
- # Guard against zip-slip — refuse entries that escape dest_dir.
342
- unless File.expand_path(target).start_with?(File.expand_path(dest_dir) + File::SEPARATOR)
343
- raise DownloadError, "Refusing to extract entry outside dest_dir: #{entry.name}"
344
- end
345
-
346
339
  FileUtils.mkdir_p(dest_dir)
347
- entry.extract(target) { true } # overwrite existing
340
+ entry.extract(target_name, destination_directory: dest_dir) { true }
348
341
  end
349
342
  end
350
343
  rescue Zip::Error => e
@@ -1,3 +1,3 @@
1
1
  module Kabosu
2
- VERSION = "0.6.11.3".freeze
2
+ VERSION = "0.6.11.4".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kabosu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.11.3
4
+ version: 0.6.11.4
5
5
  platform: x86_64-linux
6
6
  authors:
7
7
  - davafons
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-08-20 00:00:00.000000000 Z
11
+ date: 2026-09-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rubyzip
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.3'
19
+ version: '3.4'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '2.3'
26
+ version: '3.4'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: benchmark
29
29
  requirement: !ruby/object:Gem::Requirement