langchain/libs
blueoom c3ced4c6ce
core[patch]: use time.monotonic() instead time.time() in InMemoryRateLimiter
**Description:**

The get time point method in the _consume() method of
core.rate_limiters.InMemoryRateLimiter uses time.time(), which can be
affected by system time backwards. Therefore, it is recommended to use
the monotonically increasing monotonic() to obtain the time

```python
        with self._consume_lock:
            now = time.time()  # time.time() -> time.monotonic()

            # initialize on first call to avoid a burst
            if self.last is None:
                self.last = now

            elapsed = now - self.last  # when use time.time(), elapsed may be negative when system time backwards

```
2024-08-09 11:31:20 -04:00
..
cli docs: update integration api refs (#25195) 2024-08-09 12:27:32 +00:00
community community[patch]: Remove more @allow_reuse=True validators (#25236) 2024-08-09 11:10:27 -04:00
core core[patch]: use time.monotonic() instead time.time() in InMemoryRateLimiter 2024-08-09 11:31:20 -04:00
experimental experimental[patch]: Use get_fields adapter (#25193) 2024-08-08 15:10:11 -04:00
langchain langchain[patch]: add deprecations (#24792) 2024-08-09 10:34:43 -04:00
partners partners: fix of issue #24880 (#25229) 2024-08-09 13:21:37 +00:00
standard-tests core[patch]: Add pydantic metadata to subset model (#25032) 2024-08-05 17:57:39 -07:00
text-splitters text-splitters[patch]: Release 0.2.3 (#24998) 2024-08-02 20:27:22 +00:00