{"_id":"p-times","_rev":"9-981451879d63aa22a10f96722ccb3648","name":"p-times","description":"Run promise-returning & async functions a specific number of times concurrently","dist-tags":{"latest":"4.0.0"},"versions":{"1.0.0":{"name":"p-times","version":"1.0.0","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=4"},"scripts":{"test":"xo && ava"},"files":["index.js"],"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^1.0.0"},"devDependencies":{"ava":"*","xo":"*"},"xo":{"esnext":true},"gitHead":"3b9a40e2280dd2c6c5d8b372e26132861eb42e8a","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@1.0.0","_shasum":"5af304d2b946d18beffb1ed7559c78d9579fef82","_from":".","_npmVersion":"2.15.9","_nodeVersion":"4.6.0","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"shasum":"5af304d2b946d18beffb1ed7559c78d9579fef82","tarball":"https://registry.npmjs.org/p-times/-/p-times-1.0.0.tgz","integrity":"sha512-FuDhv7BzB/vHycRqtVbHUHlE9DqiYK4Z5NiFALfdny2hPi83azED3y2qJXt9QV0mODuSprswsaAWM2qYdUZ1/A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCWqVSlp1o7sQGQYqqY1dxRVDjjF24k35FI6KO7FZq9DgIgbOTGn2IwnPBwKLQuLNvBl8TUtX6YaSxN6fWVD65OHzk="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/p-times-1.0.0.tgz_1477146555524_0.9325916769448668"},"directories":{}},"1.0.1":{"name":"p-times","version":"1.0.1","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=4"},"scripts":{"test":"xo && ava"},"files":["index.js"],"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^1.0.0"},"devDependencies":{"ava":"*","xo":"*"},"xo":{"esnext":true},"gitHead":"cddd5955a6f20045b4cece1df74d350e55269c05","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@1.0.1","_shasum":"4421472f1cb246924a66ef30fc5c810190b89c19","_from":".","_npmVersion":"2.15.9","_nodeVersion":"4.6.1","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"shasum":"4421472f1cb246924a66ef30fc5c810190b89c19","tarball":"https://registry.npmjs.org/p-times/-/p-times-1.0.1.tgz","integrity":"sha512-iatk1njnem9n8UpPV10mtG8S/5fWxKmjUWpWn4GNZuHe/O+NP51dqMnd542sFonCohXU7pDyMaOMRenOsxjn6w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFhElpsma1H6fQGDKJixC1a/ZmSIRrY+/eFJDWcCjMk7AiEA+mA2Mmklu9mOrszj+dJjZQ6cRtD484BXgTIkwR7+ZWg="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/p-times-1.0.1.tgz_1477675301768_0.459802022902295"},"directories":{}},"2.0.0":{"name":"p-times","version":"2.0.0","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=8"},"scripts":{"test":"xo && ava && tsd-check"},"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^2.0.0"},"devDependencies":{"ava":"^1.3.1","tsd-check":"^0.4.0","xo":"^0.24.0"},"gitHead":"d11ce594849d989f1210882879629e49642b7bb0","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@2.0.0","_nodeVersion":"8.15.0","_npmVersion":"6.9.0","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-BQn4HKuy4TBbZPdUFGTKIbLPNRtmXq+GUm2avR80gultRFtQdiUjOKSOrTvefGfCTIQkhD6t9FvgUNNTEsXhpA==","shasum":"b2b74a45d635c0f8a3a9d80fd03b1b5a5fc9497f","tarball":"https://registry.npmjs.org/p-times/-/p-times-2.0.0.tgz","fileCount":5,"unpackedSize":4275,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcjTXGCRA9TVsSAnZWagAABekP/A6wExg5dRz6iFir1Pu8\nhC+peCNiOS5mN/5M+KQqM3JyzJQZB375aeWcYgDEn16/4zBmIkr9q2L2Ksj8\nrFdan0RCftY261R+SlrNKamk1GO6yxSQQSc43qHq57/DD+U4yATfHlwnVr6g\nmbMvF9w/1colBcD8IFyrImobfE49LwuJzOLtBaauI4NlQfkpvKVqNeIXn9rf\nIWl5Tvr9aFK/qqKVI0QKHasdtXtRPdJsnelMQ2rfSRsioj/6o/Z1wKcRlXQv\n2ABVYZYMyK6QMmMfb3HZBI6ur1N11Y4zb/xxLLNK1Zj6NLV+aXBt8ZOFPJuD\n4kS5/2MdBXBdY0KLffzF7Ag1csVtoojSCtvPwKUSYXFfd7IkuBc6BdFIQI3y\n4U2rkVwzqMmFqWKgRRsGdhuUuYvfJwdP+8h1U/vBgN4d5/piKnRdC7Zue6b0\nJz0Dn/eRk+htg0Lwc1KlspcIbFRcABqrwb+JiFI1166GTMfs6q5sQHmqCF8T\nfn7ehud4Har20rO3mctNC14Lv3Qh8yG4TA2+kW531c4wocLd8ZVtSBx5IxFP\nUNESEH6r8UGUhuJHzf7EiI2ZKsLRPAQZJXRR5f23gNhoBAp8G/rWxDo00hrM\nWGl7ROdWXWYBtzgnjpZi7v0wBI78vxkIxaJjzwUNWlL3J0Hw9gG/WCv6QGai\nxJHg\r\n=3zQQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCmSVrfUUs2G8QuQA4OMkweGXSYuFSClYA8m5k7cOZewwIgSSt3ntQxnwoc8ij3BrHmoEK1blFFX6tdDkz+E4vkrY4="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/p-times_2.0.0_1552758214017_0.47028456447260236"},"_hasShrinkwrap":false},"2.1.0":{"name":"p-times","version":"2.1.0","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=8"},"scripts":{"test":"xo && ava && tsd"},"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^2.0.0"},"devDependencies":{"ava":"^1.4.1","tsd":"^0.7.2","xo":"^0.24.0"},"gitHead":"781476004ffba1651362bb17b229d00295744243","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@2.1.0","_nodeVersion":"8.15.0","_npmVersion":"6.9.0","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-y23lF7HegeUyBTAxHNl6qYvwTy6S4d+BQcs+4CwgxXzc1v1Hsf7pyAqbDHMiYnjdL5Vcmr/oHc9l+nAu0Q+Hhg==","shasum":"b3e7f9159f916cacb6aae06d67c79451b0076c6c","tarball":"https://registry.npmjs.org/p-times/-/p-times-2.1.0.tgz","fileCount":5,"unpackedSize":4976,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcpEDDCRA9TVsSAnZWagAAgNYQAIuXqPvvNwI2ZpBQNMFR\nYri6klCLNJkvIVAqDfTpfTNZH6fckZ9ubH+Ygtofd9oLSgcSBmdBeC+cjBds\nSFNxCKnFRX9B27ZnUHdNuki7TcY/7xHcSdJH8dxcgs/EwYeRxByBDV+KJVoT\npcDV9JpFaM6DG6baw94JVJp46fbwaNsSEzP2XDRl7Yb9fZwtgCsq8T3FiNYC\nwOHNdXn29IKq+1KHGzbeyNEZ2NFmPKSPShsGEDPd5yHZ1VvG/tJBWu7GCJ5G\n0NFBr3MN9X/sdAbZ1qJUtXMHvszs6wYWjs+k4oF9xX756XppQkwR9e8NNjtj\nEX2G7Xv0eWAKz2GfxMCOKeyq1EGZ8Hnne243953QuTt1YGIjqXCc7/OKDwgP\nVc4qS6jijFCM4UiWCYTOFvnE9y/LK/GkC93dnLcZI5wpKIQ3PHqiQpgj+Cei\nWeoxx82yVGbPPQdJL7EbKusjOqodoERTiP65mJv2wUrHMJeaweGVyeAO0tk5\n1505B2QRlVEMJ+2Qos+Hw2b3EbZpgs6wWSLyl4wTqlxafwT/dg6vL3ONSTzo\n5ECViiQHHYEHsS7F5icYAo0ap1CvI0z46cWd4B7BTHH6e5STQTbd29SDtbv4\nN6RlIlNUbZDel1js52DDKi7GFUzd4BWPFmJDZpAWLsmaAp1MXWutH5HjzNdb\nf+sf\r\n=YGmg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICfZrbaU5KlzgSQSVhX2nKd3vq5Bvq5Jml1XfKcb6tDoAiEAvxmEZRyh4GHZ5nXxHeZwCfcaAybkYtNu4AUPsiWlKUk="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/p-times_2.1.0_1554268354634_0.9214061110480409"},"_hasShrinkwrap":false},"3.0.0":{"name":"p-times","version":"3.0.0","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"engines":{"node":">=10"},"scripts":{"test":"xo && ava && tsd"},"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^4.0.0"},"devDependencies":{"ava":"^1.4.1","tsd":"^0.7.2","xo":"^0.24.0"},"gitHead":"fb0b8801c09f9c6592a8ad3173919c7853985e4d","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@3.0.0","_nodeVersion":"10.20.1","_npmVersion":"6.14.4","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-/Z7mcs8Liie8E7IHI9SBtmkHVW/GjLroQ94ALoAMIG20mqFMuh56/3WYhtOTqX9ccRSOxgaCkFC94Bat1Ofskg==","shasum":"477ff51aa8cfe7edef4cfcd4bc7e0250b13b4183","tarball":"https://registry.npmjs.org/p-times/-/p-times-3.0.0.tgz","fileCount":5,"unpackedSize":5284,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeoxSoCRA9TVsSAnZWagAAG4UQAJeGcWwgS2dUE6nmw/p1\n97O7LmD4WQQ7fbOtiJK9c1NFXsdKPbOkBEP91HSsB8oDDk6wN3mvmCNfHCzC\n8HnazmFvyjfEDQf7rxOQp7iInbIaCeRXgOyYEuObcNmEcy9iizJHC8Y79pgj\nBgJU9gHyqEIhdpYJscoO8l+S3kN+iLcX5ua56uDs2nlXyJPn1DHNuNO0fxuN\nNIC894zQVtyZpSijDO4v8bJd96zT1DvAp2v5999BGpeqHJnwgTuSDrLhJuFN\ncu/eBrNwRCrDC5+XFWDilMVUTY03UGjiideBUQpjnda29U8UqIXEnqGj8y7T\nFWC04geoHsbUxVoNMWyRL8qUwIGBOV64EK+6vongvzizRo1HeL0AXKA8kWxW\nA+yRXTUm/iABbHUaU3kNhN/xxV0wNUSwB1xA6skDmKgPkBlRKoAvzVxlZoX/\n6V4HseM7fXT5krCl60FsWkReA5TGgMbBPwcZoNJXS1QWzl+GAVIZ3tDm1KQy\nfyL7S9WqEU0AqHciX1WxSaw84wVAvOyKE/NjOD6TvhHGA6mryWR6CU8LEQpM\n66TG2i7xD87BIyIu5RZzjTUAssaRNPeHSNBTQU4sKEdValoxV6uG0bxM5EHY\n2+AiHi6GsRINKZCSb/kMJ/NJhpGU04rNv+MwJEOWVYJG30fjBckjYc+YVsJk\nXSGq\r\n=Wsw9\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCoQykFQg96zSDZVJX5NHA7VZB5WtqkGAnNGRFzaP/A7wIgXbZF0CZB4tJyrV+z2x2wIkBxG+ZMPjIRD6xxbXNOqoo="}]},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/p-times_3.0.0_1587745960167_0.2208670983244465"},"_hasShrinkwrap":false},"4.0.0":{"name":"p-times","version":"4.0.0","description":"Run promise-returning & async functions a specific number of times concurrently","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"engines":{"node":">=12.20"},"type":"module","exports":"./index.js","scripts":{"test":"xo && ava && tsd"},"keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"dependencies":{"p-map":"^5.0.0"},"devDependencies":{"ava":"^3.15.0","tsd":"^0.16.0","xo":"^0.40.2"},"gitHead":"dde4be7dd7e3c098567a5c9b457cac5e50296eb3","bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"homepage":"https://github.com/sindresorhus/p-times#readme","_id":"p-times@4.0.0","_nodeVersion":"12.22.1","_npmVersion":"7.10.0","dist":{"integrity":"sha512-KqBkcxIZ2EZHHkt8lbNORmRofFLrLlHQh0ObFO3moOlrdN/v+sbJ2ssZspP5GN7E7zwvcqiqV0xnJydkQuoNyw==","shasum":"3586dff1fc1f1a0a9f4688a7c650c5cdb4b5f0cc","tarball":"https://registry.npmjs.org/p-times/-/p-times-4.0.0.tgz","fileCount":5,"unpackedSize":4661,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJguKd5CRA9TVsSAnZWagAAEdQP/jmOBvXqh1cmJa/lA7Hd\n5jIiRslfJd7OH0nt+fNyJdsu3czW6NtNNnhKEJUuzjxjmkOAnNXsK4SVelP2\nXizd/aQF5TOkooa+GdKU7FnaQU9bYuH2kW9j23ORC9dujtlOqql6rjKcVl+m\n4ibDI6MMpESiiyBPm4mwJMaIGCv+n4Jar4lOtPC8aW2CyUJ+Vqs8bLztRooI\nFmxnQt3gW+7J2ic29yBU/Gr6r2ajAapOE/UVZdQiXf2gEbxDVx/XNV2Ltbt7\nZO9nS4DpoSEg7AEkPq0vXGWieNwVgZ+gONWZFXulnCi/Br6KgeYd6RAR4fpR\nq2FYi0EJG2gCn9SIfSRtQF0ZkPF2reNE+ytSZAK3yw2cx/zgdP5yvfhSFeEQ\nSZV6/27jPOB3mByIFyKJ1mYx39B4J0K1EI/6FQz70OzrwktEnUgLmECw00zR\n6YuSpXg8OH3mYyu0Fn8s5/mU2oDzpou6yjYDC5d96osw3rQAy2uGQDTBGiRn\ng93eAORFKDBKvFLUH8iCr5aAVWLB9Fc2P99N0JVnNS5JGtQfrAJU6h0aJcEp\nnUgXoaxmwTZarK3ZQzFQGTzep3jSuNv/8n4Jo9ol3qWBKqgDOU3Gz1IZehqm\nfb0mx9SOxVrtw6NSA+qk8AS4gGfAX5QC8H/pTdMxjYlq9cbX8wbPFmaraYTu\nHUg3\r\n=ro72\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFf+b9Anl+RQ1bPsvyE/QlHvsHkYeeGAzlENibDTa0IdAiEA3K6Gibc+/BPvUAOo2Eotyos1ffteLX5n7O3LBv2bcr4="}]},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/p-times_4.0.0_1622714233659_0.18947810466383275"},"_hasShrinkwrap":false}},"readme":"# p-times\n\n> Run promise-returning & async functions a specific number of times concurrently\n\n## Install\n\n```\n$ npm install p-times\n```\n\n## Usage\n\n```js\nimport pTimes from 'p-times';\n\nconst result = await pTimes(5, index => createFixture(`🦄-${index + 1}`));\n\nconsole.log(`Created fixtures: ${result.join(' ')}`);\n//=> 'Created fixtures: 🦄-1 🦄-2 🦄-3 🦄-4 🦄-5'\n```\n\n## API\n\n### pTimes(count, mapper, options?)\n\nReturns a `Promise` that is fulfilled when all promises returned from `mapper` are fulfilled, or rejects if any of the promises reject. The fulfilled value is an `Array` of the fulfilled values returned from `mapper` in order.\n\n#### count\n\nType: `number`\n\nNumber of times to call `mapper`.\n\n#### mapper(index)\n\nType: `Function`\n\nExpected to return a `Promise` or value.\n\n#### options\n\nType: `object`\n\n##### concurrency\n\nType: `number`\\\nDefault: `Infinity`\\\nMinimum: `1`\n\nNumber of concurrently pending promises returned by `mapper`.\n\n##### stopOnError\n\nType: `boolean`\\\nDefault: `true`\n\nWhen set to `false`, instead of stopping when a promise rejects, it will wait for all the promises to settle and then reject with an [aggregated error](https://github.com/sindresorhus/aggregate-error) containing all the errors from the rejected promises.\n\n## Related\n\n- [p-forever](https://github.com/sindresorhus/p-forever) - Run promise-returning & async functions repeatedly until you end it\n- [p-map](https://github.com/sindresorhus/p-map) - Map over promises concurrently\n- [p-filter](https://github.com/sindresorhus/p-filter) - Filter promises concurrently\n- [More…](https://github.com/sindresorhus/promise-fun)\n","maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"time":{"modified":"2022-06-23T05:53:18.851Z","created":"2016-10-22T14:29:18.154Z","1.0.0":"2016-10-22T14:29:18.154Z","1.0.1":"2016-10-28T17:21:46.083Z","2.0.0":"2019-03-16T17:43:34.120Z","2.1.0":"2019-04-03T05:12:34.922Z","3.0.0":"2020-04-24T16:32:40.292Z","4.0.0":"2021-06-03T09:57:13.793Z"},"homepage":"https://github.com/sindresorhus/p-times#readme","keywords":["promise","times","number","count","loop","iterate","async","await","promises","concurrently","concurrency","parallel","bluebird"],"repository":{"type":"git","url":"git+https://github.com/sindresorhus/p-times.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"bugs":{"url":"https://github.com/sindresorhus/p-times/issues"},"license":"MIT","readmeFilename":"readme.md"}