# One line of Python, and a 3x drop in p99

DevFeed: [One line of Python, and a 3x drop in p99](<https://devfeed.tech/articles/one-line-of-python-and-a-3-drop-in-p99-2104.md>)

Original publisher: [Read original article](<https://developers.soundcloud.com/blog//one-line-of-python-and-a-3x-drop-in-p99>)

Published: 2026-08-11T00:00:00Z

Content type: article

Language: en

Sources: [SoundCloud Backstage Blog](<https://devfeed.tech/sources/soundcloud-backstage-blog.md>)

Topics: [Latency](<https://devfeed.tech/topics/latency.md>), [Back end](<https://devfeed.tech/topics/backend.md>), [bug](<https://devfeed.tech/topics/bug.md>), [cpu](<https://devfeed.tech/topics/cpu.md>), [API](<https://devfeed.tech/topics/api.md>), [Python](<https://devfeed.tech/topics/python.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [ads](<https://devfeed.tech/tags/ads.md>), [api](<https://devfeed.tech/tags/api.md>), [backend](<https://devfeed.tech/tags/backend.md>), [bug](<https://devfeed.tech/tags/bug.md>), [code](<https://devfeed.tech/tags/code.md>), [cpu](<https://devfeed.tech/tags/cpu.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [latency](<https://devfeed.tech/tags/latency.md>), [logging](<https://devfeed.tech/tags/logging.md>), [measurement](<https://devfeed.tech/tags/measurement.md>), [monitoring](<https://devfeed.tech/tags/monitoring.md>), [performance](<https://devfeed.tech/tags/performance.md>), [python](<https://devfeed.tech/tags/python.md>)

## AI overview

The article describes removing one log statement from a service's hot path, which substantially reduced 99th-percentile response latency and CPU usage. The service supports ad-serving decisions through an internal API, and the investigation found that validation warnings and metric increments were being emitted for expected requests from fixed-policy callers that supplied no Bayesian posterior state.

## Source excerpt

We removed one log statement from a service's hot path this week. Its 99th-percentile response latency fell from a steady to , and CPU...