Skip to content

Commit

Permalink
print coords not coords_list
Browse files Browse the repository at this point in the history
  • Loading branch information
machallboyd committed Jun 23, 2022
1 parent fe259fd commit 497f0cc
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion mappymatch/constructs/trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def __len__(self):
def __str__(self):
output_lines = [
"Mappymatch Trace object",
f'coords_list: {self.coords_list if hasattr(self, "coords_list") else None}',
f'coords: {self.coords if hasattr(self, "coords") else None}',
f'frame: {self._frame if hasattr(self, "_frame") else None}',
]
return "\n".join(output_lines)
Expand Down Expand Up @@ -301,3 +301,8 @@ def to_geojson(self, file: Union[str, Path]):
file: the file to write to
"""
self._frame.to_file(file, driver="GeoJSON")


class InheritTrace(Trace):

This comment has been minimized.

Copy link
@nreinicke

nreinicke Jun 23, 2022

Collaborator

Is this just a relic from some internal testing?

derp, sorry I see that was an example that you raised for when the Trace would not have the _frame attribute. I still think we would want to blow up in this case too as we wouldn't be able to genuinly pass this object around the program and keep the contract that it is indeed a Mappymatch Trace, do you agree?

We probably also want to pull this out before the merge.

This comment has been minimized.

Copy link
@machallboyd

machallboyd Jun 23, 2022

Author Collaborator

Whoops, didn't realize I'd checked that in.

def __init__(self):
pass

0 comments on commit 497f0cc

Please sign in to comment.