csv_rb 6.0.2.3 → 6.0.2.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 +4 -4
- data/Gemfile.lock +67 -67
- data/README.md +22 -15
- data/lib/csv_rb/action_controller.rb +2 -2
- data/lib/csv_rb/plain_builder.rb +2 -2
- data/lib/csv_rb/version.rb +1 -1
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/log/development.log +9 -212
- data/spec/dummy/log/test.log +948 -30711
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d112f367b8a220ad62f1e08602738d076397b09293766bbf137f49fefc5a56d2
|
|
4
|
+
data.tar.gz: f5a104efd835934d6821b02b3b93448f8b193ec4aa418f6b44361657e0fc535b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: be9e03edd2c293811753c1764936d3eb75d1acff04be6ac6bef95b03104baaca86ea061485f0945295a3894b3d599779c047f4a1f25c43d215fce5e45b1ca27f
|
|
7
|
+
data.tar.gz: bdc8986b74c2b43dd982023f89f5a6141a7d86edbfe7460b096d33baddd3259e105ca1df0283fd9061c7481a46f878a18cb97874fe04f2541bde40e3d3d4a45e
|
data/Gemfile.lock
CHANGED
|
@@ -1,63 +1,63 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
csv_rb (6.0.2.
|
|
4
|
+
csv_rb (6.0.2.4)
|
|
5
5
|
actionpack (>= 5.2)
|
|
6
6
|
csv (>= 3.1.0)
|
|
7
7
|
|
|
8
8
|
GEM
|
|
9
9
|
remote: http://rubygems.org/
|
|
10
10
|
specs:
|
|
11
|
-
actioncable (6.0.2.
|
|
12
|
-
actionpack (= 6.0.2.
|
|
11
|
+
actioncable (6.0.2.2)
|
|
12
|
+
actionpack (= 6.0.2.2)
|
|
13
13
|
nio4r (~> 2.0)
|
|
14
14
|
websocket-driver (>= 0.6.1)
|
|
15
|
-
actionmailbox (6.0.2.
|
|
16
|
-
actionpack (= 6.0.2.
|
|
17
|
-
activejob (= 6.0.2.
|
|
18
|
-
activerecord (= 6.0.2.
|
|
19
|
-
activestorage (= 6.0.2.
|
|
20
|
-
activesupport (= 6.0.2.
|
|
15
|
+
actionmailbox (6.0.2.2)
|
|
16
|
+
actionpack (= 6.0.2.2)
|
|
17
|
+
activejob (= 6.0.2.2)
|
|
18
|
+
activerecord (= 6.0.2.2)
|
|
19
|
+
activestorage (= 6.0.2.2)
|
|
20
|
+
activesupport (= 6.0.2.2)
|
|
21
21
|
mail (>= 2.7.1)
|
|
22
|
-
actionmailer (6.0.2.
|
|
23
|
-
actionpack (= 6.0.2.
|
|
24
|
-
actionview (= 6.0.2.
|
|
25
|
-
activejob (= 6.0.2.
|
|
22
|
+
actionmailer (6.0.2.2)
|
|
23
|
+
actionpack (= 6.0.2.2)
|
|
24
|
+
actionview (= 6.0.2.2)
|
|
25
|
+
activejob (= 6.0.2.2)
|
|
26
26
|
mail (~> 2.5, >= 2.5.4)
|
|
27
27
|
rails-dom-testing (~> 2.0)
|
|
28
|
-
actionpack (6.0.2.
|
|
29
|
-
actionview (= 6.0.2.
|
|
30
|
-
activesupport (= 6.0.2.
|
|
28
|
+
actionpack (6.0.2.2)
|
|
29
|
+
actionview (= 6.0.2.2)
|
|
30
|
+
activesupport (= 6.0.2.2)
|
|
31
31
|
rack (~> 2.0, >= 2.0.8)
|
|
32
32
|
rack-test (>= 0.6.3)
|
|
33
33
|
rails-dom-testing (~> 2.0)
|
|
34
34
|
rails-html-sanitizer (~> 1.0, >= 1.2.0)
|
|
35
|
-
actiontext (6.0.2.
|
|
36
|
-
actionpack (= 6.0.2.
|
|
37
|
-
activerecord (= 6.0.2.
|
|
38
|
-
activestorage (= 6.0.2.
|
|
39
|
-
activesupport (= 6.0.2.
|
|
35
|
+
actiontext (6.0.2.2)
|
|
36
|
+
actionpack (= 6.0.2.2)
|
|
37
|
+
activerecord (= 6.0.2.2)
|
|
38
|
+
activestorage (= 6.0.2.2)
|
|
39
|
+
activesupport (= 6.0.2.2)
|
|
40
40
|
nokogiri (>= 1.8.5)
|
|
41
|
-
actionview (6.0.2.
|
|
42
|
-
activesupport (= 6.0.2.
|
|
41
|
+
actionview (6.0.2.2)
|
|
42
|
+
activesupport (= 6.0.2.2)
|
|
43
43
|
builder (~> 3.1)
|
|
44
44
|
erubi (~> 1.4)
|
|
45
45
|
rails-dom-testing (~> 2.0)
|
|
46
46
|
rails-html-sanitizer (~> 1.1, >= 1.2.0)
|
|
47
|
-
activejob (6.0.2.
|
|
48
|
-
activesupport (= 6.0.2.
|
|
47
|
+
activejob (6.0.2.2)
|
|
48
|
+
activesupport (= 6.0.2.2)
|
|
49
49
|
globalid (>= 0.3.6)
|
|
50
|
-
activemodel (6.0.2.
|
|
51
|
-
activesupport (= 6.0.2.
|
|
52
|
-
activerecord (6.0.2.
|
|
53
|
-
activemodel (= 6.0.2.
|
|
54
|
-
activesupport (= 6.0.2.
|
|
55
|
-
activestorage (6.0.2.
|
|
56
|
-
actionpack (= 6.0.2.
|
|
57
|
-
activejob (= 6.0.2.
|
|
58
|
-
activerecord (= 6.0.2.
|
|
50
|
+
activemodel (6.0.2.2)
|
|
51
|
+
activesupport (= 6.0.2.2)
|
|
52
|
+
activerecord (6.0.2.2)
|
|
53
|
+
activemodel (= 6.0.2.2)
|
|
54
|
+
activesupport (= 6.0.2.2)
|
|
55
|
+
activestorage (6.0.2.2)
|
|
56
|
+
actionpack (= 6.0.2.2)
|
|
57
|
+
activejob (= 6.0.2.2)
|
|
58
|
+
activerecord (= 6.0.2.2)
|
|
59
59
|
marcel (~> 0.3.1)
|
|
60
|
-
activesupport (6.0.2.
|
|
60
|
+
activesupport (6.0.2.2)
|
|
61
61
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
62
62
|
i18n (>= 0.7, < 2)
|
|
63
63
|
minitest (~> 5.1)
|
|
@@ -93,7 +93,7 @@ GEM
|
|
|
93
93
|
globalid (0.4.2)
|
|
94
94
|
activesupport (>= 4.2.0)
|
|
95
95
|
growl (1.0.3)
|
|
96
|
-
guard (2.16.
|
|
96
|
+
guard (2.16.2)
|
|
97
97
|
formatador (>= 0.2.4)
|
|
98
98
|
listen (>= 2.7, < 4.0)
|
|
99
99
|
lumberjack (>= 1.0.12, < 2.0)
|
|
@@ -117,7 +117,7 @@ GEM
|
|
|
117
117
|
listen (3.2.1)
|
|
118
118
|
rb-fsevent (~> 0.10, >= 0.10.3)
|
|
119
119
|
rb-inotify (~> 0.9, >= 0.9.10)
|
|
120
|
-
loofah (2.
|
|
120
|
+
loofah (2.5.0)
|
|
121
121
|
crass (~> 1.0.2)
|
|
122
122
|
nokogiri (>= 1.5.9)
|
|
123
123
|
lumberjack (1.2.4)
|
|
@@ -132,7 +132,7 @@ GEM
|
|
|
132
132
|
minitest (5.14.0)
|
|
133
133
|
nenv (0.3.0)
|
|
134
134
|
nio4r (2.5.2)
|
|
135
|
-
nokogiri (1.10.
|
|
135
|
+
nokogiri (1.10.9)
|
|
136
136
|
mini_portile2 (~> 2.4.0)
|
|
137
137
|
notiffany (0.1.3)
|
|
138
138
|
nenv (~> 0.1)
|
|
@@ -142,33 +142,33 @@ GEM
|
|
|
142
142
|
method_source (~> 0.9.0)
|
|
143
143
|
pry-nav (0.3.0)
|
|
144
144
|
pry (>= 0.9.10, < 0.13.0)
|
|
145
|
-
public_suffix (4.0.
|
|
145
|
+
public_suffix (4.0.4)
|
|
146
146
|
rack (2.2.2)
|
|
147
147
|
rack-test (1.1.0)
|
|
148
148
|
rack (>= 1.0, < 3)
|
|
149
|
-
rails (6.0.2.
|
|
150
|
-
actioncable (= 6.0.2.
|
|
151
|
-
actionmailbox (= 6.0.2.
|
|
152
|
-
actionmailer (= 6.0.2.
|
|
153
|
-
actionpack (= 6.0.2.
|
|
154
|
-
actiontext (= 6.0.2.
|
|
155
|
-
actionview (= 6.0.2.
|
|
156
|
-
activejob (= 6.0.2.
|
|
157
|
-
activemodel (= 6.0.2.
|
|
158
|
-
activerecord (= 6.0.2.
|
|
159
|
-
activestorage (= 6.0.2.
|
|
160
|
-
activesupport (= 6.0.2.
|
|
149
|
+
rails (6.0.2.2)
|
|
150
|
+
actioncable (= 6.0.2.2)
|
|
151
|
+
actionmailbox (= 6.0.2.2)
|
|
152
|
+
actionmailer (= 6.0.2.2)
|
|
153
|
+
actionpack (= 6.0.2.2)
|
|
154
|
+
actiontext (= 6.0.2.2)
|
|
155
|
+
actionview (= 6.0.2.2)
|
|
156
|
+
activejob (= 6.0.2.2)
|
|
157
|
+
activemodel (= 6.0.2.2)
|
|
158
|
+
activerecord (= 6.0.2.2)
|
|
159
|
+
activestorage (= 6.0.2.2)
|
|
160
|
+
activesupport (= 6.0.2.2)
|
|
161
161
|
bundler (>= 1.3.0)
|
|
162
|
-
railties (= 6.0.2.
|
|
162
|
+
railties (= 6.0.2.2)
|
|
163
163
|
sprockets-rails (>= 2.0.0)
|
|
164
164
|
rails-dom-testing (2.0.3)
|
|
165
165
|
activesupport (>= 4.2.0)
|
|
166
166
|
nokogiri (>= 1.6)
|
|
167
167
|
rails-html-sanitizer (1.3.0)
|
|
168
168
|
loofah (~> 2.3)
|
|
169
|
-
railties (6.0.2.
|
|
170
|
-
actionpack (= 6.0.2.
|
|
171
|
-
activesupport (= 6.0.2.
|
|
169
|
+
railties (6.0.2.2)
|
|
170
|
+
actionpack (= 6.0.2.2)
|
|
171
|
+
activesupport (= 6.0.2.2)
|
|
172
172
|
method_source
|
|
173
173
|
rake (>= 0.8.7)
|
|
174
174
|
thor (>= 0.20.3, < 2.0)
|
|
@@ -189,22 +189,22 @@ GEM
|
|
|
189
189
|
rspec-mocks (~> 3.9.0)
|
|
190
190
|
rspec-core (3.9.1)
|
|
191
191
|
rspec-support (~> 3.9.1)
|
|
192
|
-
rspec-expectations (3.9.
|
|
192
|
+
rspec-expectations (3.9.1)
|
|
193
193
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
194
194
|
rspec-support (~> 3.9.0)
|
|
195
195
|
rspec-mocks (3.9.1)
|
|
196
196
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
197
197
|
rspec-support (~> 3.9.0)
|
|
198
|
-
rspec-rails (
|
|
199
|
-
actionpack (>=
|
|
200
|
-
activesupport (>=
|
|
201
|
-
railties (>=
|
|
202
|
-
rspec-core (~> 3.9
|
|
203
|
-
rspec-expectations (~> 3.9
|
|
204
|
-
rspec-mocks (~> 3.9
|
|
205
|
-
rspec-support (~> 3.9
|
|
198
|
+
rspec-rails (4.0.0)
|
|
199
|
+
actionpack (>= 4.2)
|
|
200
|
+
activesupport (>= 4.2)
|
|
201
|
+
railties (>= 4.2)
|
|
202
|
+
rspec-core (~> 3.9)
|
|
203
|
+
rspec-expectations (~> 3.9)
|
|
204
|
+
rspec-mocks (~> 3.9)
|
|
205
|
+
rspec-support (~> 3.9)
|
|
206
206
|
rspec-support (3.9.2)
|
|
207
|
-
rubyzip (2.
|
|
207
|
+
rubyzip (2.3.0)
|
|
208
208
|
shellany (0.0.1)
|
|
209
209
|
simplecov (0.16.1)
|
|
210
210
|
docile (~> 1.1)
|
|
@@ -230,14 +230,14 @@ GEM
|
|
|
230
230
|
thread_safe (0.3.6)
|
|
231
231
|
tins (1.24.1)
|
|
232
232
|
sync
|
|
233
|
-
tzinfo (1.2.
|
|
233
|
+
tzinfo (1.2.7)
|
|
234
234
|
thread_safe (~> 0.1)
|
|
235
235
|
websocket-driver (0.7.1)
|
|
236
236
|
websocket-extensions (>= 0.1.0)
|
|
237
237
|
websocket-extensions (0.1.4)
|
|
238
238
|
xpath (3.2.0)
|
|
239
239
|
nokogiri (~> 1.8)
|
|
240
|
-
zeitwerk (2.
|
|
240
|
+
zeitwerk (2.3.0)
|
|
241
241
|
|
|
242
242
|
PLATFORMS
|
|
243
243
|
ruby
|
data/README.md
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
|
-
CSVRb-Rails — Streaming CSVs with
|
|
1
|
+
CSVRb-Rails — Streaming CSVs with ActionView templates
|
|
2
2
|
===================================================
|
|
3
3
|
|
|
4
|
-
[](http://badge.fury.io/rb/csv_rb)
|
|
6
|
-
[](http://badge.fury.io/rb/csv_rb)
|
|
8
5
|

|
|
9
|
-

|
|
10
7
|
|
|
11
8
|
## Installation
|
|
12
9
|
|
|
@@ -19,7 +16,15 @@ gem 'csv_rb'
|
|
|
19
16
|
|
|
20
17
|
## Requirements
|
|
21
18
|
|
|
22
|
-
* Rails 5.2
|
|
19
|
+
* \>= Rails 5.2
|
|
20
|
+
- Latest Version Tested With:
|
|
21
|
+
- 5.2
|
|
22
|
+
- 6.0
|
|
23
|
+
* \>= Ruby 2.5
|
|
24
|
+
- Latest Version Tested With:
|
|
25
|
+
- 2.6
|
|
26
|
+
- 2.7
|
|
27
|
+
|
|
23
28
|
|
|
24
29
|
## Usage
|
|
25
30
|
|
|
@@ -89,12 +94,12 @@ format.csv {
|
|
|
89
94
|
}
|
|
90
95
|
```
|
|
91
96
|
|
|
92
|
-
If you use `render csv:` the gem will try to guess the file name
|
|
97
|
+
If you use `render csv:` the gem will try to guess the file name based on the `:csv` key value
|
|
93
98
|
|
|
94
99
|
```ruby
|
|
95
|
-
# filename of 'buttons'
|
|
100
|
+
# filename of 'buttons.csv'
|
|
96
101
|
render csv: 'buttons'
|
|
97
|
-
# filename of 'latest_buttons'
|
|
102
|
+
# filename of 'latest_buttons.csv'
|
|
98
103
|
render csv: 'latest_buttons', template: 'featured/latest'
|
|
99
104
|
```
|
|
100
105
|
|
|
@@ -110,13 +115,15 @@ Partials work as expected, but you must pass in relevant spreadsheet variables:
|
|
|
110
115
|
|
|
111
116
|
```ruby
|
|
112
117
|
csv << ['BEFORE']
|
|
113
|
-
render :partial => '
|
|
118
|
+
render :partial => 'csv_partial', :locals => { csv: csv }
|
|
114
119
|
csv << ['AFTER']
|
|
115
120
|
```
|
|
116
121
|
|
|
117
122
|
With the partial simply using the passed variables:
|
|
118
123
|
|
|
119
124
|
```ruby
|
|
125
|
+
# _csv_partial.csv.csvrb
|
|
126
|
+
|
|
120
127
|
csv << ['Partial Content']
|
|
121
128
|
```
|
|
122
129
|
|
|
@@ -130,8 +137,8 @@ class UserMailer < ActionMailer::Base
|
|
|
130
137
|
csv = render_to_string layout: false, handlers: [:csvrb], formats: [:csv], template: "users/export", locals: {users: users}
|
|
131
138
|
attachment = Base64.encode64(csv)
|
|
132
139
|
attachments["Users.csv"] = {mime_type: Mime[:csv], content: attachment, encoding: 'base64'}
|
|
133
|
-
# For rails 4 use Mime::
|
|
134
|
-
# attachments["Users.csv"] = {mime_type: Mime::
|
|
140
|
+
# For rails 4 use Mime::CSV
|
|
141
|
+
# attachments["Users.csv"] = {mime_type: Mime::CSV, content: attachment, encoding: 'base64'}
|
|
135
142
|
# self.instance_variable_set(:@_lookup_context, nil) # If attachments are rendered as content, try this and open an issue
|
|
136
143
|
...
|
|
137
144
|
end
|
|
@@ -139,8 +146,8 @@ end
|
|
|
139
146
|
```
|
|
140
147
|
|
|
141
148
|
* If the route specifies or suggests the `:csv` format you do not need to specify `formats` or `handlers`.
|
|
142
|
-
* If the template (`users/export`) can refer to only one file (
|
|
143
|
-
* Specifying the encoding as 'base64' can avoid UTF-8 errors.
|
|
149
|
+
* If the template (`users/export` in this case) can refer to only one file (`users/export.csv.csvrb`), you do not need to specify `handlers`, provided the `formats` key includes `:csv`.
|
|
150
|
+
* Specifying the encoding as 'base64' can help avoid UTF-8 errors.
|
|
144
151
|
|
|
145
152
|
### Testing
|
|
146
153
|
|
|
@@ -61,9 +61,9 @@ else
|
|
|
61
61
|
def to_csv
|
|
62
62
|
@_action_has_layout = false
|
|
63
63
|
if @default_response
|
|
64
|
-
@default_response.call(options)
|
|
64
|
+
@default_response.call(**options)
|
|
65
65
|
else
|
|
66
|
-
controller.render
|
|
66
|
+
controller.render csv: controller.action_name, **options
|
|
67
67
|
end
|
|
68
68
|
end
|
|
69
69
|
end
|
data/lib/csv_rb/plain_builder.rb
CHANGED
|
@@ -3,7 +3,7 @@ require 'csv_rb/stream_builder'
|
|
|
3
3
|
module CSVRb
|
|
4
4
|
class PlainBuilder < StreamBuilder
|
|
5
5
|
def initialize(*)
|
|
6
|
-
super("
|
|
6
|
+
super(+"", false)
|
|
7
7
|
end
|
|
8
8
|
|
|
9
9
|
def value
|
|
@@ -11,7 +11,7 @@ module CSVRb
|
|
|
11
11
|
end
|
|
12
12
|
|
|
13
13
|
def set(complete_value)
|
|
14
|
-
@enumerator = complete_value || "
|
|
14
|
+
@enumerator = complete_value || +""
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
def close
|
data/lib/csv_rb/version.rb
CHANGED
|
Binary file
|
data/spec/dummy/db/test.sqlite3
CHANGED
|
Binary file
|
|
@@ -12,73 +12,25 @@ for all models and all boolean columns, after which the flag must be set to
|
|
|
12
12
|
true by adding the following to your application.rb file:
|
|
13
13
|
|
|
14
14
|
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
15
|
-
(called from
|
|
16
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
17
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
18
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
19
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
20
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
21
|
-
by setting up a rake task which runs
|
|
22
|
-
|
|
23
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
24
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
25
|
-
|
|
26
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
27
|
-
true by adding the following to your application.rb file:
|
|
28
|
-
|
|
29
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
30
|
-
(called from load at /home/samps/.gem/ruby/2.6.0/bin/rake:23)
|
|
15
|
+
(called from require at bin/rails:4)
|
|
31
16
|
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
|
|
32
17
|
[1m[35m (4.0ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
|
|
33
|
-
[1m[35m (3.
|
|
34
|
-
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
35
|
-
Migrating to CreateUsers (20120717192452)
|
|
36
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
37
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
38
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
39
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
40
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
41
|
-
by setting up a rake task which runs
|
|
42
|
-
|
|
43
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
44
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
45
|
-
|
|
46
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
47
|
-
true by adding the following to your application.rb file:
|
|
48
|
-
|
|
49
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
50
|
-
(called from load at /home/samps/.gem/ruby/2.6.0/bin/rake:23)
|
|
51
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
52
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
53
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
54
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
55
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
56
|
-
by setting up a rake task which runs
|
|
57
|
-
|
|
58
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
59
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
60
|
-
|
|
61
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
62
|
-
true by adding the following to your application.rb file:
|
|
63
|
-
|
|
64
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
65
|
-
(called from load at /home/samps/.gem/ruby/2.6.0/bin/rake:23)
|
|
18
|
+
[1m[35m (3.5ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
66
19
|
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
67
20
|
Migrating to CreateUsers (20120717192452)
|
|
68
21
|
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
69
|
-
[1m[35m (0.1ms)[0m [1m[
|
|
70
|
-
[1m[35m (0.2ms)[0m [1m[35mCREATE TABLE "users" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "last_name" varchar, "address" varchar, "email" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
22
|
+
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "users" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "last_name" varchar, "address" varchar, "email" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
71
23
|
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20120717192452"]]
|
|
72
|
-
[1m[35m (
|
|
24
|
+
[1m[35m (3.5ms)[0m [1m[36mcommit transaction[0m
|
|
73
25
|
Migrating to CreateLikes (20121206210955)
|
|
74
26
|
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
75
27
|
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "likes" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "user_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
76
28
|
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20121206210955"]]
|
|
77
|
-
[1m[35m (
|
|
29
|
+
[1m[35m (3.7ms)[0m [1m[36mcommit transaction[0m
|
|
78
30
|
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
|
79
31
|
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
80
|
-
[1m[36mActiveRecord::InternalMetadata Create (0.1ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "development"], ["created_at", "2019-
|
|
81
|
-
[1m[35m (2.
|
|
32
|
+
[1m[36mActiveRecord::InternalMetadata Create (0.1ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "development"], ["created_at", "2019-07-02 21:51:45.974537"], ["updated_at", "2019-07-02 21:51:45.974537"]]
|
|
33
|
+
[1m[35m (2.4ms)[0m [1m[36mcommit transaction[0m
|
|
82
34
|
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
83
35
|
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
84
36
|
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
@@ -95,163 +47,8 @@ true by adding the following to your application.rb file:
|
|
|
95
47
|
|
|
96
48
|
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
97
49
|
(called from load at /home/samps/.gem/ruby/2.6.0/bin/rake:23)
|
|
98
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
99
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
100
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
101
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
102
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
103
|
-
by setting up a rake task which runs
|
|
104
|
-
|
|
105
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
106
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
107
|
-
|
|
108
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
109
|
-
true by adding the following to your application.rb file:
|
|
110
|
-
|
|
111
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
112
|
-
(called from load at /home/samps/.gem/ruby/2.6.0/bin/rake:23)
|
|
113
|
-
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
|
|
114
|
-
[1m[35m (4.0ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
|
|
115
|
-
[1m[35m (2.2ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
116
50
|
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
117
|
-
Migrating to CreateUsers (20120717192452)
|
|
118
|
-
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
119
|
-
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "users" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "last_name" varchar, "address" varchar, "email" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
120
|
-
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20120717192452"]]
|
|
121
|
-
[1m[35m (2.2ms)[0m [1m[36mcommit transaction[0m
|
|
122
|
-
Migrating to CreateLikes (20121206210955)
|
|
123
|
-
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
124
|
-
[1m[35m (0.2ms)[0m [1m[35mCREATE TABLE "likes" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "user_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
125
|
-
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20121206210955"]]
|
|
126
|
-
[1m[35m (2.5ms)[0m [1m[36mcommit transaction[0m
|
|
127
51
|
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
|
128
52
|
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
129
|
-
[1m[
|
|
130
|
-
[1m[35m (
|
|
131
|
-
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
132
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
133
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
134
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
135
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
136
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
137
|
-
by setting up a rake task which runs
|
|
138
|
-
|
|
139
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
140
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
141
|
-
|
|
142
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
143
|
-
true by adding the following to your application.rb file:
|
|
144
|
-
|
|
145
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
146
|
-
(called from require at bin/rails:4)
|
|
147
|
-
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
|
|
148
|
-
[1m[35m (6.6ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
|
|
149
|
-
[1m[35m (2.5ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
150
|
-
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
151
|
-
Migrating to CreateUsers (20120717192452)
|
|
152
|
-
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
153
|
-
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "users" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "last_name" varchar, "address" varchar, "email" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
154
|
-
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20120717192452"]]
|
|
155
|
-
[1m[35m (2.1ms)[0m [1m[36mcommit transaction[0m
|
|
156
|
-
Migrating to CreateLikes (20121206210955)
|
|
157
|
-
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
158
|
-
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "likes" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "user_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
|
159
|
-
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20121206210955"]]
|
|
160
|
-
[1m[35m (2.3ms)[0m [1m[36mcommit transaction[0m
|
|
161
|
-
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
|
162
|
-
[1m[35m (0.0ms)[0m [1m[36mbegin transaction[0m
|
|
163
|
-
[1m[36mActiveRecord::InternalMetadata Create (0.1ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "development"], ["created_at", "2019-06-06 23:08:42.659439"], ["updated_at", "2019-06-06 23:08:42.659439"]]
|
|
164
|
-
[1m[35m (1.8ms)[0m [1m[36mcommit transaction[0m
|
|
165
|
-
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
166
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
167
|
-
DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /home/samps/gems/csv_rb/spec/dummy/config/environment.rb:5)
|
|
168
|
-
DEPRECATION WARNING: Leaving `ActiveRecord::ConnectionAdapters::SQLite3Adapter.represent_boolean_as_integer`
|
|
169
|
-
set to false is deprecated. SQLite databases have used 't' and 'f' to serialize
|
|
170
|
-
boolean values and must have old data converted to 1 and 0 (its native boolean
|
|
171
|
-
serialization) before setting this flag to true. Conversion can be accomplished
|
|
172
|
-
by setting up a rake task which runs
|
|
173
|
-
|
|
174
|
-
ExampleModel.where("boolean_column = 't'").update_all(boolean_column: 1)
|
|
175
|
-
ExampleModel.where("boolean_column = 'f'").update_all(boolean_column: 0)
|
|
176
|
-
|
|
177
|
-
for all models and all boolean columns, after which the flag must be set to
|
|
178
|
-
true by adding the following to your application.rb file:
|
|
179
|
-
|
|
180
|
-
Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
|
|
181
|
-
(called from require at bin/rails:4)
|
|
182
|
-
Started GET "/" for ::1 at 2019-06-06 17:08:57 -0600
|
|
183
|
-
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
|
184
|
-
Processing by HomeController#index as HTML
|
|
185
|
-
Rendering home/index.html.erb within layouts/application
|
|
186
|
-
Rendered home/index.html.erb within layouts/application (0.6ms)
|
|
187
|
-
Completed 200 OK in 12ms (Views: 11.7ms | ActiveRecord: 0.0ms)
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
Started GET "/another.csv" for ::1 at 2019-06-06 17:08:59 -0600
|
|
191
|
-
Processing by HomeController#another as CSV
|
|
192
|
-
Completed 200 OK in 1ms (Views: 0.3ms | ActiveRecord: 0.0ms)
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
Started GET "/another" for ::1 at 2019-06-06 17:09:12 -0600
|
|
196
|
-
Processing by HomeController#another as HTML
|
|
197
|
-
Completed 200 OK in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
Started GET "/only_html" for ::1 at 2019-06-06 17:10:05 -0600
|
|
201
|
-
|
|
202
|
-
ActionController::RoutingError (No route matches [GET] "/only_html"):
|
|
203
|
-
|
|
204
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/debug_exceptions.rb:65:in `call'
|
|
205
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/show_exceptions.rb:33:in `call'
|
|
206
|
-
railties (5.2.3) lib/rails/rack/logger.rb:38:in `call_app'
|
|
207
|
-
railties (5.2.3) lib/rails/rack/logger.rb:26:in `block in call'
|
|
208
|
-
activesupport (5.2.3) lib/active_support/tagged_logging.rb:71:in `block in tagged'
|
|
209
|
-
activesupport (5.2.3) lib/active_support/tagged_logging.rb:28:in `tagged'
|
|
210
|
-
activesupport (5.2.3) lib/active_support/tagged_logging.rb:71:in `tagged'
|
|
211
|
-
railties (5.2.3) lib/rails/rack/logger.rb:26:in `call'
|
|
212
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/remote_ip.rb:81:in `call'
|
|
213
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/request_id.rb:27:in `call'
|
|
214
|
-
rack (2.0.7) lib/rack/method_override.rb:22:in `call'
|
|
215
|
-
rack (2.0.7) lib/rack/runtime.rb:22:in `call'
|
|
216
|
-
activesupport (5.2.3) lib/active_support/cache/strategy/local_cache_middleware.rb:29:in `call'
|
|
217
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/executor.rb:14:in `call'
|
|
218
|
-
actionpack (5.2.3) lib/action_dispatch/middleware/static.rb:127:in `call'
|
|
219
|
-
rack (2.0.7) lib/rack/sendfile.rb:111:in `call'
|
|
220
|
-
railties (5.2.3) lib/rails/engine.rb:524:in `call'
|
|
221
|
-
thin (1.7.2) lib/thin/connection.rb:86:in `block in pre_process'
|
|
222
|
-
thin (1.7.2) lib/thin/connection.rb:84:in `catch'
|
|
223
|
-
thin (1.7.2) lib/thin/connection.rb:84:in `pre_process'
|
|
224
|
-
thin (1.7.2) lib/thin/connection.rb:53:in `process'
|
|
225
|
-
thin (1.7.2) lib/thin/connection.rb:39:in `receive_data'
|
|
226
|
-
eventmachine (1.2.7) lib/eventmachine.rb:195:in `run_machine'
|
|
227
|
-
eventmachine (1.2.7) lib/eventmachine.rb:195:in `run'
|
|
228
|
-
thin (1.7.2) lib/thin/backends/base.rb:73:in `start'
|
|
229
|
-
thin (1.7.2) lib/thin/server.rb:162:in `start'
|
|
230
|
-
rack (2.0.7) lib/rack/handler/thin.rb:22:in `run'
|
|
231
|
-
rack (2.0.7) lib/rack/server.rb:297:in `start'
|
|
232
|
-
railties (5.2.3) lib/rails/commands/server/server_command.rb:53:in `start'
|
|
233
|
-
railties (5.2.3) lib/rails/commands/server/server_command.rb:147:in `block in perform'
|
|
234
|
-
railties (5.2.3) lib/rails/commands/server/server_command.rb:142:in `tap'
|
|
235
|
-
railties (5.2.3) lib/rails/commands/server/server_command.rb:142:in `perform'
|
|
236
|
-
thor (0.20.3) lib/thor/command.rb:27:in `run'
|
|
237
|
-
thor (0.20.3) lib/thor/invocation.rb:126:in `invoke_command'
|
|
238
|
-
thor (0.20.3) lib/thor.rb:387:in `dispatch'
|
|
239
|
-
railties (5.2.3) lib/rails/command/base.rb:65:in `perform'
|
|
240
|
-
railties (5.2.3) lib/rails/command.rb:46:in `invoke'
|
|
241
|
-
railties (5.2.3) lib/rails/commands.rb:18:in `<top (required)>'
|
|
242
|
-
bin/rails:4:in `require'
|
|
243
|
-
bin/rails:4:in `<main>'
|
|
244
|
-
Started GET "/home/only_html" for ::1 at 2019-06-06 17:10:19 -0600
|
|
245
|
-
Processing by HomeController#only_html as HTML
|
|
246
|
-
Rendering home/only_html.html.erb within layouts/application
|
|
247
|
-
Rendered home/only_html.html.erb within layouts/application (0.1ms)
|
|
248
|
-
Completed 200 OK in 1ms (Views: 0.9ms | ActiveRecord: 0.0ms)
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
Started GET "/home/only_html" for ::1 at 2019-06-06 17:10:44 -0600
|
|
252
|
-
Processing by HomeController#only_html as HTML
|
|
253
|
-
Rendering home/only_html.html.erb within layouts/application
|
|
254
|
-
Rendered home/only_html.html.erb within layouts/application (0.1ms)
|
|
255
|
-
Completed 200 OK in 2ms (Views: 1.2ms | ActiveRecord: 0.0ms)
|
|
256
|
-
|
|
257
|
-
|
|
53
|
+
[1m[35m (0.0ms)[0m [1m[36mcommit transaction[0m
|
|
54
|
+
[1m[35m (0.0ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|