Task #10520 (new)
Opened 11 years ago
Last modified 8 years ago
Bug: path._base == unicode on Python2.7
Reported by: | jamoore | Owned by: | spli |
---|---|---|---|
Priority: | major | Milestone: | Unscheduled |
Component: | OmeroPy | Version: | 5.0.5 |
Keywords: | n.a. | Cc: | python-team@…, mtbcarroll, cblackburn, spli, hflynn |
Resources: | n.a. | Referenced By: | n.a. |
References: | n.a. | Remaining Time: | n.a. |
Sprint: | n.a. |
Description
See: https://github.com/openmicroscopy/openmicroscopy/pull/864/files#r3373785
Under Python 2.7, path.path IS-A unicode as opposed to Python 2.6 where it IS-A str. Minimally, rstring will need to be updated to check isinstance(val, (str, unicode)) which is a pretty common occurrence. More likely, the entire RString stack will need to be checked for unicode handling including unit tests.
Change History (10)
comment:1 Changed 11 years ago by mtbcarroll
comment:2 Changed 9 years ago by jamoore
- Cc spli added
- Milestone changed from 5.x to 5.1.0-m3
- Version set to 5.0.5
Is this something that needs to be taken care of ASAP?
comment:3 Changed 9 years ago by jamoore
- Milestone changed from 5.1.0-m4 to 5.1.1
- Owner jamoore deleted
If anyone has time to look at this, feel free.
comment:4 Changed 9 years ago by jamoore
- Milestone changed from 5.1.1 to 5.2.0-m1
Talking to Simon, there are likely 2 ways to fix this:
- modify path.py to behave appropriately
- updating rstring to properly handle unicode (largely to match gateway's handling)
Both of these are really too dangerous for 5.1.1. Pushing to 5.2 with the hope that we will just drop PY26 in 5.2. Otherwise, it will be a good time for a breaking change.
comment:5 Changed 9 years ago by jamoore
- Milestone changed from 5.2.0 to OMERO-5.2.0
Splitting due to milestone decoupling.
comment:6 Changed 9 years ago by jamoore
- Cc hflynn added
Can I propose we update rstring for 5.2.0 and document the (breaking) change?
comment:7 Changed 9 years ago by jamoore
- Owner set to spli
Simon, is there anything left to do here after https://github.com/openmicroscopy/openmicroscopy/pull/3950 ?
comment:8 Changed 8 years ago by jburel
- Milestone changed from OMERO-5.2.1 to OMERO-5.2.2
Milestone OMERO-5.2.1 deleted
comment:9 Changed 8 years ago by jburel
- Milestone changed from OMERO-5.2.2 to OMERO-5.2.1
Milestone OMERO-5.2.2 deleted
comment:10 Changed 8 years ago by jburel
Simon?
Once this is fixed, the rstring(str(f.abspath())) in repository.py can have the str removed; such str may have been added elsewhere as a temporary measure.