PyPy test failures
Open
Nobody has claimed this yet.
windows
- Dominant language
- Python
- Stars
- 4.5k
- Forks
- 631
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 10
Description
On the conda-forge feedstock, the tests for PyPy on Windows are skipping a few failures:
test_frechet_distance_densify crashes, and test_dump_binary_load_hex fails with the below error:
__________________________ test_dump_binary_load_hex __________________________
some_point = <POINT (1.2 3.4)>
tmpdir = local('C:\\Users\\VssAdministrator\\AppData\\Local\\Temp\\pytest-of-VssAdministrator\\pytest-0\\test_dump_binary_load_hex0')
def test_dump_binary_load_hex(some_point, tmpdir):
"""Asserts that reading a text file (hex mode) as binary fails."""
file = tmpdir.join("test.wkb")
with open(file, "wb") as file_pointer:
dump(some_point, file_pointer)
# TODO(shapely-2.0) on windows this doesn't seem to error with pygeos,
# but you get back a point with garbage coordinates
if sys.platform == "win32":
with open(file, "r") as file_pointer:
> restored = load(file_pointer, hex=True)
..\_test_env\lib\site-packages\shapely\tests\legacy\test_wkb.py:153:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
..\_test_env\lib\site-packages\shapely\wkb.py:28: in load
data = fp.read()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <encodings.utf_8.IncrementalDecoder object at 0x0000022be5a47bb0>
input = b'\x01\x01\x00\x00\x00333333\xf3?333333\x0b@', final = True
def decode(self, input, final=False):
# decode input (taking the buffer into account)
data = self.buffer + input
> (result, consumed) = self._buffer_decode(data, self.errors, final)
E UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf3 in position 11: invalid continuation byte
..\_test_env\Lib\codecs.py:322: UnicodeDecodeError
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce test_frechet_distance_densify and test_dump_binary_load_hex under PyPy on Windows. Read the traceback locations in shapely/tests/legacy/test_wkb.py and shapely/wkb.py, then trace the platform-specific behavior. Done means both tests pass without being skipped in that environment.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- operating-systems, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100