Comments (4)
You are right. Only integers are working at the moment.
I'm going to work on fixing it!
from promise-throttle.
The initial implementation tried to resolve promises in such a way that it would eventually converge in the requestsPerSecond
value (roughly after 1 second). However this overcomplicates the code and forces to keep track of the time when a set of promises started.
I have simplified the code to just store the time when the last promise was started. This should fix this issue.
from promise-throttle.
Merged and published!
from promise-throttle.
Nice!! Works perfectly.
from promise-throttle.
Related Issues (19)
- An in-range update of eslint is breaking the build 🚨 HOT 20
- Error: Cannot find module 'ansi-styles' HOT 2
- another full throttle :) HOT 1
- Hey dude HOT 1
- An in-range update of sinon is breaking the build 🚨 HOT 6
- How to use it HOT 2
- Aborting requests throws a ReferenceError in node.js HOT 1
- Abort - takes time to reject pending promises HOT 1
- An in-range update of eslint is breaking the build 🚨 HOT 19
- An in-range update of sinon is breaking the build 🚨 HOT 7
- .addAll() should return a promise HOT 2
- An in-range update of coveralls is breaking the build 🚨 HOT 7
- Documentation is missing a bunch of functionality? HOT 2
- An in-range update of promise is breaking the build 🚨 HOT 1
- Wrong argument type in TypeScript declaration? HOT 3
- unexpected weight behaviour
- v1.1.2 is not released on npm HOT 1
- Undefined requestsPerSeconds gives an infinite loop
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from promise-throttle.