
Research
2025 Report: Destructive Malware in Open Source Packages
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.
libravatar-py
Advanced tools
Friendly fork of pyLibravatar.
While working on the Libravatar client project I came across the well built pyLibravatar library. The last update was at Jun 28, 2015 ( Thats over 6 years ago when I was writing this ). So thats why I decided to write this library. It mimics the API ( and functionality ) of pyLibravatar but with asyncio spice.
Install with pip from pypi (No extra dependencies):
$ python -m pip install libravatar-py
Install with pip from github ( Development | Not Recommended for Production ):
$ python -m pip install https://codeload.github.com/baseplate-admin/libravatar-py/zip/refs/heads/main
Call any of these 4 methods.
libravatar_url function ( This will essentially return the base url of
the image ) :
from libravatar import libravatar_url
url = libravatar_url(email="someone@example.com")
print(url)
# https://seccdn.libravatar.org/avatar/16d113840f999444259f73bac9ab8b10
libravatar_img_tag function ( This will wrap the libravatar url in a <img /> tag. You can also customize _alt text ) :
from libravatar import libravatar_img_tag
url = libravatar_img_tag(email="someone@example.com")
print(url)
# <img src=https://seccdn.libravatar.org/avatar/16d113840f999444259f73bac9ab8b10 alt='Avatar for someone@example.com' />
libravatar_raw_image function ( This will return the Libravatar image in a binary form ) :
from libravatar import libravatar_raw_image
res = libravatar_raw_image(email="someone@example.com")
print(res)
# Large binary string.
# To load it.
from PIL import Image
from io import BytesIO
res = Image.open(BytesIO(res))
libravatar_raw_query function ( Essentially passes the {args, kwargs} to httpx_get_avatar ):
from libravatar import libravatar_raw_image
# Note this this must be called from an async function
res = await libravatar_raw_query(email="someone@example.com", {})
# All httpx variables available in res
If you like this project add a star. If you have problems or suggestions please put them in the Issue Tracker. If you like to add features. Fork this repo and submit a Pull Request. 😛
The library is feature complete ( in my opinion ).
FAQs
Friendly fork of pyLibravatar for async support.
We found that libravatar-py demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.

Security News
Socket CTO Ahmad Nassri shares practical AI coding techniques, tools, and team workflows, plus what still feels noisy and why shipping remains human-led.

Research
/Security News
A five-month operation turned 27 npm packages into durable hosting for browser-run lures that mimic document-sharing portals and Microsoft sign-in, targeting 25 organizations across manufacturing, industrial automation, plastics, and healthcare for credential theft.