ducklake 0.1.3 → 0.1.4

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: 98460f8bbd24007057521ad2749899aebd4e689c0183ab98551e7c0e9d7b8ffe
4
- data.tar.gz: 726ea12c95079c99999b9415fb915e05818548bcab38647413eee44018c2a7f3
3
+ metadata.gz: 535980c5eabd395203e0abc095d01b8ed502e12e4880347d06840a04f92cc98b
4
+ data.tar.gz: c9c8aac81ae63bd8d870a330cbdd1f3188dde5ee815909aa114ca200530ff62a
5
5
  SHA512:
6
- metadata.gz: 772924fb6262d3a3373eb2e92431b55dc73f81869e2aaf1a92746831c1d784f669a9e82a03a8c4d2538bda7c7980e940cd29f65c068ca996ea71a55c19d37dbd
7
- data.tar.gz: c57170ee010ea949d4f8c250f3ff4fcc05a3153b1e25d9412ba12cd53e4ef7e866f088e2956886948757e0586f4005087e50c89fff1295404ce4c01baae79ce1
6
+ metadata.gz: '09115886b370740f415fe59c321ca6df78c1a21c8c5e5a8be608444ba54394eb706f9e07381a10b4cfe81a7114383074e157708ed1ef79c7f08e3e042858669e'
7
+ data.tar.gz: 2047f9acd798b0c8ce52215bef6420fde44602e6e360ccf54e5b020ac3b83ec8d3df72671b3894023ad07c523a5613f85717d16b55ee2e72a5ba0fdf73d19ed0
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 0.1.4 (2026-03-09)
2
+
3
+ - Added support for DuckDB 1.5
4
+
1
5
  ## 0.1.3 (2025-09-23)
2
6
 
3
7
  - Added `current_snapshot` and `last_committed_snapshot` methods
data/LICENSE.txt CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2025 Andrew Kane
3
+ Copyright (c) 2025-2026 Andrew Kane
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/README.md CHANGED
@@ -163,6 +163,8 @@ Delete data
163
163
  ducklake.sql("DELETE * FROM events WHERE id = ?", [1])
164
164
  ```
165
165
 
166
+ ## Transactions
167
+
166
168
  Run multiple statements in a transaction
167
169
 
168
170
  ```ruby
@@ -173,6 +175,16 @@ end
173
175
 
174
176
  Raise `DuckLake::Rollback` to rollback
175
177
 
178
+ Add commit info to a transaction
179
+
180
+ ```ruby
181
+ ducklake.transaction(commit_message: "...", commit_author: "...") do
182
+ # ...
183
+ end
184
+ ```
185
+
186
+ This will appear in [snapshots](#snapshots)
187
+
176
188
  ## Schema Changes
177
189
 
178
190
  Update the schema
@@ -211,6 +223,12 @@ Get snapshots
211
223
  ducklake.snapshots
212
224
  ```
213
225
 
226
+ Get the current snapshot
227
+
228
+ ```ruby
229
+ ducklake.current_snapshot
230
+ ```
231
+
214
232
  Query the data at a specific snapshot version or time
215
233
 
216
234
  ```ruby
@@ -247,6 +265,12 @@ Clean up old files
247
265
  ducklake.cleanup_old_files(older_than: Date.today - 7)
248
266
  ```
249
267
 
268
+ Rewrite files with a certain percentage of deleted rows
269
+
270
+ ```ruby
271
+ ducklake.rewrite_data_files(delete_threshold: 0.5)
272
+ ```
273
+
250
274
  ## Configuration
251
275
 
252
276
  Get [options](https://ducklake.select/docs/stable/duckdb/usage/configuration)
@@ -328,7 +352,7 @@ ducklake.sql("COPY #{quoted_table} FROM #{quoted_file}")
328
352
 
329
353
  ## Encryption
330
354
 
331
- Note: This feature is unreleased and must be set when creating the catalog
355
+ Note: This feature is experimental and must be set when creating the catalog
332
356
 
333
357
  Encrypt Parquet files
334
358
 
@@ -64,7 +64,7 @@ module DuckLake
64
64
  attach_options[:encrypted] = 1 if encrypted
65
65
  attach_options[:snapshot_version] = snapshot_version if !snapshot_version.nil?
66
66
  attach_options[:snapshot_time] = snapshot_time if !snapshot_time.nil?
67
- attach_options[:data_inlining_row_limit] = data_inlining_row_limit if data_inlining_row_limit > 0
67
+ attach_options[:data_inlining_row_limit] = data_inlining_row_limit
68
68
  attach_options[:create_if_not_exists] = false unless create_if_not_exists
69
69
  attach_options[:migrate_if_required] = false unless migrate_if_required
70
70
  attach_options[:override_data_path] = true if override_storage_url
@@ -220,6 +220,16 @@ module DuckLake
220
220
  execute("SELECT value FROM ducklake_options(?) WHERE option_name = ?", [@catalog, "version"]).first["value"]
221
221
  end
222
222
 
223
+ # experimental
224
+ def extension_version
225
+ execute("SELECT extension_version FROM duckdb_extensions() WHERE extension_name = ?", ["ducklake"]).first["extension_version"]
226
+ end
227
+
228
+ # experimental
229
+ def duckdb_version
230
+ execute("SELECT VERSION() AS version").first["version"]
231
+ end
232
+
223
233
  # https://ducklake.select/docs/stable/duckdb/maintenance/merge_adjacent_files
224
234
  def merge_adjacent_files
225
235
  execute("CALL merge_adjacent_files()")
@@ -331,6 +341,7 @@ module DuckLake
331
341
  params << table_name
332
342
  end
333
343
 
344
+ # TODO return nil in 0.2.0
334
345
  symbolize_keys execute("CALL ducklake_flush_inlined_data(#{args.join(", ")})", params)
335
346
  end
336
347
 
@@ -1,3 +1,3 @@
1
1
  module DuckLake
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.4"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ducklake
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Kane
@@ -53,7 +53,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  requirements: []
56
- rubygems_version: 3.6.9
56
+ rubygems_version: 4.0.3
57
57
  specification_version: 4
58
58
  summary: DuckLake for Ruby
59
59
  test_files: []