tableau_api 5.0.0 → 6.0.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: 43cac99596054f87a1077b820a3b461fd8eda987d3ae4c785b50bfade19c9543
4
- data.tar.gz: b1a031c5fb30bb1d59e5065ec0f044e8696784ddb673d106aa7f86442d783647
3
+ metadata.gz: 84a36ca634703047a12edf192dd3e0c0c5c383cf692b7a6ca0bfeec5466824ae
4
+ data.tar.gz: 70f55987bcc8879662c14e1cb276f8dfa4a9fbdb0b2b2a2a1d59606d5a319d02
5
5
  SHA512:
6
- metadata.gz: 4386b22e40f004915e66b4051c8de0ce50e6aa0a052f0471429d67a588b2c6d3effe85e5555675685ec2059e256297042a8773bbcf4c141827c7b5f8dd2770e1
7
- data.tar.gz: 4afa373753b3647d72b755e5864e10ba7ddb0de4d2bb55637c3ed4bcc89c64728827285e3661c8e46fb36b4291cde2173c29ec30ab9ab763638c8d534a6bf437
6
+ metadata.gz: 921e1acfb66c6d45fb18cabb85c158c0ba24e3726b55f14a888bd016e5e8d4e66f791ef165a48874256ee31c053f1db0b8fbc4d149c10cc99423bf54c2868f72
7
+ data.tar.gz: b384e520e571445142e9cf305751b2199e92edcc852acfebf535c6f2036abfd1eb6261f16705757ed538d00640e67afe06e63036e05b67bbaa72422c19f30c06
data/.dockerignore ADDED
@@ -0,0 +1,7 @@
1
+ .git
2
+ .bundle
3
+ Gemfile.lock
4
+ coverage
5
+ doc
6
+ pkg
7
+ tmp
data/.rubocop.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  inherit_from: .rubocop_todo.yml
2
2
 
3
3
  AllCops:
4
- TargetRubyVersion: 2.7
4
+ TargetRubyVersion: 3.3
5
5
  NewCops: enable
6
6
 
7
7
  Gemspec/RequiredRubyVersion:
data/.rubocop_todo.yml CHANGED
@@ -1,12 +1,68 @@
1
1
  # This configuration was generated by
2
- # `rubocop --auto-gen-config`
3
- # on 2019-08-21 17:54:45 +0000 using RuboCop version 0.49.1.
2
+ # `rubocop --auto-gen-config --no-auto-gen-timestamp`
3
+ # using RuboCop version 1.91.0.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
7
7
  # versions of RuboCop, may require this file to be generated again.
8
8
 
9
- # Offense count: 13
10
- # Configuration parameters: CountComments, ExcludedMethods.
9
+ # Offense count: 8
10
+ # Configuration parameters: EnforcedStyle, AllowedGems.
11
+ # SupportedStyles: Gemfile, gems.rb, gemspec
12
+ Gemspec/DevelopmentDependencies:
13
+ Exclude:
14
+ - 'tableau_api.gemspec'
15
+
16
+ # Offense count: 1
17
+ # This cop supports safe autocorrection (--autocorrect).
18
+ Layout/EmptyLinesAfterModuleInclusion:
19
+ Exclude:
20
+ - 'lib/tableau_api/connection.rb'
21
+
22
+ # Offense count: 6
23
+ # Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
24
+ # AllowedMethods: refine
11
25
  Metrics/BlockLength:
12
- Max: 316
26
+ Max: 85
27
+
28
+ # Offense count: 1
29
+ # This cop supports safe autocorrection (--autocorrect).
30
+ # Configuration parameters: EnforcedStyle, BlockForwardingName.
31
+ # SupportedStyles: anonymous, explicit
32
+ Naming/BlockForwarding:
33
+ Exclude:
34
+ - 'lib/tableau_api/client.rb'
35
+
36
+ # Offense count: 8
37
+ # Configuration parameters: Mode, AllowedMethods, AllowedPatterns, AllowBangMethods, WaywardPredicates.
38
+ # AllowedMethods: call
39
+ # WaywardPredicates: infinite?, nonzero?
40
+ Naming/PredicateMethod:
41
+ Exclude:
42
+ - 'lib/tableau_api/resources/auth.rb'
43
+ - 'lib/tableau_api/resources/groups.rb'
44
+ - 'lib/tableau_api/resources/workbooks.rb'
45
+
46
+ # Offense count: 2
47
+ # This cop supports safe autocorrection (--autocorrect).
48
+ # Configuration parameters: AllowOnlyRestArgument, UseAnonymousForwarding, RedundantRestArgumentNames, RedundantKeywordRestArgumentNames, RedundantBlockArgumentNames.
49
+ # RedundantRestArgumentNames: args, arguments
50
+ # RedundantKeywordRestArgumentNames: kwargs, options, opts
51
+ # RedundantBlockArgumentNames: blk, block, proc
52
+ Style/ArgumentsForwarding:
53
+ Exclude:
54
+ - 'lib/tableau_api.rb'
55
+
56
+ # Offense count: 3
57
+ # This cop supports unsafe autocorrection (--autocorrect-all).
58
+ Style/DirectiveScope:
59
+ Exclude:
60
+ - 'lib/tableau_api/connection.rb'
61
+ - 'lib/tableau_api/resources/workbooks.rb'
62
+
63
+ # Offense count: 1
64
+ # This cop supports safe autocorrection (--autocorrect).
65
+ # Configuration parameters: AllowMethodComparison, ComparisonsThreshold.
66
+ Style/MultipleComparison:
67
+ Exclude:
68
+ - 'lib/tableau_api/resources/auth.rb'
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 3.2.1
1
+ 3.4
data/.travis.yml CHANGED
@@ -4,6 +4,6 @@ branches:
4
4
  - master
