devika icon indicating copy to clipboard operation
devika copied to clipboard

Fixed: TypeError: unsupported operand type(s) for |: 'type' and 'type'

Open obliviousz opened this issue 1 year ago • 3 comments

TypeError: unsupported operand type(s) for |: 'type' and 'type' fix

obliviousz avatar Apr 04 '24 08:04 obliviousz

The problem was just that python < 3.10 is incompatible with new typing syntax. Not sure if all type hints should be rewritten in a compatible manner or if the project should just require python >= 3.10 which is quite reasonable in 2024.

jmtatsch avatar Apr 04 '24 11:04 jmtatsch

@jmtatsch That's true. It could be changed to >= 3.10 in requirements then. But what I feel is if this works for lower versions and higher ones, then it doesn't hurt to change them. I'm new to open source, hence I might be wrong. So do excuse.

obliviousz avatar Apr 04 '24 11:04 obliviousz

No worries. We will just let the maintainer decide.

jmtatsch avatar Apr 04 '24 11:04 jmtatsch

I test this version on python 3.8 and 3.10 works fine. but we recommend to use >= 3.10 and < 3.12 currently closing this issue cause no one has this problem.

ARajgor avatar Apr 06 '24 07:04 ARajgor