dubbletrack_remote 0.7.5 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ruby.yml +1 -1
- data/.tool-versions +1 -1
- data/CHANGELOG.md +20 -0
- data/config/settings-example.yml +1 -1
- data/dubbletrack_remote.gemspec +1 -1
- data/lib/dubbletrack_remote/cli.rb +4 -6
- data/lib/dubbletrack_remote/client.rb +3 -4
- data/lib/dubbletrack_remote/reader/dbf.rb +0 -3
- data/lib/dubbletrack_remote/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fbd23b3429fcbcfddcd0f46d491d01e060ff2a269ae2f0b2f3d0baa37c3d1def
|
4
|
+
data.tar.gz: 9848afcc5a09b4dd37bf5ccd48eb93064d0fe15a67a606a6a92ec6ca820d04b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4071400ce0276d7767760886ff4f0aab2b6e9f6a7846493ea0d0f5884881dadcb9495021fea40da1b7f44069f980ca985ad166fa7718d7d3ee5d159380052a71
|
7
|
+
data.tar.gz: 90c035c0f5be2d929e06535ab587fa02b24471fb5ac4b4385bfad413484b850d9386d29aa65257ffcb5b93248d60d965dde01f949f0c6e4fcf44ee49907b55c8
|
data/.github/workflows/ruby.yml
CHANGED
data/.tool-versions
CHANGED
@@ -1 +1 @@
|
|
1
|
-
ruby
|
1
|
+
ruby 3.1.2
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,25 @@
|
|
1
1
|
dubbletrack remote changelog
|
2
2
|
|
3
|
+
# [0.8.0](https://github.com/dubbletrack/remote/compare/v0.7.6...v0.8.0) (2024-07-10)
|
4
|
+
|
5
|
+
|
6
|
+
### Bug Fixes
|
7
|
+
|
8
|
+
* use delay time for test ([37d3fb6](https://github.com/dubbletrack/remote/commit/37d3fb669929800277e39942f565cf1f14075854))
|
9
|
+
|
10
|
+
|
11
|
+
### Features
|
12
|
+
|
13
|
+
* send in batches ([be99f11](https://github.com/dubbletrack/remote/commit/be99f11d13b377b1e4f751b65c9fd42c766b3217))
|
14
|
+
* update to use v2 endpoint and save uuids ([51e0e6f](https://github.com/dubbletrack/remote/commit/51e0e6f4c2208d5281feb0b8f5281924bac78e39))
|
15
|
+
|
16
|
+
## [0.7.6](https://github.com/dubbletrack/remote/compare/v0.7.5...v0.7.6) (2023-06-15)
|
17
|
+
|
18
|
+
|
19
|
+
### Bug Fixes
|
20
|
+
|
21
|
+
* remove debug statements ([8756eef](https://github.com/dubbletrack/remote/commit/8756eef2ff9322eb35d225d42d1c15a505c9db44))
|
22
|
+
|
3
23
|
## [0.7.5](https://github.com/dubbletrack/remote/compare/v0.7.4...v0.7.5) (2023-06-15)
|
4
24
|
|
5
25
|
|
data/config/settings-example.yml
CHANGED
data/dubbletrack_remote.gemspec
CHANGED
@@ -55,7 +55,7 @@ Gem::Specification.new do |spec|
|
|
55
55
|
spec.add_dependency "require_all", "~> 3.0"
|
56
56
|
spec.add_dependency "rspec", "~> 3.9.0"
|
57
57
|
spec.add_dependency "sinatra-activerecord", "~> 2.0.18"
|
58
|
-
spec.add_dependency "sqlite3", "~> 1.
|
58
|
+
spec.add_dependency "sqlite3", "~> 1.5.1"
|
59
59
|
spec.add_dependency "thor", "~> 1.0.1"
|
60
60
|
spec.add_dependency "timecop", "~> 0.9.1"
|
61
61
|
spec.add_dependency "tzinfo", "~> 1.2.9"
|
@@ -23,9 +23,7 @@ module DubbletrackRemote
|
|
23
23
|
|
24
24
|
Thread.new do
|
25
25
|
loop do
|
26
|
-
Item.next(
|
27
|
-
client.send([item])
|
28
|
-
end
|
26
|
+
client.send(Item.next(25))
|
29
27
|
update # this feels redundant with the watch above
|
30
28
|
status
|
31
29
|
rescue => e
|
@@ -86,8 +84,8 @@ module DubbletrackRemote
|
|
86
84
|
|
87
85
|
if remaining.count > 0
|
88
86
|
puts "sending #{remaining.size} from playlist #{file_path}"
|
89
|
-
Item.where(id: remaining.pluck(:id)).remaining.
|
90
|
-
client.send(
|
87
|
+
Item.where(id: remaining.pluck(:id)).remaining.find_in_batches(batch_size: 25) do |items|
|
88
|
+
client.send(items)
|
91
89
|
end
|
92
90
|
end
|
93
91
|
else
|
@@ -328,7 +326,7 @@ module DubbletrackRemote
|
|
328
326
|
playlists_path = ask "Where should I look for playlists? (This can include regex and strftime components, i.e. /Enco/Dad/STUDIO[1-2]%m%d%y.DBF)", path: true
|
329
327
|
end
|
330
328
|
<<~YAMS.strip
|
331
|
-
api_url: https://api.dubbletrack.com/api/
|
329
|
+
api_url: https://api.dubbletrack.com/api/v2/automation
|
332
330
|
api_key: #{api_key}
|
333
331
|
api_secret: #{api_secret}
|
334
332
|
automation:
|
@@ -13,7 +13,7 @@ module DubbletrackRemote
|
|
13
13
|
faraday.adapter Faraday.default_adapter # make requests with Net::HTTP
|
14
14
|
end
|
15
15
|
|
16
|
-
@url = url # || 'https://dubbletrack.com/api/
|
16
|
+
@url = url # || 'https://api.dubbletrack.com/api/v2/automation'
|
17
17
|
@key = key # || 'dt_xxxxxxxx'
|
18
18
|
@secret = secret # || 'dts_xxxxxxxxxxxx'
|
19
19
|
end
|
@@ -49,13 +49,12 @@ module DubbletrackRemote
|
|
49
49
|
|
50
50
|
found_response = if data.size > 1
|
51
51
|
data.find do |d|
|
52
|
-
d["
|
53
|
-
d["attributes"]["artist_name"] == item.artist_name
|
52
|
+
d["remote_automation_id"] == item.automation_id
|
54
53
|
end
|
55
54
|
else
|
56
55
|
data.first
|
57
56
|
end
|
58
|
-
item.remote_id = found_response["
|
57
|
+
item.remote_id = found_response["uuid"] if found_response
|
59
58
|
item.save
|
60
59
|
puts item.pretty_print
|
61
60
|
end
|
@@ -43,8 +43,6 @@ module DubbletrackRemote
|
|
43
43
|
attrs[key] = attrs[key].mb_chars.tidy_bytes.to_s
|
44
44
|
end
|
45
45
|
|
46
|
-
debugger unless attrs["LENGTH"]
|
47
|
-
|
48
46
|
attrs
|
49
47
|
end
|
50
48
|
|
@@ -86,7 +84,6 @@ module DubbletrackRemote
|
|
86
84
|
date = (hash["DATE"] || "").strip
|
87
85
|
time = (hash["ACTSTART"] || "").strip
|
88
86
|
|
89
|
-
debugger if hash["TITLE"] == "PSA CSA Juneteenth 23"
|
90
87
|
duration = (hash["LENGTH"] || "0.0").to_f
|
91
88
|
automation_id = (hash["CUT"] || "").strip
|
92
89
|
automation_group = (hash["GROUP"] || "").strip
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dubbletrack_remote
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeff Keen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-07-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: minitest
|
@@ -282,14 +282,14 @@ dependencies:
|
|
282
282
|
requirements:
|
283
283
|
- - "~>"
|
284
284
|
- !ruby/object:Gem::Version
|
285
|
-
version: 1.
|
285
|
+
version: 1.5.1
|
286
286
|
type: :runtime
|
287
287
|
prerelease: false
|
288
288
|
version_requirements: !ruby/object:Gem::Requirement
|
289
289
|
requirements:
|
290
290
|
- - "~>"
|
291
291
|
- !ruby/object:Gem::Version
|
292
|
-
version: 1.
|
292
|
+
version: 1.5.1
|
293
293
|
- !ruby/object:Gem::Dependency
|
294
294
|
name: thor
|
295
295
|
requirement: !ruby/object:Gem::Requirement
|