5
5
  language: ruby
6
6
  rvm:
7
- - 3.2.1
8
- - 3.1.3
9
- - 2.7.0
7
+ - 4.0
8
+ - 3.4
9
+ - 3.3
data/CHANGELOG.md CHANGED
@@ -3,9 +3,15 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  This project adheres to [Semantic Versioning](http://semver.org/).
5
5
 
6
- ## upcoming
6
+ ## [6.0.0] - 2026-10-08
7
7
 
8
- ### Changed
8
+ - Breaking: dropped support for Ruby 2.7 through 3.2. The minimum required Ruby version is now 3.3.
9
+ - Bumped rubyzip to ~> 3.7 to address open security advisories
10
+ - Bumped httparty to ~> 0.22 and added multi_xml ~> 0.7, so Ruby 3.4+ gets the csv and bigdecimal gems it no longer bundles
11
+ - `Workbooks#version` now returns nil for a twbx with no twb at the archive root, instead of raising NoMethodError
12
+ - Bumped dev dependencies: rake ~> 13.0, rubocop ~> 1.91, chunky_png ~> 1.4
13
+ - Bumped CI matrix Ruby versions to 4.0, 3.4, and 3.3
14
+ - Added a Dockerfile and docker-compose.yml for development
9
15
 
10
16
  ## [5.0.0] - 2023-03-23
11
17
 
@@ -113,7 +119,8 @@ This project adheres to [Semantic Versioning](http://semver.org/).
113
119
 
114
120
  - Initial Release
115
121
 
116
- [Unreleased]: https://github.com/civisanalytics/tableau_api/compare/v1.1.2...HEAD
122
+ [6.0.0]: https://github.com/civisanalytics/tableau_api/compare/v5.0.0...v6.0.0
123
+ [Unreleased]: https://github.com/civisanalytics/tableau_api/compare/v6.0.0...HEAD
117
124
  [1.1.2]: https://github.com/civisanalytics/tableau_api/compare/v1.1.1...v1.1.2
118
125
  [1.1.1]: https://github.com/civisanalytics/tableau_api/compare/v1.1.0...v1.1.1
119
126
  [1.1.0]: https://github.com/civisanalytics/tableau_api/compare/v1.0.0...v1.1.0
data/Dockerfile ADDED
@@ -0,0 +1,13 @@
1
+ ARG RUBY_VERSION=3.4
2
+ FROM ruby:${RUBY_VERSION}
3
+
4
+ WORKDIR /src
5
+
6
+ # The gemspec shells out to `git ls-files`, and the repo is bind-mounted from the host.
7
+ RUN git config --global --add safe.directory /src
8
+
9
+ ENV BUNDLE_PATH=/bundle \
10
+ BUNDLE_BIN=/bundle/bin \
11
+ PATH=/bundle/bin:$PATH
12
+
13
+ CMD ["bash"]
data/README.md CHANGED
@@ -53,9 +53,18 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
53
53
 
54
54
  ### Docker
55
55
 
56
+ A development image is provided so you don't need a local Ruby toolchain. The image and the installed gems are kept per Ruby version, so versions don't interfere with each other.
57
+
56
58
  ```
57
- docker run -it -d -v $(pwd):/src ruby:2 /bin/bash
58
- docker exec -it CONTAINER_ID /bin/bash -c "cd /src && bundle && rake"
59
+ docker compose run --rm dev bundle install
60
+ docker compose run --rm dev bundle exec rake
61
+ ```
62
+
63
+ This uses Ruby 3.4 by default. To run against another supported Ruby (3.3 and newer), set `RUBY_VERSION` on the same commands. The image is built the first time a version is used:
64
+
65
+ ```
66
+ RUBY_VERSION=3.3 docker compose run --rm dev bundle install
67
+ RUBY_VERSION=3.3 docker compose run --rm dev bundle exec rake
59
68
  ```
60
69
 
61
70
  ### Creating New VCR Cassettes
@@ -0,0 +1,16 @@
1
+ services:
2
+ dev:
3
+ image: tableau_api-dev:${RUBY_VERSION:-3.4}
4
+ build:
5
+ context: .
6
+ args:
7
+ RUBY_VERSION: ${RUBY_VERSION:-3.4}
8
+ volumes:
9
+ - .:/src
10
+ - bundle:/bundle
11
+ stdin_open: true
12
+ tty: true
13
+
14
+ volumes:
15
+ bundle:
16
+ name: tableau_api-bundle-${RUBY_VERSION:-3.4}
@@ -11,6 +11,8 @@ module TableauApi
11
11
  if File.exist?(file) && File.extname(file) == '.twbx'
12
12
  Zip::File.open(file) do |zip_file|
13
13
  entry = zip_file.glob('*.twb').first
14
+ next unless entry
15
+
14
16
  version = HTTParty::Parser.new(entry.get_input_stream.read, :xml).parse['workbook']['version']
15
17
  end
16
18
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TableauApi
4
- VERSION = '5.0.0'
4
+ VERSION = '6.0.0'
5
5
  end
data/tableau_api.gemspec CHANGED
@@ -19,19 +19,20 @@ Gem::Specification.new do |spec|
19
19
  spec.bindir = 'exe'
20
20
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
21
  spec.require_paths = ['lib']
22
- spec.required_ruby_version = '>= 2.7'
22
+ spec.required_ruby_version = '>= 3.3'
23
23
 
24
24
  spec.add_dependency 'builder', '~> 3.2'
25
- spec.add_dependency 'httparty', '~> 0.13'
25
+ spec.add_dependency 'httparty', '~> 0.22'
26
26
  spec.add_dependency 'multipart-post', '~> 2.0'
27
- spec.add_dependency 'rubyzip', '~> 1.0'
27
+ spec.add_dependency 'multi_xml', '~> 0.7'
28
+ spec.add_dependency 'rubyzip', '~> 3.7'
28
29
 
29
- spec.add_development_dependency 'chunky_png', '~> 1.3.11'
30
+ spec.add_development_dependency 'chunky_png', '~> 1.4'
30
31
  spec.add_development_dependency 'pry', '~> 0.10'
31
32
  spec.add_development_dependency 'pry-byebug', '~> 3.4'
32
- spec.add_development_dependency 'rake', '~> 12.3.3'
33
+ spec.add_development_dependency 'rake', '~> 13.0'
33
34
  spec.add_development_dependency 'rspec', '~> 3.6'
34
- spec.add_development_dependency 'rubocop', '~> 1.48.1'
35
+ spec.add_development_dependency 'rubocop', '~> 1.91'
35
36
  spec.add_development_dependency 'vcr', '~> 6.0'
36
37
  spec.add_development_dependency 'webmock', '~> 3.0'
37
38
  spec.metadata['rubygems_mfa_required'] = 'true'
metadata CHANGED
@@ -1,16 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tableau_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.0
4
+ version: 6.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Christopher Manning
8
8
  - Matt Brennan
9
9
  - Jonathan Cobian
10
- autorequire:
11
10
  bindir: exe
12
11
  cert_chain: []
13
- date: 2023-03-23 00:00:00.000000000 Z
12
+ date: 1980-01-02 00:00:00.000000000 Z
14
13
  dependencies:
15
14
  - !ruby/object:Gem::Dependency
16
15
  name: builder
@@ -32,14 +31,14 @@ dependencies:
32
31
  requirements:
33
32
  - - "~>"
34
33
  - !ruby/object:Gem::Version
35
- version: '0.13'
34
+ version: '0.22'
36
35
  type: :runtime
37
36
  prerelease: false
38
37
  version_requirements: !ruby/object:Gem::Requirement
39
38
  requirements:
40
39
  - - "~>"
41
40
  - !ruby/object:Gem::Version
42
- version: '0.13'
41
+ version: '0.22'
43
42
  - !ruby/object:Gem::Dependency
44
43
  name: multipart-post
45
44
  requirement: !ruby/object:Gem::Requirement
@@ -54,34 +53,48 @@ dependencies:
54
53
  - - "~>"
55
54
  - !ruby/object:Gem::Version
56
55
  version: '2.0'
56
+ - !ruby/object:Gem::Dependency
57
+ name: multi_xml
58
+ requirement: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - "~>"
61
+ - !ruby/object:Gem::Version
62
+ version: '0.7'
63
+ type: :runtime
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: '0.7'
57
70
  - !ruby/object:Gem::Dependency
58
71
  name: rubyzip
59
72
  requirement: !ruby/object:Gem::Requirement
60
73
  requirements:
61
74
  - - "~>"
62
75
  - !ruby/object:Gem::Version
63
- version: '1.0'
76
+ version: '3.7'
64
77
  type: :runtime
65
78
  prerelease: false
66
79
  version_requirements: !ruby/object:Gem::Requirement
67
80
  requirements:
68
81
  - - "~>"
69
82
  - !ruby/object:Gem::Version
70
- version: '1.0'
83
+ version: '3.7'
71
84
  - !ruby/object:Gem::Dependency
72
85
  name: chunky_png
73
86
  requirement: !ruby/object:Gem::Requirement
74
87
  requirements:
75
88
  - - "~>"
76
89
  - !ruby/object:Gem::Version
77
- version: 1.3.11
90
+ version: '1.4'
78
91
  type: :development
79
92
  prerelease: false
80
93
  version_requirements: !ruby/object:Gem::Requirement
81
94
  requirements:
82
95
  - - "~>"
83
96
  - !ruby/object:Gem::Version
84
- version: 1.3.11
97
+ version: '1.4'
85
98
  - !ruby/object:Gem::Dependency
86
99
  name: pry
87
100
  requirement: !ruby/object:Gem::Requirement
@@ -116,14 +129,14 @@ dependencies:
116
129
  requirements:
117
130
  - - "~>"
118
131
  - !ruby/object:Gem::Version
119
- version: 12.3.3
132
+ version: '13.0'
120
133
  type: :development
121
134
  prerelease: false
122
135
  version_requirements: !ruby/object:Gem::Requirement
123
136
  requirements:
124
137
  - - "~>"
125
138
  - !ruby/object:Gem::Version
126
- version: 12.3.3
139
+ version: '13.0'
127
140
  - !ruby/object:Gem::Dependency
128
141
  name: rspec
129
142
  requirement: !ruby/object:Gem::Requirement
@@ -144,14 +157,14 @@ dependencies:
144
157
  requirements:
145
158
  - - "~>"
146
159
  - !ruby/object:Gem::Version
147
- version: 1.48.1
160
+ version: '1.91'
148
161
  type: :development
149
162
  prerelease: false
150
163
  version_requirements: !ruby/object:Gem::Requirement
151
164
  requirements:
152
165
  - - "~>"
153
166
  - !ruby/object:Gem::Version
154
- version: 1.48.1
167
+ version: '1.91'
155
168
  - !ruby/object:Gem::Dependency
156
169
  name: vcr
157
170
  requirement: !ruby/object:Gem::Requirement
@@ -180,13 +193,13 @@ dependencies:
180
193
  - - "~>"
181
194
  - !ruby/object:Gem::Version
182
195
  version: '3.0'
183
- description:
184
196
  email:
185
197
  - opensource@civisanalytics.com
186
198
  executables: []
187
199
  extensions: []
188
200
  extra_rdoc_files: []
189
201
  files:
202
+ - ".dockerignore"
190
203
  - ".gitignore"
191
204
  - ".rspec"
192
205
  - ".rubocop.yml"
@@ -195,12 +208,14 @@ files:
195
208
  - ".travis.yml"
196
209
  - CHANGELOG.md
197
210
  - CODE_OF_CONDUCT.md
211
+ - Dockerfile
198
212
  - Gemfile
199
213
  - LICENSE.txt
200
214
  - README.md
201
215
  - Rakefile
202
216
  - bin/console
203
217
  - bin/setup
218
+ - docker-compose.yml
204
219
  - lib/tableau_api.rb
205
220
  - lib/tableau_api/client.rb
206
221
  - lib/tableau_api/connection.rb
@@ -221,7 +236,6 @@ licenses:
221
236
  - BSD-3-Clause
222
237
  metadata:
223
238
  rubygems_mfa_required: 'true'
224
- post_install_message:
225
239
  rdoc_options: []
226
240
  require_paths:
227
241
  - lib
@@ -229,15 +243,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
229
243
  requirements:
230
244
  - - ">="
231
245
  - !ruby/object:Gem::Version
232
- version: '2.7'
246
+ version: '3.3'
233
247
  required_rubygems_version: !ruby/object:Gem::Requirement
234
248
  requirements:
235
249
  - - ">="
236
250
  - !ruby/object:Gem::Version
237
251
  version: '0'
238
252
  requirements: []
239
- rubygems_version: 3.4.6
240
- signing_key:
253
+ rubygems_version: 3.6.9
241
254
  specification_version: 4
242
255
  summary: Ruby interface to the Tableau API.
243
256
  test_files: []