Skip to content

BUG | "Fatal Error: can't compare offset-naive and offset-aware datetimes" when running with Python 3.13 #434

Description

@DandelionSprout

What is the problem you are experiencing?

Running a scan PyFunceble in Python 3.13 works for 15〜20sec, then throws Fatal Error: can't compare offset-naive and offset-aware datetimes. This applies both to the Microsoft Store version of Python 3.13, and the Cygwin version of Python 3.13.

How can we reproduce the problem?

To reproduce the problem:

  1. Have PyFunceble installed through py.
  2. Start a scan of a local file, for example pyfunceble -f JohnMaddenAeiou.txt --adblock
  3. It works well for a short while, being able to scan 〜90 entries.
  4. Throws the Fatal Error: can't compare offset-naive and offset-aware datetimes.

Do you have a screenshot?

Screenshot Image

What did you expect to happen?

I expected that the scan would work normally and be able to scan the whole of a .txt file correctly.

Is there a workaround?

None that I'm aware of.

There is the wild off-chance that downgrading client-side to Python 3.9 could fix it, but do not take my word for that at all.

How did you configure PyFunceble?

.PyFuncble.overwrite.yaml was empty on my end, and I can't immediately see that I've done any changes to the near-fresh install of .PyFunceble.yaml that I have on the Microsoft Store version of Python 3.13.

Which Operating System did you use?

Windows 11

Which Python Version did you use?

3.13

Which PyFunceble Version did you use?

pyfunceble 4.2.28. (Blue Duckling: Tulip)

Additional context

The line that Python complains about is allegedly

date_of_inclusion = dataset["tested_at"]

The little I understand from online claims on e.g. https://www.pythonclear.com/errors/typeerror-cant-compare-offset-naive-and-offset-aware-datetimes/ is that fixing it would require a full rewrite of the syntaxing of the datetime section(s) of (...)/inactive/csv.py.

Metadata

Metadata

Assignees

Labels

Projects

Status
✅ Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions