-
-
Notifications
You must be signed in to change notification settings - Fork 263
Closed
Labels
Description
PyShp Version
Head
Python Version
All of them
Your code
Doesn't matterFull stacktrace
run_tests (3.9, ubuntu-24.04)
failed now in 8s
Search logs
1s
1s
0s
3s
Prepare all required actions
Run ./.github/actions/test
Run python shapefile.py
Running doctests...
**********************************************************************
File "README.md", line 1187, in README
Failed example:
for shape in sf.iterShapes():
# do something here
pass
Exception raised:
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.23/x64/lib/python3.9/doctest.py", line 1334, in __run
exec(compile(example.source, filename, "single",
File "<doctest README[221]>", line 1, in <module>
for shape in sf.iterShapes():
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1548, in iterShapes
shp = self.__getFileObj(self.shp)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1319, in __getFileObj
raise ShapefileException(
shapefile.ShapefileException: Shapefile Reader requires a shapefile or file-like object.
**********************************************************************
File "README.md", line 1195, in README
Failed example:
for shapeRec in sf.iterShapeRecords():
# do something here
pass
Exception raised:
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.23/x64/lib/python3.9/doctest.py", line 1334, in __run
exec(compile(example.source, filename, "single",
File "<doctest README[223]>", line 1, in <module>
for shapeRec in sf.iterShapeRecords():
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1889, in iterShapeRecords
for shape, record in izip(
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1548, in iterShapes
shp = self.__getFileObj(self.shp)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1319, in __getFileObj
raise ShapefileException(
shapefile.ShapefileException: Shapefile Reader requires a shapefile or file-like object.
**********************************************************************
File "README.md", line 1199, in README
Failed example:
for shapeRec in sf: # same as iterShapeRecords()
# do something here
pass
Exception raised:
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.23/x64/lib/python3.9/doctest.py", line 1334, in __run
exec(compile(example.source, filename, "single",
File "<doctest README[224]>", line 1, in <module>
for shapeRec in sf: # same as iterShapeRecords()
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1222, in __iter__
for shaperec in self.iterShapeRecords():
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1889, in iterShapeRecords
for shape, record in izip(
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1548, in iterShapes
shp = self.__getFileObj(self.shp)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1319, in __getFileObj
raise ShapefileException(
shapefile.ShapefileException: Shapefile Reader requires a shapefile or file-like object.
**********************************************************************
File "README.md", line 1222, in README
Failed example:
for rec in sf.iterRecords(fields=[filter_field]):
if rec[filter_field] == filter_value:
# load full record and shape
shapeRec = sf.shapeRecord(rec.oid)
shapeRec.record["name"]
Exception raised:
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.23/x64/lib/python3.9/doctest.py", line 1334, in __run
exec(compile(example.source, filename, "single",
File "<doctest README[230]>", line 4, in <module>
shapeRec = sf.shapeRecord(rec.oid)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1864, in shapeRecord
shape = self.shape(i, bbox=bbox)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1498, in shape
shp = self.__getFileObj(self.shp)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1319, in __getFileObj
raise ShapefileException(
shapefile.ShapefileException: Shapefile Reader requires a shapefile or file-like object.
**********************************************************************
File "README.md", line 1243, in README
Failed example:
for shapeRec in sf.iterShapeRecords(bbox=bbox, fields=fields):
shapeRec.record
Exception raised:
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.23/x64/lib/python3.9/doctest.py", line 1334, in __run
exec(compile(example.source, filename, "single",
File "<doctest README[233]>", line 1, in <module>
for shapeRec in sf.iterShapeRecords(bbox=bbox, fields=fields):
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1899, in iterShapeRecords
for shape in self.iterShapes(bbox=bbox):
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1548, in iterShapes
shp = self.__getFileObj(self.shp)
File "/home/runner/work/pyshp/pyshp/shapefile.py", line 1319, in __getFileObj
raise ShapefileException(
shapefile.ShapefileException: Shapefile Reader requires a shapefile or file-like object.
**********************************************************************
1 items had failures:
5 of 269 in README
***Test Failed*** 5 failures.
Error: Process completed with exit code 5.Other notes
