Skip to content

use pyo3 0.28.2 and support python 3.14 issue#51#52

Open
ensignavenger wants to merge 2 commits intoeclipse-biscuit:mainfrom
ensignavenger:main
Open

use pyo3 0.28.2 and support python 3.14 issue#51#52
ensignavenger wants to merge 2 commits intoeclipse-biscuit:mainfrom
ensignavenger:main

Conversation

@ensignavenger
Copy link

This may be messy, I tried to clean it up. It is not passing pytest... and I am not sure how to fix it. As stated in issue #51, I don't have any Rust experience. Submitting the pull request for review and feedback and maybe help of those wiser than I.

@divarvel
Copy link
Contributor

The issue seems to be coming from this change https://github.com/eclipse-biscuit/biscuit-python/pull/52/changes#diff-b1a35a68f14e696205874893c07fd24fdb88882b47c23cc0e0c80a30c7d53759R1346

Since PyDate now wraps a PyAny, it will always succeed in FromPyObject and as such always be picked before PyBytes in NestedPyTerm’s FromPyObject impl.

@divarvel
Copy link
Contributor

divarvel commented Mar 14, 2026

I see FromPyObject is implemented for OffsetDateTime, you could try replacing PyDateTime by this and seeing if that works. Pay attention to the time offset, make sure that the test covers it, don’t hesitate to update them if necessary.

@ensignavenger
Copy link
Author

Simply reverting that change to the original seems to have fixed it... is that acceptable?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants