How the PyTorch Lightning Community Discovered a Supply Chain Attack and Fixed it in 42 Minutes
Blog post from Lightning AI
PyTorch Lightning reported that its PyPI publishing credentials were compromised on April 30, 2026, allowing an attacker to upload tampered versions 2.6.2 and 2.6.3, which were available for 42 minutes before being quarantined following reports from community members, security services, and PyPI. The GitHub source repository was not affected; instead, the attacker cloned the public code, added a payload, and distributed malicious builds through PyPI. Importing the compromised package allegedly launched a background process that installed Bun and ran obfuscated JavaScript designed to collect cloud credentials, browser-stored credentials, environment files, and GitHub tokens before sending data to an attacker-controlled server. Users who installed or imported either affected version, including in CI/CD environments, are advised to treat accessible secrets as compromised, immediately switch to version 2.6.1, rotate credentials, inspect logs and environments, and scan for published indicators of compromise. The Lightning AI team stated that it has regained control of PyPI access, is rotating credentials and assessing the incident’s scope, plans to issue version 2.6.4, retire the affected version numbers permanently, and publish a post-mortem and updated security advisory.
| Trend | Post Mentions | Total Month Mentions | Posts | Companies | MoM |
|---|---|---|---|---|---|
| Secrets Management | 2 | 2,183 | 460 | 136 | +6% |
Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.