Skip to content

gr.to_rle() does not work when the chromosome keys are not strings #114

Description

@endrebak
  File "/home/endrebak/code/ruranges/benchmark.py", line 9, in <module>
    print(gr.to_rle())
    ~~~~~^^^^^^^^^^^^^
  File "/home/endrebak/venvs/ruranges/lib/python3.14/site-packages/pyrle/rledict.py", line 377, in __str__
    " ".join(keys[0]),
    ~~~~~~~~^^^^^^^^^
TypeError: sequence item 0: expected str instance, numpy.int64 found

This is just because the join needs to turn the non-string into a string. Should be a simple fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions