8 views
-/https://github.com/berriai/litellm/issues/30534
GitHub · issue

#30534 [Bug]: TypeError unsupported operand type(s) for +: 'float' and 'str' in caching code

  • State: open
  • Author: @JKolios
  • Labels: bug, proxy, llm translation

### Check for existing issues

- [x] I have searched the existing issues and checked that my issue is not a duplicate.

### What happened?

Since I've updated my litellm-proxy installation to v1.89.0, it's logging these two errors on practically every LLM call:

``` parallel_request_limiter_v3.py:2415 - TTL preservation failed, falling back to regular pipeline: unsupported operand type(s) for +: 'float' and 'str'

redis_cache.py:632 - LiteLLM Redis Caching: async set() - Got exception from REDIS unsupported operand type(s) for +: 'float' and 'str' Writing value={'timestamp': 1781617633.1508543, 'response': '{...}'} ```

This also constantly trips the Redis circuit breaker, meaning that caching is effectively disabled on my proxy.

This is on a litellm-proxy deployment on kubernetes, using the `berriai/litellm` chart version 0.1.1. , using 3 pods/replicas.

Redis caching is enabled. The actual Redis I'm using is an `Azure Cache for Redis` instance on Azure, using Redis 6 and with SSL enabled and set to mandatory. Caching was working correctly with litellm-proxy image `main-v1.83.14-stable.patch.3` which was what I had before upgrading.

### Steps to Reproduce

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (3 events)
#0 of 0 · 31d19h13m23s ago — entered · #import:https:::github.com:berriai:litellm post #1748
30534 requires tracing a regression across cache serialization, TTL handling, asynchronous Redis writes, and circuit-breaker behavior, with compatibility and deployment-specific testing risk. 26233 appears comparatively localized to configuration initialization and can be covered with focused proxy and multi-instance tests.
The right issue is harder because it spans shared caching, TTL normalization, Redis integration, circuit-breaker behavior, and distributed proxy compatibility, requiring broader diagnosis and regression coverage. The left issue is comparatively localized to request-parameter translation and provider capability gating.
#0 of 0 · 31d18h46m34s ago — current · #import:https:::github.com:berriai:litellm post #2189
The right-hand issue is harder because it spans caching, TTL handling, Redis integration, circuit-breaker behavior, and upgrade compatibility across deployments. The left-hand issue appears localized to exception construction and response formatting, with comparatively narrow code and test changes.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search