• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Gallopsled / pwntools / 40085163675
74%
dev: 0%

Build:
Build:
LAST BUILD BRANCH: fix/encoder-alphanumeric-amd64
DEFAULT BRANCH: dev
Ran 24 Oct 2026 10:23AM UTC
Jobs 1
Files 151
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

24 Oct 2026 10:15AM UTC coverage: 73.545% (+0.05%) from 73.498%
40085163675

push

github

web-flow
fix(packing): dd() raises TypeError on a bytearray destination (#2772)

* fix(packing): dd() raises TypeError on a bytearray destination

dd() documents bytearray as a supported destination type, but
dd(bytearray(b'Hello!'), b'?', skip=5) raises
"TypeError: 'bytes' object cannot be interpreted as an integer".

pwnlib/util/packing.py:1108 handled list and bytearray destinations in a
single branch and filled both with list(map(p8, bytearray(src))). p8()
returns a length-1 bytes object, which is what a list destination is
documented to hold (see the existing dd(list('Hello!'), (63,), skip=5)
doctest), but a bytearray slice assignment needs an iterable of int, so
every bytearray destination crashed.

Assign the byte string src directly when the destination is a bytearray.
Every src branch above the destination dispatch (packing.py:1039-1089)
has already reduced src to a byte string, so the slice assignment is
always valid. This also makes a bytearray destination agree with the
bytes and str destinations, which already copy src verbatim.

Add a doctest covering the returned value and the in-place update of the
caller's bytearray.

* Add changelog entry for #2772

---------

Co-authored-by: peace-maker <peacemakerctf@gmail.com>

3818 of 6432 branches covered (59.36%)

3 of 3 new or added lines in 1 file covered. (100.0%)

13336 of 18133 relevant lines covered (73.55%)

0.74 hits per line

Jobs
ID Job ID Ran Files Coverage
1 40085163675.1 24 Oct 2026 10:23AM UTC 151
73.55
GitHub Action Run
Source Files on build 40085163675
  • Tree
  • List 151
  • Changed 3
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • 3daf28b6 on github
  • Prev Build on stable (#40085013754)
  • Next Build on stable (#40086150110)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc