ecoportal-api 0.9.7 → 0.10.1
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/.markdownlint.json +4 -0
- data/.rubocop.yml +55 -15
- data/.ruby-version +1 -0
- data/CHANGELOG.md +224 -171
- data/Rakefile +18 -7
- data/ecoportal-api.gemspec +7 -7
- data/lib/ecoportal/api/common/base_model.rb +36 -25
- data/lib/ecoportal/api/common/batch_operation.rb +18 -15
- data/lib/ecoportal/api/common/batch_response.rb +2 -5
- data/lib/ecoportal/api/common/client.rb +57 -22
- data/lib/ecoportal/api/common/response.rb +6 -6
- data/lib/ecoportal/api/common/wrapped_response.rb +14 -19
- data/lib/ecoportal/api/internal/account.rb +11 -10
- data/lib/ecoportal/api/internal.rb +5 -5
- data/lib/ecoportal/api/logger.rb +11 -9
- data/lib/ecoportal/api/v1/people.rb +59 -21
- data/lib/ecoportal/api/v1/person.rb +16 -13
- data/lib/ecoportal/api/v1/person_details.rb +10 -9
- data/lib/ecoportal/api/v1/person_schema.rb +1 -1
- data/lib/ecoportal/api/v1/person_schemas.rb +0 -2
- data/lib/ecoportal/api/v1/schema_field.rb +4 -5
- data/lib/ecoportal/api/v1/schema_field_value.rb +23 -24
- data/lib/ecoportal/api/v1.rb +4 -3
- data/lib/ecoportal/api/version.rb +1 -1
- metadata +23 -46
data/CHANGELOG.md
CHANGED
@@ -1,295 +1,348 @@
|
|
1
1
|
# Change Log
|
2
|
+
|
2
3
|
All notable changes to this project will be documented in this file.
|
3
4
|
|
4
|
-
## [0.
|
5
|
+
## [0.10.1] - 2024-08-01
|
5
6
|
|
6
7
|
### Added
|
8
|
+
|
9
|
+
- `Ecoportal::V1::Person#brand_id`
|
10
|
+
- `Ecoportal::V1::Person#archived`
|
11
|
+
|
7
12
|
### Changed
|
8
|
-
|
9
|
-
|
13
|
+
|
14
|
+
- require `ruby 3`
|
10
15
|
|
11
16
|
### Fixed
|
12
17
|
|
18
|
+
## [0.9.8] - 2024-05-15
|
19
|
+
|
20
|
+
### Added
|
21
|
+
|
22
|
+
- `rubocop`
|
23
|
+
|
24
|
+
### Changed
|
25
|
+
|
26
|
+
- `Ecoportal::API::Common::Client#with_retry`
|
27
|
+
- Make resilient (**re-try**) to recent silent server errors where the body doesn't parse as JSON.
|
28
|
+
|
29
|
+
### Fixed
|
30
|
+
|
31
|
+
## [0.9.7] - 2024-02-03
|
32
|
+
|
33
|
+
### Changed
|
34
|
+
|
35
|
+
- `Ecoportal::API::V1::Person`
|
36
|
+
- **removed** property `subordinates`
|
37
|
+
|
13
38
|
## [0.9.6] - 2024-02-03
|
14
39
|
|
15
40
|
### Changed
|
16
|
-
|
41
|
+
|
42
|
+
- upgraded some gems
|
17
43
|
|
18
44
|
### Fixed
|
19
|
-
|
20
|
-
|
45
|
+
|
46
|
+
- Compatibility with `ruby 3`
|
47
|
+
- replaced `Proc.new` (with no block) by `block` in methods
|
21
48
|
|
22
49
|
## [0.9.5] - 2023-09-05
|
23
50
|
|
24
51
|
### Fixed
|
25
|
-
|
52
|
+
|
53
|
+
- `Ecoportal::API::V1::Person#as_update` missing parameter on `super` call.
|
26
54
|
|
27
55
|
## [0.9.4] - 2023-04-17
|
28
56
|
|
29
57
|
### Changed
|
30
|
-
|
31
|
-
|
58
|
+
|
59
|
+
- Softened max version of **gem** dependencies
|
60
|
+
- Upgraded required ruby version
|
32
61
|
|
33
62
|
### Fixed
|
34
|
-
|
35
|
-
|
63
|
+
|
64
|
+
- `Ecoportal::API::Common::BaseModel` should make a copy of `doc` on `initialize`
|
65
|
+
- This was affecting `reset!` as `doc` was being changed
|
36
66
|
|
37
67
|
## [0.9.3] - 2023-03-16
|
38
68
|
|
39
69
|
### Added
|
40
|
-
|
70
|
+
|
71
|
+
- `Ecoportal::API::V1::SchemaFieldValue#clear` helper to clear the value
|
41
72
|
|
42
73
|
## [0.9.1] - 2023-03-09
|
43
74
|
|
44
75
|
### Added
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
- `
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
-
|
54
|
-
|
55
|
-
|
76
|
+
|
77
|
+
- `Ecoportal::API::V1::Person#contractor_organization_id` support for contractor management
|
78
|
+
- `Ecoportal::API::Common::BaseModel` **added** `doc` helper methods:
|
79
|
+
- `replace_doc!` and `#replace_original_doc!`
|
80
|
+
- `Ecoportal::API::Internal::Person` **added** methods
|
81
|
+
- **breaking change**, they default to compare with `original_doc`, while they did it with `initial_doc`)
|
82
|
+
- `#new?` => to know if this person is being created now (it doesn't exist on **server side**).
|
83
|
+
- `#account_added?` => to know if this person is getting the account added.
|
84
|
+
- `#account_removed?` => to know if this person is getting their account removed.
|
85
|
+
- `Ecoportal::API::Common::Client#host` expose
|
86
|
+
- `Ecoportal::API::Internal::Permissions` added abilities
|
87
|
+
- `contractor_management`
|
56
88
|
|
57
89
|
### Fixed
|
58
|
-
|
90
|
+
|
91
|
+
- `Ecoportal::API::V1::PersonDetails.key?` should index first.
|
59
92
|
|
60
93
|
### Changed
|
61
|
-
|
94
|
+
|
95
|
+
- `Ecoportal::API::V1::Person::VALID_TAG_REGEX` allow dot `.` in tags.
|
62
96
|
|
63
97
|
## [0.8.5] - 2022-02-28
|
64
98
|
|
65
99
|
### Added
|
66
|
-
|
67
|
-
|
68
|
-
|
100
|
+
|
101
|
+
- `Ecoportal::API::V1::PersonDetails#[]` to raise a specific error type to allow handling
|
102
|
+
- `Ecoportal::API::V1::PersonDetails.key?` to allow to check if a field exists
|
103
|
+
- `Ecoportal::API::Internal::Account#force_send_invites` support for back-end new method
|
69
104
|
|
70
105
|
### Fixed
|
71
|
-
|
72
|
-
|
106
|
+
|
107
|
+
- `Ecoportal::API::V1::People#get` fixed typo
|
108
|
+
- `Ecoportal::API::Common::BaseModel` `#original_doc` and `#initial_doc` maybe empty for the parent object
|
73
109
|
|
74
110
|
### Changed
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
111
|
+
|
112
|
+
- `Ecoportal::API::V1::People#each` limited the `GET` retries to `5`
|
113
|
+
- `Ecoportal::API::Internal::Account#default_tag=`
|
114
|
+
- Controls input type to be `String` or `nil`
|
115
|
+
- Inherent `upcase`
|
79
116
|
|
80
117
|
## [0.8.4] - 2021-11-05
|
81
118
|
|
82
119
|
### Added
|
83
|
-
|
84
|
-
|
85
|
-
-
|
86
|
-
|
87
|
-
|
120
|
+
|
121
|
+
- `Ecoportal::API::Internal::Permissions` added abilities
|
122
|
+
- `visitor_management`, `cross_register_reporting` and `broadcast_notifications`
|
123
|
+
- Some yardocs too
|
124
|
+
- Some callbacks are done in a non-obvious way and the returned object type was not documented
|
125
|
+
- For this reason, some yardocs have been added to some of the parts that have been worked on.
|
88
126
|
|
89
127
|
### Fixed
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
-
|
95
|
-
-
|
96
|
-
|
97
|
-
|
128
|
+
|
129
|
+
- `Ecoportal::API::V1::People#create_job`
|
130
|
+
- **Removed** call to `BatchOperation#process_response`
|
131
|
+
- The method was is already called by `job_result`
|
132
|
+
- As a consequence there was a double up of `callbacks`
|
133
|
+
- **Fixed** line in wrong position
|
134
|
+
- `Ecoportal::API::V1::People#batch`
|
135
|
+
- `Ecoportal::API::Common::ElasticApmIntegration#unexpected_server_error?`
|
136
|
+
- No code or code lesser than 100 is a server error as well
|
98
137
|
|
99
138
|
### Changed
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
139
|
+
|
140
|
+
- `Ecoportal::API::Common::Client`: changed
|
141
|
+
- Logging the **response** of batches or batch jobs can be handy when debugging the back-end
|
142
|
+
- **removed** method `#without_response_logging`
|
143
|
+
- This change entailed to remove dependencies in `Ecoportal::API::V1::People`
|
144
|
+
- Specifically in methods `#batch`, `#job_result` and `#create_job`
|
145
|
+
- `@response_logging_enabled` to be set in initialization stage (added parameter for `.new`)
|
106
146
|
|
107
147
|
## [0.8.3] - 2021-05-24
|
108
148
|
|
109
149
|
### Added
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
150
|
+
|
151
|
+
- `Ecoportal::API::Errors` namespace
|
152
|
+
- `Ecoportal::API::Errors::Base` base error class.
|
153
|
+
- `Ecoportal::API::Errors::TimeOut` error when an api request fails with time out.
|
154
|
+
- This serves the purpose to allow a client script to re-start the process where it stopped by capturing this specific Error
|
155
|
+
- `Ecoportal::API::Common::BaseModel::UnlinkedModel` added more description to track down the source of the error.
|
156
|
+
- `Ecoportal::API::Common::BaseModel#reset!` added parameter `key`, which should try to recover `doc[key]` from `original_doc[key]`
|
157
|
+
- Thanks to this, you are supposed to be able to do things like:
|
158
|
+
- `person.account = nil && person.reset!("account")`
|
159
|
+
- `person.name = nil && person.reset!("name")`
|
160
|
+
- `Ecoportal::API::V1::People#job` methods to provide more information on failure.
|
161
|
+
- Specific changes due to eP **release `1.5.9.70`** (_Policy Group Abilities_)
|
162
|
+
- `Ecoportal::API::Internal::Account#permissions_merged`
|
163
|
+
- `Ecoportal::API::Internal::Permissions#person_abilities` (new ability)
|
164
|
+
- `Ecoportal::API::Internal::Account#user_id`
|
124
165
|
|
125
166
|
### Fixed
|
126
|
-
|
127
|
-
|
128
|
-
-
|
129
|
-
|
167
|
+
|
168
|
+
- `Ecoportal::API::Internal::Account`: consistency in setting arrays (`uniq!` & `compact`)
|
169
|
+
- `#policy_group_ids=`, `#login_provider_ids=`, `#starred_ids=`
|
170
|
+
- `Ecoportal::API::Common::HashDiff.diff` was including empty `{}` objects
|
171
|
+
- This change sacrifices the case `account: {}` (which will be also removed from `as_update`), but it should be fine.
|
130
172
|
|
131
173
|
### Changed
|
132
|
-
- `Ecoportal::API::V1::People#job` to raise specific error on time out `API::Errors::TimeOut`
|
133
|
-
- Specific changes due to eP **release `1.5.9.70`** (_Policy Group Abilities_)
|
134
|
-
- `Ecoportal::API::Internal::Account` **removed** methods: `#permissions_preset`, `#preset` and `#preset=`
|
135
|
-
- `Ecoportal::API::Internal::Person#account=` added support for `user_id` which should remain unchanged when existing
|
136
|
-
- **remove** from `as_update` **read-only** data
|
137
|
-
- `Ecoportal::API::Common::HashDiff.diff` added parameter `:ignore` (`Array`)
|
138
|
-
- `Ecoportal::API::Common::BaseModel#as_update` added parameter `:ignore`
|
139
|
-
- `Ecoportal::API::V1::Person#as_update` added method, which ignores `subordinates`
|
140
|
-
- `Ecoportal::API::Internal::Person#as_update` added method, which ignores `user_id`, `permissions_merged` and `prefilter`
|
141
|
-
- `Ecoportal::API::Internal::Account#as_update` added method, which ignores `user_id`, `permissions_merged` and `prefilter`
|
142
|
-
- `Ecoportal::API::Common::Client` native support for `elastic-apm`
|
143
|
-
- Via new module `Ecoportal::API::Common::ElasticApmIntegration` with method `log_unexpected_server_error`, which will only log an `UnexpectedServerError` to _ElasticAPM_ if
|
144
|
-
1. There's a correct configuration: environmental variables `ELASTIC_APM_KEY` and `ELASTIC_APM_ACCOUNT_ID` are defined
|
145
|
-
2. The `Response` from the server gave `code` in the range `5xx` (which are those under server responsibility)
|
146
|
-
- `Ecoportal::API::Common::Client` added retry logics when `response.status == 5xx`
|
147
174
|
|
148
|
-
|
175
|
+
- `Ecoportal::API::V1::People#job` to raise specific error on time out `API::Errors::TimeOut`
|
176
|
+
- Specific changes due to eP **release `1.5.9.70`** (_Policy Group Abilities_)
|
177
|
+
- `Ecoportal::API::Internal::Account` **removed** methods: `#permissions_preset`, `#preset` and `#preset=`
|
178
|
+
- `Ecoportal::API::Internal::Person#account=` added support for `user_id` which should remain unchanged when existing
|
179
|
+
- **remove** from `as_update` **read-only** data
|
180
|
+
- `Ecoportal::API::Common::HashDiff.diff` added parameter `:ignore` (`Array`)
|
181
|
+
- `Ecoportal::API::Common::BaseModel#as_update` added parameter `:ignore`
|
182
|
+
- `Ecoportal::API::V1::Person#as_update` added method, which ignores `subordinates`
|
183
|
+
- `Ecoportal::API::Internal::Person#as_update` added method, which ignores `user_id`, `permissions_merged` and `prefilter`
|
184
|
+
- `Ecoportal::API::Internal::Account#as_update` added method, which ignores `user_id`, `permissions_merged` and `prefilter`
|
185
|
+
- `Ecoportal::API::Common::Client` native support for `elastic-apm`
|
186
|
+
- Via new module `Ecoportal::API::Common::ElasticApmIntegration` with method `log_unexpected_server_error`, which will only log an `UnexpectedServerError` to _ElasticAPM_ if
|
187
|
+
1. There's a correct configuration: environmental variables `ELASTIC_APM_KEY` and `ELASTIC_APM_ACCOUNT_ID` are defined
|
188
|
+
2. The `Response` from the server gave `code` in the range `5xx` (which are those under server responsibility)
|
189
|
+
- `Ecoportal::API::Common::Client` added retry logics when `response.status == 5xx`
|
149
190
|
|
150
|
-
|
191
|
+
## [0.8.2] - 2021-02-24
|
151
192
|
|
152
193
|
### Fixed
|
153
|
-
|
194
|
+
|
195
|
+
- `Ecoportal::API::V1::Person#filter_tags=` should ignore `nil` values
|
154
196
|
|
155
197
|
### Changed
|
156
|
-
- removed all the namespace under `Ecoportal::API::V2` as that is managed by `ecoportal-api-oozes` gem
|
157
|
-
- url: https://rubygems.org/gems/ecoportal-api-oozes
|
158
|
-
- `Ecoportal::API::V1::People.get` should return a `Person` object
|
159
|
-
- observe that it was returning the `WrappedResponse` (an `Enumerable` helper that works better when getting multiple people).
|
160
198
|
|
161
|
-
|
199
|
+
- removed all the namespace under `Ecoportal::API::V2` as that is managed by `ecoportal-api-oozes` gem
|
200
|
+
- url: <https://rubygems.org/gems/ecoportal-api-oozes>
|
201
|
+
- `Ecoportal::API::V1::People.get` should return a `Person` object
|
202
|
+
- observe that it was returning the `WrappedResponse` (an `Enumerable` helper that works better when getting multiple people).
|
162
203
|
|
163
|
-
|
204
|
+
## [0.7.5] - 2021-02-12
|
164
205
|
|
165
206
|
### Fixed
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
207
|
+
|
208
|
+
- `pretty_print` method was colliding with `pp` module:
|
209
|
+
- renamed to `Ecoportal::API::Common::BaseModel#print_pretty`
|
210
|
+
- renamed to `Ecoportal::API::Common::BatchReponse#print_pretty`
|
211
|
+
- renamed to `Ecoportal::API::Common::Reponse#print_pretty`
|
212
|
+
- renamed to `Ecoportal::API::Common::WrappedResponse#print_pretty`
|
171
213
|
|
172
214
|
### Changed
|
173
|
-
- forgot to change `Ecoportal::API::VERSION` during last release
|
174
215
|
|
175
|
-
|
216
|
+
- forgot to change `Ecoportal::API::VERSION` during last release
|
176
217
|
|
177
|
-
|
218
|
+
## [0.7.4] - 2021-01-2
|
178
219
|
|
179
220
|
### Fixed
|
180
|
-
- changed `compact` to `compact!`:
|
181
|
-
- `Ecoportal::API::V1::Person#filter_tags=`
|
182
|
-
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
183
|
-
- `Ecoportal::API::Internal::Account#login_provider_ids=`
|
184
|
-
- `Ecoportal::API::Internal::Account#starred_ids=`
|
185
221
|
|
186
|
-
|
222
|
+
- changed `compact` to `compact!`:
|
223
|
+
- `Ecoportal::API::V1::Person#filter_tags=`
|
224
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
225
|
+
- `Ecoportal::API::Internal::Account#login_provider_ids=`
|
226
|
+
- `Ecoportal::API::Internal::Account#starred_ids=`
|
187
227
|
|
188
|
-
|
228
|
+
### Changed
|
189
229
|
|
190
230
|
### Added
|
191
231
|
|
192
232
|
### Fixed
|
193
|
-
- `Ecoportal::API::V1::Person#email=`: was not showing the incorrect value in the error message
|
194
|
-
- added `compact` to remove `null` values on:
|
195
|
-
- `Ecoportal::API::V1::Person#filter_tags=`
|
196
|
-
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
197
|
-
- `Ecoportal::API::Internal::Account#login_provider_ids=`
|
198
|
-
- `Ecoportal::API::Internal::Account#starred_ids=`
|
199
|
-
|
200
|
-
### Changed
|
201
233
|
|
234
|
+
- `Ecoportal::API::V1::Person#email=`: was not showing the incorrect value in the error message
|
235
|
+
- added `compact` to remove `null` values on:
|
236
|
+
- `Ecoportal::API::V1::Person#filter_tags=`
|
237
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
238
|
+
- `Ecoportal::API::Internal::Account#login_provider_ids=`
|
239
|
+
- `Ecoportal::API::Internal::Account#starred_ids=`
|
202
240
|
|
203
241
|
## [0.7.2] - 2020-10-19
|
204
242
|
|
205
243
|
### Added
|
206
|
-
|
207
|
-
|
208
|
-
|
244
|
+
|
245
|
+
- `Ecoportal::API::V1::Person#email=`:
|
246
|
+
- do a minimum validation (no blanks in the email)
|
247
|
+
- set in lower case (as this is how it's in the server)
|
248
|
+
|
209
249
|
### Fixed
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
250
|
+
|
251
|
+
- `Ecoportal::API::V1::People#each`: when `silent` it shouldn't print a blank line
|
252
|
+
- fixed so they return empty array `[]` when `nil`:
|
253
|
+
- `Ecoportal::API::V1::Person#filter_tags`
|
254
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids`
|
255
|
+
- `Ecoportal::API::Internal::Account#login_provider_ids`
|
256
|
+
- `Ecoportal::API::Internal::Account#starred_ids`
|
257
|
+
|
216
258
|
### Changed
|
217
|
-
- made it so some methods the `Array` with `uniq` values:
|
218
|
-
- `Ecoportal::API::V1::Person#filter_tags=`
|
219
|
-
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
220
|
-
- made it so it only updates the keys defined in the `Hash` passed to the setter:
|
221
|
-
- `Ecoportal::API::Internal::Account#permissions_custom=`
|
222
|
-
- `Ecoportal::API::Internal::Account#preferences=`
|
223
259
|
|
260
|
+
- made it so some methods the `Array` with `uniq` values:
|
261
|
+
- `Ecoportal::API::V1::Person#filter_tags=`
|
262
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids=`
|
263
|
+
- made it so it only updates the keys defined in the `Hash` passed to the setter:
|
264
|
+
- `Ecoportal::API::Internal::Account#permissions_custom=`
|
265
|
+
- `Ecoportal::API::Internal::Account#preferences=`
|
224
266
|
|
225
267
|
## [0.7.1] - 2020-09-30
|
226
268
|
|
227
269
|
### Added
|
228
|
-
|
229
|
-
|
270
|
+
|
271
|
+
- `Ecoportal::API::Internal::Permissions`: **update for new ability `tasks` of ecoPortal release `1.5.3`**
|
272
|
+
- `Ecoportal::API::V1::People#each`: added keyword argument `silent:` to display download progress
|
273
|
+
|
230
274
|
### Fixed
|
231
|
-
|
275
|
+
|
276
|
+
- `Ecoportal::API::V1::People#each`: when no block provided, it was creating an `Enumarator` without preserving the parameters (i.e. `:q` or `per_page` were lost)
|
232
277
|
|
233
278
|
## [0.7.0] - 2020-09-11
|
234
279
|
|
235
280
|
### Added
|
236
|
-
|
237
|
-
|
238
|
-
|
281
|
+
|
282
|
+
- added hook, **private** method `body_data` for child classes to define behaviour on `response.body` to
|
283
|
+
- `Ecoportal::API::V1::People`
|
284
|
+
- `Ecoportal::API::Common::BatchOperation`
|
239
285
|
|
240
286
|
### Changed
|
241
|
-
- `Ecoportal::API::Internal::Permissions`: **update for new abilities of ecoPortal release `1.5.2`**
|
242
|
-
- decoupled abilities: `person_core` into `person_core_create`, `person_core_edit`
|
243
|
-
### Fixed
|
244
287
|
|
288
|
+
- `Ecoportal::API::Internal::Permissions`: **update for new abilities of ecoPortal release `1.5.2`**
|
289
|
+
- decoupled abilities: `person_core` into `person_core_create`, `person_core_edit`
|
245
290
|
|
246
291
|
## [0.6.0] - 2020-07-14
|
247
292
|
|
248
293
|
### Added
|
249
|
-
|
250
|
-
|
251
|
-
-
|
252
|
-
|
294
|
+
|
295
|
+
- `Ecoportal::API::Common::BaseModel#initial_doc`: `#consolidate!` modifies `original_doc`
|
296
|
+
- this helper allows to know what was the initial document the object was created with
|
297
|
+
- `Ecoportal::API::Common::BaseModel#as_update`: added parameter (default: `:last` => compare with `original_doc`)
|
298
|
+
- calling it with `:total` will compare the current `doc` with the `initial_doc`
|
299
|
+
|
253
300
|
### Changed
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
301
|
+
|
302
|
+
- `Ecoportal::API::Internal::Permissions`: **update for new abilities of ecoPortal release `1.5.0`**
|
303
|
+
- added abilities: `person_core`, `person_account`, `person_details`
|
304
|
+
- removed ability: `people`
|
305
|
+
- renamed `print` to `pretty_print` to avoid overriding `$stdout.print`, on:
|
306
|
+
- `Ecoportal::API::Common::BaseModel`
|
307
|
+
- `Ecoportal::API::Common::BatchReponse`
|
308
|
+
- `Ecoportal::API::Common::Response`
|
309
|
+
- `Ecoportal::API::Common::WrappedResponse`
|
310
|
+
|
262
311
|
### Fixed
|
263
|
-
|
312
|
+
|
313
|
+
- `Ecoportal::API::Internal::Preferences`: **kiosk** settings should default to `false` (`nil`)
|
264
314
|
|
265
315
|
## [0.5.8] - 2020-06-23
|
266
316
|
|
267
|
-
### Added
|
268
|
-
### Changed
|
269
317
|
### Fixed
|
270
|
-
- `Ecoportal::API::V1::Person#filter_tags=`: `original_doc["filter_tags"]` is `nil` when creating a person
|
271
|
-
- `Ecoportal::API::Internal::Account#policy_group_ids=`: `original_doc["account"]` is `nil` when creating a person
|
272
318
|
|
319
|
+
- `Ecoportal::API::V1::Person#filter_tags=`: `original_doc["filter_tags"]` is `nil` when creating a person
|
320
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids=`: `original_doc["account"]` is `nil` when creating a person
|
273
321
|
|
274
322
|
## [0.5.7] - 2020-06-22
|
275
323
|
|
276
324
|
### Added
|
277
|
-
|
278
|
-
|
325
|
+
|
326
|
+
- `Ecoportal::API::V1::PersonSchema`: added `enable_tags` & `tags` properties
|
327
|
+
- `Ecoportal::API::Internal::Preferences`: added missing fields for **kiosk**
|
328
|
+
|
279
329
|
### Changed
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
-
|
284
|
-
|
330
|
+
|
331
|
+
- `Ecoportal::API::V1::People::JOB_TIMEOUT`: from 1 minute to 3 minutes
|
332
|
+
- `Ecoportal::API::V1::Person#filter_tags=`: will preserve the original order of the matching tags
|
333
|
+
- this change is to prevent `as_update` to generate false update positives
|
334
|
+
- `Ecoportal::API::Internal::Account#policy_group_ids=`: will preserve the original order of the matching ids
|
335
|
+
- this change is to prevent `as_update` to generate false update positives
|
336
|
+
|
285
337
|
### Fixed
|
286
|
-
- `Ecoportal::API::Internal::Preferences`: access `doc` using string keys (not with `symbol` keys)
|
287
338
|
|
339
|
+
- `Ecoportal::API::Internal::Preferences`: access `doc` using string keys (not with `symbol` keys)
|
288
340
|
|
289
341
|
## [0.5.6] - 2020-06-08
|
290
342
|
|
291
343
|
### Added
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
344
|
+
|
345
|
+
- this `CHANGELOG.md` file
|
346
|
+
- person model: `freemium` core property
|
347
|
+
|
348
|
+
|
data/Rakefile
CHANGED
@@ -1,7 +1,8 @@
|
|
1
|
-
require
|
2
|
-
require
|
3
|
-
require
|
4
|
-
require
|
1
|
+
require 'bundler/gem_tasks'
|
2
|
+
require 'rspec/core/rake_task'
|
3
|
+
require 'rubocop/rake_task'
|
4
|
+
require 'yard'
|
5
|
+
require 'redcarpet'
|
5
6
|
|
6
7
|
desc "run the specs"
|
7
8
|
RSpec::Core::RakeTask.new(:spec)
|
@@ -10,11 +11,18 @@ desc "run rspec showing backtrace"
|
|
10
11
|
RSpec::Core::RakeTask.new(:spec_trace) do |task|
|
11
12
|
task.rspec_opts = ['--backtrace']
|
12
13
|
end
|
14
|
+
task(rspec_trace: :spec_trace)
|
13
15
|
|
14
16
|
desc "run rspec stopping on first fail, and show backtrace"
|
15
17
|
RSpec::Core::RakeTask.new(:spec_fast) do |task|
|
16
18
|
task.rspec_opts = ['--fail-fast', '--backtrace']
|
17
19
|
end
|
20
|
+
task(rspec_fast: :spec_fast)
|
21
|
+
|
22
|
+
desc "run rubocop diaplying cop names"
|
23
|
+
RuboCop::RakeTask.new(:rubocop) do |t|
|
24
|
+
t.options = ['--display-cop-names']
|
25
|
+
end
|
18
26
|
|
19
27
|
# default task name is yard
|
20
28
|
desc "Yard: generate all the documentation"
|
@@ -22,6 +30,9 @@ YARD::Rake::YardocTask.new(:doc) do |t|
|
|
22
30
|
#t.files = ['lib/**/*.rb']
|
23
31
|
end
|
24
32
|
|
25
|
-
|
26
|
-
task :
|
27
|
-
|
33
|
+
desc "default task: runs rubocop and rspec"
|
34
|
+
task :default do
|
35
|
+
Rake::Task[:rubocop].invoke
|
36
|
+
ensure
|
37
|
+
Rake::Task[:spec].invoke
|
38
|
+
end
|
data/ecoportal-api.gemspec
CHANGED
@@ -1,5 +1,4 @@
|
|
1
|
-
|
2
|
-
lib = File.expand_path("../lib", __FILE__)
|
1
|
+
lib = File.expand_path('lib', __dir__)
|
3
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
3
|
require "ecoportal/api/version"
|
5
4
|
|
@@ -13,23 +12,24 @@ Gem::Specification.new do |spec|
|
|
13
12
|
spec.homepage = "https://www.ecoportal.com"
|
14
13
|
spec.licenses = %w[MIT]
|
15
14
|
|
16
|
-
spec.
|
15
|
+
spec.metadata['rubygems_mfa_required'] = 'true'
|
16
|
+
|
17
|
+
spec.required_ruby_version = '>= 3.2.2'
|
17
18
|
|
18
|
-
spec.files
|
19
|
+
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
19
20
|
f.match(%r{^(test|spec|features)/})
|
20
21
|
end
|
21
22
|
spec.bindir = "exe"
|
22
23
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
23
24
|
spec.require_paths = ["lib"]
|
24
25
|
|
25
|
-
spec.add_development_dependency "bundler", ">= 2.4.12", "< 3"
|
26
26
|
spec.add_development_dependency "rspec", ">= 3.12.0", "< 4"
|
27
27
|
spec.add_development_dependency "rake", ">= 13.1.0", "< 14"
|
28
28
|
spec.add_development_dependency "yard", ">= 0.9.34", "< 1"
|
29
29
|
spec.add_development_dependency "redcarpet", ">= 3.6.0", "< 4"
|
30
30
|
spec.add_development_dependency "pry" , "~> 0.14"
|
31
31
|
|
32
|
-
spec.add_dependency '
|
33
|
-
spec.add_dependency 'dotenv', '>= 2.8', "< 3"
|
32
|
+
spec.add_dependency 'dotenv', '~> 3'
|
34
33
|
spec.add_dependency 'elastic-apm', '>= 4.7', "< 5"
|
34
|
+
spec.add_dependency 'http', '~> 5.1', "< 6"
|
35
35
|
end
|