panda_pal 5.3.6.beta1 → 5.3.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +21 -1
- data/app/controllers/panda_pal/lti_v1_p0_controller.rb +1 -1
- data/app/controllers/panda_pal/lti_v1_p3_controller.rb +8 -4
- data/app/lib/lti_xml/base_platform.rb +7 -2
- data/app/lib/panda_pal/launch_url_helpers.rb +15 -8
- data/app/models/panda_pal/organization_concerns/settings_validation.rb +14 -0
- data/config/routes.rb +1 -0
- data/db/618eef7c0380ba654ad16f867a919e72.sqlite3 +0 -0
- data/db/9ff93d4f7e0e9dc80a43f68997caf4a1.sqlite3 +0 -0
- data/db/a3fda4044a7215bc2c9eb01a4b9e517a.sqlite3 +0 -0
- data/db/daa0e6378a5ec76fcce83b7070dad219.sqlite3 +0 -0
- data/db/migrate/20171205194657_remove_old_organization_settings.rb +1 -0
- data/lib/panda_pal.rb +1 -0
- data/lib/panda_pal/helpers/controller_helper.rb +7 -2
- data/lib/panda_pal/helpers/route_helper.rb +6 -0
- data/lib/panda_pal/version.rb +1 -1
- data/panda_pal.gemspec +1 -0
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/log/development.log +15042 -40
- data/spec/dummy/log/test.log +0 -83348
- metadata +31 -10
- data/app/lib/panda_pal/batch_processor.rb +0 -41
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: panda_pal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.3.
|
4
|
+
version: 5.3.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Instructure ProServe
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-02-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -128,6 +128,20 @@ dependencies:
|
|
128
128
|
- - ">="
|
129
129
|
- !ruby/object:Gem::Version
|
130
130
|
version: '0'
|
131
|
+
- !ruby/object:Gem::Dependency
|
132
|
+
name: httparty
|
133
|
+
requirement: !ruby/object:Gem::Requirement
|
134
|
+
requirements:
|
135
|
+
- - ">="
|
136
|
+
- !ruby/object:Gem::Version
|
137
|
+
version: '0'
|
138
|
+
type: :runtime
|
139
|
+
prerelease: false
|
140
|
+
version_requirements: !ruby/object:Gem::Requirement
|
141
|
+
requirements:
|
142
|
+
- - ">="
|
143
|
+
- !ruby/object:Gem::Version
|
144
|
+
version: '0'
|
131
145
|
- !ruby/object:Gem::Dependency
|
132
146
|
name: sidekiq
|
133
147
|
requirement: !ruby/object:Gem::Requirement
|
@@ -184,7 +198,7 @@ dependencies:
|
|
184
198
|
- - ">="
|
185
199
|
- !ruby/object:Gem::Version
|
186
200
|
version: '0'
|
187
|
-
description:
|
201
|
+
description:
|
188
202
|
email:
|
189
203
|
- pseng@instructure.com
|
190
204
|
executables: []
|
@@ -206,7 +220,6 @@ files:
|
|
206
220
|
- app/lib/lti_xml/base_platform.rb
|
207
221
|
- app/lib/lti_xml/bridge_platform.rb
|
208
222
|
- app/lib/lti_xml/canvas_platform.rb
|
209
|
-
- app/lib/panda_pal/batch_processor.rb
|
210
223
|
- app/lib/panda_pal/launch_url_helpers.rb
|
211
224
|
- app/lib/panda_pal/lti_jwt_validator.rb
|
212
225
|
- app/lib/panda_pal/misc_helper.rb
|
@@ -222,6 +235,10 @@ files:
|
|
222
235
|
- config/dev_lti_key.key
|
223
236
|
- config/initializers/apartment.rb
|
224
237
|
- config/routes.rb
|
238
|
+
- db/618eef7c0380ba654ad16f867a919e72.sqlite3
|
239
|
+
- db/9ff93d4f7e0e9dc80a43f68997caf4a1.sqlite3
|
240
|
+
- db/a3fda4044a7215bc2c9eb01a4b9e517a.sqlite3
|
241
|
+
- db/daa0e6378a5ec76fcce83b7070dad219.sqlite3
|
225
242
|
- db/migrate/20160412205931_create_panda_pal_organizations.rb
|
226
243
|
- db/migrate/20160413135653_create_panda_pal_sessions.rb
|
227
244
|
- db/migrate/20160425130344_add_panda_pal_organization_to_session.rb
|
@@ -268,7 +285,9 @@ files:
|
|
268
285
|
- spec/dummy/config/locales/en.yml
|
269
286
|
- spec/dummy/config/routes.rb
|
270
287
|
- spec/dummy/config/secrets.yml
|
288
|
+
- spec/dummy/db/development.sqlite3
|
271
289
|
- spec/dummy/db/schema.rb
|
290
|
+
- spec/dummy/db/test.sqlite3
|
272
291
|
- spec/dummy/log/development.log
|
273
292
|
- spec/dummy/log/test.log
|
274
293
|
- spec/dummy/public/404.html
|
@@ -287,7 +306,7 @@ homepage: http://instructure.com
|
|
287
306
|
licenses:
|
288
307
|
- MIT
|
289
308
|
metadata: {}
|
290
|
-
post_install_message:
|
309
|
+
post_install_message:
|
291
310
|
rdoc_options: []
|
292
311
|
require_paths:
|
293
312
|
- lib
|
@@ -298,12 +317,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
298
317
|
version: '0'
|
299
318
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
300
319
|
requirements:
|
301
|
-
- - "
|
320
|
+
- - ">="
|
302
321
|
- !ruby/object:Gem::Version
|
303
|
-
version:
|
322
|
+
version: '0'
|
304
323
|
requirements: []
|
305
|
-
rubygems_version: 3.
|
306
|
-
signing_key:
|
324
|
+
rubygems_version: 3.1.2
|
325
|
+
signing_key:
|
307
326
|
specification_version: 4
|
308
327
|
summary: LTI mountable engine
|
309
328
|
test_files:
|
@@ -341,6 +360,8 @@ test_files:
|
|
341
360
|
- spec/dummy/public/500.html
|
342
361
|
- spec/dummy/public/404.html
|
343
362
|
- spec/dummy/db/schema.rb
|
363
|
+
- spec/dummy/db/test.sqlite3
|
364
|
+
- spec/dummy/db/development.sqlite3
|
344
365
|
- spec/dummy/log/test.log
|
345
366
|
- spec/dummy/log/development.log
|
346
367
|
- spec/dummy/README.rdoc
|
@@ -1,41 +0,0 @@
|
|
1
|
-
module PandaPal
|
2
|
-
# An array that "processes" after so many items are added.
|
3
|
-
#
|
4
|
-
# Example Usage:
|
5
|
-
# batches = BatchProcessor.new(of: 1000) do |batch|
|
6
|
-
# # Process the batch somehow
|
7
|
-
# end
|
8
|
-
# enumerator_of_some_kind.each { |item| batches << item }
|
9
|
-
# batches.flush
|
10
|
-
class BatchProcessor
|
11
|
-
attr_reader :batch_size
|
12
|
-
|
13
|
-
def initialize(of: 1000, &blk)
|
14
|
-
@batch_size = of
|
15
|
-
@block = blk
|
16
|
-
@current_batch = []
|
17
|
-
end
|
18
|
-
|
19
|
-
def <<(item)
|
20
|
-
@current_batch << item
|
21
|
-
process_batch if @current_batch.count >= batch_size
|
22
|
-
end
|
23
|
-
|
24
|
-
def add_all(items)
|
25
|
-
items.each do |i|
|
26
|
-
self << i
|
27
|
-
end
|
28
|
-
end
|
29
|
-
|
30
|
-
def flush
|
31
|
-
process_batch if @current_batch.present?
|
32
|
-
end
|
33
|
-
|
34
|
-
protected
|
35
|
-
|
36
|
-
def process_batch
|
37
|
-
@block.call(@current_batch)
|
38
|
-
@current_batch = []
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|