ry.URL.replace_* -> ry.URL.with_*: the replace_* methods are
deprecated in favor of with_* methods. The ry.URL.replace still exists
as a way to replace multiple parts at once.
ry.aiopen -> ry.aopen: it was supposed to be “asyncio-open”, but it
could be easily confused with “artificial-intellegence-open”/“llm-open”
ryo3-fnv
FnvHasher -> fnv1a
fnv1a function removed as it was just a stupid proxy for fnv1a class
constructor
ryo3-jiff
use PyMutex and get rid of parking_lot::Mutex for jiff series iterators
PyMutex that lets ya pick to throw or not via const generic (very fancy
look at me)
ryo3-jiff
Update jiff to 0.2.16
Add ZonedSeries
ryo3-std
Use jiff for duration formatting
ry.Duration.seconds now returns total seconds in duration
ry.Duration.seconds_remainder returns seconds % days (self.seconds
% 86400)
Remove datetime.timedelta support for ry.Duration.__richcmp__ as there
is not a one-2-uno direct mapping between timedeltas and durations (bc
durations are unsigned)
pydantic support for ry.Duration
ryo3-serde
Use jiff unsigned-duration serialization for ry.Duration
switched query/form kwargs to accept anything that can be serde-d via
ryo3-serde which is basically anything that is json-serializable via
ry.stringify
ry.protocols
moved all protocols to ry.protocols
deprecations
deprecate all obj.string() methods in favor of obj.to_string() tho I
still dont love it in the first place
ryo3-jiff
added isoformat and from_isoformat methods to ry.TimeSpan and
ry.SignedDuration structs
ryo3-sqlformat
Updated to version 0.4.0 of sqlformat crate
Added sqlformat version 0.4.0 new options:
ignore_case_convert: list[str] | None = None
inline: bool = False
max_inline_block: int = 50
max_inline_arguments: int | None = None
max_inline_top_level: int | None = None
joins_as_top_level: bool = False
Changed indent arg/kwarg to accept either:
int (positive integer for number of spaces)
str (“tabs”, “\t” or “spaces”)
Changed uppercase arg/kwarg to default to False instead of True to be
more inline with the default behaviour of sqlformat crate
migrated from xxhash-rust to twox-hash ~ retiring ryo3-xxhash :( - the
xxhash-rust hashers liked to sometimes crash, whereas the twox-hash
py-hashers dont
Speed run of socketaddr types (WIP); needs more testing and the socket types
could be cleaner…
ryo3-memchr
Basic functionality for memchr and memrchr operations
ryo3-jiff
Changed human arg/kwarg in ry.TimeSpan and ry.SignedDuration to
friendly and also make keyword only
Changed strptime and strftime functions to be more inline with python’s
datetime module by changing the order of args to be (string, format)
instead of (format, string); the strptime signature is
strptime(s: str, /, fmt: str) -> Self
Added to ry.TimeSpan and ry.SignedDuration the friendly method for
more natural string representations
Many internal refactors and cleanup
Converted all __repr__ methods to use struct Display impls
Fixed rounding object repr function(s) and added pickling and tests for
round objects
type-annotations
Missing lstrip/rstrip method types for ry.Bytes
Updated types for ry.TimeSpan and ry.SignedDuration w/ correct
friendly kwarg and friendly() methods
pyo3-bytes mirrors the official pyo3-bytes crate + extra methods, BUT
it requires the multiple-pymethods feature to be enabled
ryo3-bytes is a crammed together version of the pyo3-bytes
implementation and extra methods and does NOT require the
multiple-pymethods feature to be enabled
Made PythonBytesMethods trait for the methods that are shared between
pyo3-bytes and ryo3-bytes
ryo3-ulid
strict + lax ulid parsing for pydantic
ryo3-jiff
Renamed checked_add and checked_sub to add and sub where the
checked_version can error; did not remove where the checked version returns
an Option type (ry.SignedDuration). .checked_add may return later as a
method that returns an Option type for all types (tbd). This is also meant
to pave the way for add/sub functions with a more familiar api akin to
whenever, pendulum, arrow, insert-other-datetime-lib-here
Added replace methods to Date, DateTime and Time structs that use
the underlying jiff with functions
pybytes bool kwargs to return builtins.bytes if True and ry.Bytes if
False; default is False
ryo3-serde
support for types defined in ryo3-http
support for default kwarg that is passed to the serde serializer; like w/
the stdlib-json and orjson serializers, this allows for serializing types
that are not natively supported by ry/serde and if failure should occur, it
should raise a TypeError or ValueError instead of returning None by
default
ryo3-reqwest
json kwarg added to request builders that auto-serializes via
ryo3-serde; also because it uses the reqwest::RequestBuilder it auto
sets the Content-Type header to application/json
this should theoretically allow for serializing any python object that is
serde serializable with almost any serde serializer… that is the goal
ryo3-json
Where json stuff + ry is going to live in the near future (may consolidate
ryo3-jiter into this newer crate)
ry.stringify() uses ryo3-serde + serde_json to write json bytes/bufs
and it is pretty fast, faster than ujson and rapidjson (not tested yyjson),
BUT orjson is still fastest (read a bunch of their code and it is remarkably
advanced and optimized)
Added async def take(self, n: int=1): ... method returns n chunks as a
list
Added async def collect(self: join = False) -> ...: method that collects
the stream into a single ry.Bytes object if join=True or a list of
ry.Bytes objects if join=False
Added async def take(self, n: int=1): ... which returns n chunks as a
list
ryo3-glob
add dtype kwarg that takes either dtype=str | ry.FsPath | pathlib.Path
as type of obj yielded by the iterable; something about this feels really
icky, the default may be changed to str (from pathlib.Path)
ryo3-ulid
Added mostly as a way to test how much pydantic + ry integration would be
added __target__ to python package metadata in ry.__about__ with the
target triple of the current build
ryo3-std
Buffering for FileReadStream
ryo3-jiter
Add function parse_jsonl for parsing json lines
Add lines kwarg to read_json for parsing/reading json lines
ryo3-jiff
ZonedDateTime.__new__ takes more python-datetime like args/kwargs, old
version of constructor moved to classmethod
ZonedDateTime.from_parts(timestamp: ry.Timestamp, tz: ry.TimeZone) -> ZonedDateTime
zoned top level function
if tz is None then it uses the system timezone
SIGNATURE
def zoned(
year: int,
month: int,
day: int,
hour: int = 0,
minute: int = 0,
second: int = 0,
nanosecond: int = 0,
tz: str | None = None,
) -> ZonedDateTime: ...
reqwest-request functions use TypedDict and Unpack
ryo3-jiff
serde serialization features/support
ry.ZonedDateTime.replace method mirroring ZonedWith – with is a
python keyword, so used replace instead
example script based on jiff-docs examples
test_jiff_examples_v2.py test script (basis for example script)
Was tired/fried so I copy-pasta-ed the ry/ryo3/_jiff.pyi type
annotations, the jiff-v2-docs-examples, and the jiff-v1-hand-translated
test_jiff_examples_v1.py file into Chad-Gippity who was able to do most
of the translation from rust to ry…
ryo3-xxhash
Align with xxhash pypi library w/ respect to naming conventions
Per Mr. Sushi’s thoughts changed all until/since methods to use kwargs
instead of the rust-like tuples that impl From/Into as it does not
translate well to python