Security update to Drupal 8.4.6
[yaffs-website] / node_modules / grunt-uncss / node_modules / async / CHANGELOG.md
1 #v2.1.5
2 - Fix `auto` bug when function names collided with Array.prototype (#1358)
3 - Improve some error messages (#1349)
4 - Avoid stack overflow case in queue
5 - Fixed an issue in `some`, `every` and `find` where processing would continue after the result was determined.
6 - Cleanup implementations of `some`, `every` and `find` 
7
8 # v2.1.3
9 - Make bundle size smaller
10 - Create optimized hotpath for `filter` in array case.
11
12 # v2.1.2
13 - Fixed a stackoverflow bug with `detect`, `some`, `every` on large inputs (#1293).
14
15 # v2.1.0
16
17 - `retry` and `retryable` now support an optional `errorFilter` function that determines if the `task` should retry on the error (#1256, #1261)
18 - Optimized array iteration in `race`, `cargo`, `queue`, and `priorityQueue` (#1253)
19 - Added alias documentation to doc site (#1251, #1254)
20 - Added [BootStrap scrollspy](http://getbootstrap.com/javascript/#scrollspy) to docs to highlight in the sidebar the current method being viewed  (#1289, #1300)
21 - Various minor doc fixes (#1263, #1264, #1271, #1278, #1280, #1282, #1302)
22
23 # v2.0.1
24
25 - Significantly optimized all iteration based collection methods such as `each`, `map`, `filter`, etc (#1245, #1246, #1247).
26
27 # v2.0.0
28
29 Lots of changes here!
30
31 First and foremost, we have a slick new [site for docs](https://caolan.github.io/async/). Special thanks to [**@hargasinski**](https://github.com/hargasinski) for his work converting our old docs to `jsdoc` format and implementing the new website. Also huge ups to [**@ivanseidel**](https://github.com/ivanseidel) for designing our new logo. It was a long process for both of these tasks, but I think these changes turned out extraordinary well.
32
33 The biggest feature is modularization. You can now `require("async/series")` to only require the `series` function. Every Async library function is available this way. You still can `require("async")` to require the entire library, like you could do before.
34
35 We also provide Async as a collection of ES2015 modules. You can now `import {each} from 'async-es'` or `import waterfall from 'async-es/waterfall'`. If you are using only a few Async functions, and are using a ES bundler such as Rollup, this can significantly lower your build size.
36
37 Major thanks to [**@Kikobeats**](github.com/Kikobeats), [**@aearly**](github.com/aearly) and [**@megawac**](github.com/megawac) for doing the majority of the modularization work, as well as [**@jdalton**](github.com/jdalton) and [**@Rich-Harris**](github.com/Rich-Harris) for advisory work on the general modularization strategy.
38
39 Another one of the general themes of the 2.0 release is standardization of what an "async" function is. We are now more strictly following the node-style continuation passing style. That is, an async function is a function that:
40
41 1. Takes a variable number of arguments
42 2. The last argument is always a callback
43 3. The callback can accept any number of arguments
44 4. The first argument passed to the callback will be treated as an error result, if the argument is truthy
45 5. Any number of result arguments can be passed after the "error" argument
46 6. The callback is called once and exactly once, either on the same tick or later tick of the JavaScript event loop.
47
48 There were several cases where Async accepted some functions that did not strictly have these properties, most notably `auto`, `every`, `some`, and `filter`.
49
50 Another theme is performance. We have eliminated internal deferrals in all cases where they make sense. For example, in `waterfall` and `auto`, there was a `setImmediate` between each task -- these deferrals have been removed. A `setImmediate` call can add up to 1ms of delay. This might not seem like a lot, but it can add up if you are using many Async functions in the course of processing a HTTP request, for example. Nearly all asynchronous functions that do I/O already have some sort of deferral built in, so the extra deferral is unnecessary. The trade-off of this change is removing our built-in stack-overflow defense. Many synchronous callback calls in series can quickly overflow the JS call stack. If you do have a function that is sometimes synchronous (calling its callback on the same tick), and are running into stack overflows, wrap it with `async.ensureAsync()`.
51
52 Another big performance win has been re-implementing `queue`, `cargo`, and `priorityQueue` with [doubly linked lists](https://en.wikipedia.org/wiki/Doubly_linked_list) instead of arrays. This has lead to queues being an order of [magnitude faster on large sets of tasks](https://github.com/caolan/async/pull/1205).
53
54 ## New Features
55
56 - Async is now modularized. Individual functions can be `require()`d from the main package. (`require('async/auto')`) (#984, #996)
57 - Async is also available as a collection of ES2015 modules in the new `async-es` package. (`import {forEachSeries} from 'async-es'`) (#984, #996)
58 - Added `race`, analogous to `Promise.race()`. It will run an array of async tasks in parallel and will call its callback with the result of the first task to respond. (#568, #1038)
59 - Collection methods now accept ES2015 iterators.  Maps, Sets, and anything that implements the iterator spec can now be passed directly to `each`, `map`, `parallel`, etc.. (#579, #839, #1074)
60 - Added `mapValues`, for mapping over the properties of an object and returning an object with the same keys. (#1157, #1177)
61 - Added `timeout`, a wrapper for an async function that will make the task time-out after the specified time. (#1007, #1027)
62 - Added `reflect` and `reflectAll`, analagous to [`Promise.reflect()`](http://bluebirdjs.com/docs/api/reflect.html), a wrapper for async tasks that always succeeds, by gathering results and errors into an object.  (#942, #1012, #1095)
63 - `constant` supports dynamic arguments -- it will now always use its last argument as the callback. (#1016, #1052)
64 - `setImmediate` and `nextTick` now support arguments to partially apply to the deferred function, like the node-native versions do. (#940, #1053)
65 - `auto` now supports resolving cyclic dependencies using [Kahn's algorithm](https://en.wikipedia.org/wiki/Topological_sorting#Kahn.27s_algorithm) (#1140).
66 - Added `autoInject`, a relative of `auto` that automatically spreads a task's dependencies as arguments to the task function. (#608, #1055, #1099, #1100)
67 - You can now limit the concurrency of `auto` tasks. (#635, #637)
68 - Added `retryable`, a relative of `retry` that wraps an async function, making it retry when called. (#1058)
69 - `retry` now supports specifying a function that determines the next time interval, useful for exponential backoff, logging and other retry strategies. (#1161)
70 - `retry` will now pass all of the arguments the task function was resolved with to the callback (#1231).
71 - Added `q.unsaturated` -- callback called when a `queue`'s number of running workers falls below a threshold. (#868, #1030, #1033, #1034)
72 - Added `q.error` -- a callback called whenever a `queue` task calls its callback with an error. (#1170)
73 - `applyEach` and `applyEachSeries` now pass results to the final callback. (#1088)
74
75 ## Breaking changes
76
77 - Calling a callback more than once is considered an error, and an error will be thrown. This had an explicit breaking change in `waterfall`. If you were relying on this behavior, you should more accurately represent your control flow as an event emitter or stream. (#814, #815, #1048, #1050)
78 - `auto` task functions now always take the callback as the last argument. If a task has dependencies, the `results` object will be passed as the first argument. To migrate old task functions, wrap them with [`_.flip`](https://lodash.com/docs#flip) (#1036, #1042)
79 - Internal `setImmediate` calls have been refactored away. This may make existing flows vulnerable to stack overflows if you use many synchronous functions in series. Use `ensureAsync` to work around this. (#696, #704, #1049, #1050)
80 - `map` used to return an object when iterating over an object.  `map` now always returns an array, like in other libraries.  The previous object behavior has been split out into `mapValues`. (#1157, #1177)
81 - `filter`, `reject`, `some`, `every`, and related functions now expect an error as the first callback argument, rather than just a simple boolean. Pass `null` as the first argument, or use `fs.access` instead of `fs.exists`. (#118, #774, #1028, #1041)
82 - `{METHOD}` and `{METHOD}Series` are now implemented in terms of `{METHOD}Limit`. This is a major internal simplification, and is not expected to cause many problems, but it does subtly affect how functions execute internally. (#778, #847)
83 - `retry`'s callback is now optional. Previously, omitting the callback would partially apply the function, meaning it could be passed directly as a task to `series` or `auto`. The partially applied "control-flow" behavior has been separated out into `retryable`. (#1054, #1058)
84 - The test function for `whilst`, `until`, and `during` used to be passed non-error args from the iteratee function's callback, but this led to weirdness where the first call of the test function would be passed no args. We have made it so the test function is never passed extra arguments, and only the `doWhilst`, `doUntil`, and `doDuring` functions pass iteratee callback arguments to the test function (#1217, #1224)
85 - The `q.tasks` array has been renamed `q._tasks` and is now implemented as a doubly linked list (DLL). Any code that used to interact with this array will need to be updated to either use the provided helpers or support DLLs (#1205).
86 - The timing of the `q.saturated()` callback in a `queue` has been modified to better reflect when tasks pushed to the queue will start queueing. (#724, #1078)
87 - Removed `iterator` method in favour of [ES2015 iterator protocol](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Iterators_and_Generators ) which natively supports arrays (#1237)
88 - Dropped support for Component, Jam, SPM, and Volo (#1175, ##176)
89
90 ## Bug Fixes
91
92 - Improved handling of no dependency cases in `auto` & `autoInject` (#1147).
93 - Fixed a bug where the callback generated by `asyncify` with  `Promises` could resolve twice (#1197).
94 - Fixed several documented optional callbacks not actually being optional (#1223).
95
96 ## Other
97
98 - Added `someSeries` and `everySeries` for symmetry, as well as a complete set of `any`/`anyLimit`/`anySeries` and `all`/`/allLmit`/`allSeries` aliases.
99 - Added `find` as an alias for `detect. (as well as `findLimit` and `findSeries`).
100 - Various doc fixes (#1005, #1008, #1010, #1015, #1021, #1037, #1039, #1051, #1102, #1107, #1121, #1123, #1129, #1135, #1138, #1141, #1153, #1216, #1217, #1232, #1233, #1236, #1238)
101
102 Thank you [**@aearly**](github.com/aearly) and [**@megawac**](github.com/megawac) for taking the lead on version 2 of async.
103
104 ------------------------------------------
105
106 # v1.5.2
107 - Allow using `"constructor"` as an argument in `memoize` (#998)
108 - Give a better error messsage when `auto` dependency checking fails (#994)
109 - Various doc updates (#936, #956, #979, #1002)
110
111 # v1.5.1
112 - Fix issue with `pause` in `queue` with concurrency enabled (#946)
113 - `while` and `until` now pass the final result to callback (#963)
114 - `auto` will properly handle concurrency when there is no callback (#966)
115 - `auto` will no. properly stop execution when an error occurs (#988, #993)
116 - Various doc fixes (#971, #980)
117
118 # v1.5.0
119
120 - Added `transform`, analogous to [`_.transform`](http://lodash.com/docs#transform) (#892)
121 - `map` now returns an object when an object is passed in, rather than array with non-numeric keys. `map` will begin always returning an array with numeric indexes in the next major release. (#873)
122 - `auto` now accepts an optional `concurrency` argument to limit the number o. running tasks (#637)
123 - Added `queue#workersList()`, to retrieve the lis. of currently running tasks. (#891)
124 - Various code simplifications (#896, #904)
125 - Various doc fixes :scroll: (#890, #894, #903, #905, #912)
126
127 # v1.4.2
128
129 - Ensure coverage files don't get published on npm (#879)
130
131 # v1.4.1
132
133 - Add in overlooked `detectLimit` method (#866)
134 - Removed unnecessary files from npm releases (#861)
135 - Removed usage of a reserved word to prevent :boom: in older environments (#870)
136
137 # v1.4.0
138
139 - `asyncify` now supports promises (#840)
140 - Added `Limit` versions of `filter` and `reject` (#836)
141 - Add `Limit` versions of `detect`, `some` and `every` (#828, #829)
142 - `some`, `every` and `detect` now short circuit early (#828, #829)
143 - Improve detection of the global object (#804), enabling use in WebWorkers
144 - `whilst` now called with arguments from iterator (#823)
145 - `during` now gets called with arguments from iterator (#824)
146 - Code simplifications and optimizations aplenty ([diff](https://github.com/caolan/async/compare/v1.3.0...v1.4.0))
147
148
149 # v1.3.0
150
151 New Features:
152 - Added `constant`
153 - Added `asyncify`/`wrapSync` for making sync functions work with callbacks. (#671, #806)
154 - Added `during` and `doDuring`, which are like `whilst` with an async truth test. (#800)
155 - `retry` now accepts an `interval` parameter to specify a delay between retries. (#793)
156 - `async` should work better in Web Workers due to better `root` detection (#804)
157 - Callbacks are now optional in `whilst`, `doWhilst`, `until`, and `doUntil` (#642)
158 - Various internal updates (#786, #801, #802, #803)
159 - Various doc fixes (#790, #794)
160
161 Bug Fixes:
162 - `cargo` now exposes the `payload` size, and `cargo.payload` can be changed on the fly after the `cargo` is created. (#740, #744, #783)
163
164
165 # v1.2.1
166
167 Bug Fix:
168
169 - Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782)
170
171
172 # v1.2.0
173
174 New Features:
175
176 - Added `timesLimit` (#743)
177 - `concurrency` can be changed after initialization in `queue` by setting `q.concurrency`. The new concurrency will be reflected the next time a task is processed. (#747, #772)
178
179 Bug Fixes:
180
181 - Fixed a regression in `each` and family with empty arrays that have additional properties. (#775, #777)
182
183
184 # v1.1.1
185
186 Bug Fix:
187
188 - Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782)
189
190
191 # v1.1.0
192
193 New Features:
194
195 - `cargo` now supports all of the same methods and event callbacks as `queue`.
196 - Added `ensureAsync` - A wrapper that ensures an async function calls its callback on a later tick. (#769)
197 - Optimized `map`, `eachOf`, and `waterfall` families of functions
198 - Passing a `null` or `undefined` array to `map`, `each`, `parallel` and families will be treated as an empty array (#667).
199 - The callback is now optional for the composed results of `compose` and `seq`. (#618)
200 - Reduced file size by 4kb, (minified version by 1kb)
201 - Added code coverage through `nyc` and `coveralls` (#768)
202
203 Bug Fixes:
204
205 - `forever` will no longer stack overflow with a synchronous iterator (#622)
206 - `eachLimit` and other limit functions will stop iterating once an error occurs (#754)
207 - Always pass `null` in callbacks when there is no error (#439)
208 - Ensure proper conditions when calling `drain()` after pushing an empty data set to a queue (#668)
209 - `each` and family will properly handle an empty array (#578)
210 - `eachSeries` and family will finish if the underlying array is modified during execution (#557)
211 - `queue` will throw if a non-function is passed to `q.push()` (#593)
212 - Doc fixes (#629, #766)
213
214
215 # v1.0.0
216
217 No known breaking changes, we are simply complying with semver from here on out.
218
219 Changes:
220
221 - Start using a changelog!
222 - Add `forEachOf` for iterating over Objects (or to iterate Arrays with indexes available) (#168 #704 #321)
223 - Detect deadlocks in `auto` (#663)
224 - Better support for require.js (#527)
225 - Throw if queue created with concurrency `0` (#714)
226 - Fix unneeded iteration in `queue.resume()` (#758)
227 - Guard against timer mocking overriding `setImmediate` (#609 #611)
228 - Miscellaneous doc fixes (#542 #596 #615 #628 #631 #690 #729)
229 - Use single noop function internally (#546)
230 - Optimize internal `_each`, `_map` and `_keys` functions.