Provides a mutable alternative to namedtuple. Users define a class with fields and get a mutable, tuple-like object with named attributes. Last stable version is 1.4, released in 2012. No active development, but still usable. Use with caution in new projects.
pip install recordtypeVerified import paths — ran on the pinned version, not inferred.
Creates a mutable record type with named fields.
Use from dataclasses import dataclass and define a class with fields.
Always use a space-separated string: recordtype('Name', 'field1 field2 field3').Consider using dataclasses with type annotations if you need type safety.
If you need pickle, implement __reduce__ manually or switch to a different library.
Use: from recordtype import recordtype
Pass field names as a string: recordtype('Person', 'name age')Access fields by name, not by unpacking. If unpacking is needed, consider namedtuple or dataclasses.
No dependency data recorded yet.