sequel_bitemporal 0.11.0 → 0.11.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 33df8e3ea5762139cd17bc15469b6f4c0535e698191eff1db9feb1387be4eb9b
4
- data.tar.gz: da3482ad1fa5d018fc50e95c45940beba6013205574f65257be300abbfc119ee
3
+ metadata.gz: 42f549f8678f8debbf16a8fbec81d01b07dc3a106a5e2e73792dd5290e4e7c0d
4
+ data.tar.gz: '04492a9f9795923438306c0671423407aea09db2835e7361f0adbcfa1dcd2ada'
5
5
  SHA512:
6
- metadata.gz: 0b6f966365eaf5c42143b5e050c467aaef0b1e479c68fd792cbedc1cf4d3c420962651254ca9dd1344c95e4401f3ee2ba56f6acb54702248a8d4d5684d351265
7
- data.tar.gz: 176b15f045e9b91b29857f0b5e1ffcbb313d44cd623bd10718cbdabd359ba929b55c231882d639e47499c496307c8b5bbf9c160cacc11569d46c624bca9439d3
6
+ metadata.gz: '03636048e87d3762aae4d4b8361a5c54e6e91e68ba58e4d2622cf80a930f4d75ba93e2b515bb5ec61cdaa42215fdc17728d92a3979402c089a3e73348967df31'
7
+ data.tar.gz: d1f35b35383a38cf9cfbc6e358233e931b318dd019d2c5d595d8e210ebf70eb50df7054858f1edc6b3f16ed8591e96d5cc78e4b60121d1c264097a9e9c4fe608
@@ -332,7 +332,7 @@ module Sequel
332
332
  { master_id: id }
333
333
  end
334
334
 
335
- current_version.columns.each do |key|
335
+ current_version.keys.each do |key|
336
336
  next if excluded_columns.include? key
337
337
  current_attributes[key] = current_version.public_send key
338
338
  end if current_version?
@@ -592,7 +592,7 @@ module Sequel
592
592
 
593
593
  def save_fossil(expired, attributes={})
594
594
  fossil = model.version_class.new
595
- expired_attributes = expired.columns.each_with_object({}) do |key, hash|
595
+ expired_attributes = expired.keys.each_with_object({}) do |key, hash|
596
596
  hash[key] = expired.public_send key
597
597
  end
598
598
  expired_attributes.delete :id
@@ -603,7 +603,7 @@ module Sequel
603
603
 
604
604
  def save_propagated(version, attributes={})
605
605
  propagated = model.version_class.new
606
- version_attributes = version.columns.each_with_object({}) do |key, hash|
606
+ version_attributes = version.keys.each_with_object({}) do |key, hash|
607
607
  hash[key] = version.public_send key
608
608
  end
609
609
  version_attributes.delete :id
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "sequel_bitemporal"
6
- s.version = "0.11.0"
6
+ s.version = "0.11.1"
7
7
  s.authors = ["Joseph HALTER", "Jonathan TRON"]
8
8
  s.email = ["joseph.halter@thetalentbox.com", "jonathan.tron@thetalentbox.com"]
9
9
  s.homepage = "https://github.com/TalentBox/sequel_bitemporal"
@@ -11,14 +11,14 @@ Gem::Specification.new do |s|
11
11
  s.description = "Bitemporal versioning for sequel, fully tested."
12
12
  s.license = "MIT"
13
13
 
14
- s.files = `git ls-files`.split("\n")
14
+ s.files = `git ls-files`.split("\n").reject{|f| f.start_with?(".github") || f.start_with?("ci") }
15
15
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
16
16
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
17
17
  s.require_paths = ["lib"]
18
18
 
19
19
  s.add_runtime_dependency "sequel", ">= 4.0", "< 6.0"
20
20
 
21
- s.add_development_dependency "rspec", "~> 3.6.0"
21
+ s.add_development_dependency "rspec", "~> 3.13.0"
22
22
  s.add_development_dependency "timecop"
23
23
  s.add_development_dependency "rake"
24
24
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sequel_bitemporal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.0
4
+ version: 0.11.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joseph HALTER
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2024-02-12 00:00:00.000000000 Z
12
+ date: 2024-02-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: sequel
@@ -37,14 +37,14 @@ dependencies:
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 3.6.0
40
+ version: 3.13.0
41
41
  type: :development
42
42
  prerelease: false
43
43
  version_requirements: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 3.6.0
47
+ version: 3.13.0
48
48
  - !ruby/object:Gem::Dependency
49
49
  name: timecop
50
50
  requirement: !ruby/object:Gem::Requirement
@@ -81,7 +81,6 @@ executables: []
81
81
  extensions: []
82
82
  extra_rdoc_files: []
83
83
  files:
84
- - ".github/workflows/ci.yml"
85
84
  - ".gitignore"
86
85
  - ".rspec"
87
86
  - ".ruby-version"
@@ -89,7 +88,6 @@ files:
89
88
  - LICENSE
90
89
  - README.md
91
90
  - Rakefile
92
- - ci/sequel.gemfile
93
91
  - lib/sequel/plugins/bitemporal.rb
94
92
  - lib/sequel_bitemporal.rb
95
93
  - sequel_bitemporal.gemspec
@@ -1,64 +0,0 @@
1
- name: CI
2
-
3
- on:
4
- push:
5
- branches: [ master ]
6
- pull_request:
7
- branches: ['**']
8
-
9
- jobs:
10
- tests:
11
- services:
12
- postgres:
13
- image: postgres:13
14
- env:
15
- POSTGRES_USER: postgres
16
- POSTGRES_PASSWORD: postgres
17
- ports:
18
- - 5432
19
- options: >-
20
- --health-cmd pg_isready
21
- --health-interval 10s
22
- --health-timeout 5s
23
- --health-retries 5
24
-
25
- runs-on: ubuntu-latest
26
- strategy:
27
- fail-fast: false
28
- matrix:
29
- ruby:
30
- - "2.7"
31
- - "3.0"
32
- - "3.1"
33
- - "3.2"
34
- - "3.3"
35
- name: Ruby ${{ matrix.ruby }}
36
-
37
- env:
38
- SEQUEL: "~> 5.0"
39
- BUNDLE_GEMFILE: "ci/sequel.gemfile"
40
- steps:
41
- - uses: actions/checkout@v3
42
- - name: Install db dependencies and check connections
43
- run: |
44
- env PGPASSWORD=postgres psql -h localhost -p ${{ job.services.postgres.ports[5432] }} -U postgres -l
45
- - uses: ruby/setup-ruby@v1
46
- with:
47
- ruby-version: ${{ matrix.ruby }}
48
- bundler-cache: true
49
- - name: Create databases
50
- run: |
51
- env PGPASSWORD=postgres psql -c 'create database sequel_bitemporal_test;' -U postgres -h localhost -p ${{ job.services.postgres.ports[5432] }}
52
- - name: Run PostgreSQL tests
53
- run: bundle exec rake spec
54
- env:
55
- TEST_ADAPTER: postgresql
56
- TEST_DATABASE: sequel_bitemporal_test
57
- TEST_DATABASE_HOST: localhost
58
- TEST_DATABASE_PORT: ${{ job.services.postgres.ports[5432] }}
59
- TEST_USERNAME: postgres
60
- TEST_PASSWORD: postgres
61
- - name: Run SQLite tests
62
- run: bundle exec rake spec
63
- env:
64
- TEST_ADAPTER: sqlite
data/ci/sequel.gemfile DELETED
@@ -1,17 +0,0 @@
1
- source 'https://rubygems.org'
2
-
3
- gemspec :path => '../'
4
-
5
- gem 'sequel', "#{ENV['SEQUEL']}"
6
-
7
- # MRI/Rubinius Adapter Dependencies
8
- platforms :ruby do
9
- gem "pg"
10
- gem "sqlite3"
11
- end
12
-
13
- # JRuby Adapter Dependencies
14
- platforms :jruby do
15
- gem "jdbc-postgres"
16
- gem "jdbc-sqlite3"
17
- end