geopython / pycsw

pycsw is an OGC CSW server implementation written in Python. pycsw fully implements the OpenGIS Catalogue Service Implementation Specification [Catalogue Service for the Web]. Initial development started in 2010 (more formally announced in 2011). The project is certified OGC Compliant, and is an OGC Reference Implementation. pycsw allows for the publishing and discovery of geospatial metadata via numerous APIs (CSW 2/CSW 3, OpenSearch, OAI-PMH, SRU). Existing repositories of geospatial metadata can also be exposed, providing a standards-based metadata and catalogue component of spatial data infrastructures. pycsw is Open Source, released under an MIT license, and runs on all major platforms (Windows, Linux, Mac OS X). Please read the docs at https://pycsw.org/docs for more information.
https://pycsw.org
MIT License
198 stars 153 forks source link

incorrect formatting of coordinates in bbox2wktpolygon function #53 #930

Closed netanelC closed 6 months ago

netanelC commented 7 months ago

Description

The bbox2wktpolygon function in the util.py file uses %.2f for formatting coordinates in the resulting WKT Polygon. This formatting limits the number of decimal places in the output, leading to inaccurate representation of coordinates.

Environment

Steps to Reproduce

  1. Use the bbox2wktpolygon function with a bounding box input.
  2. Observe the resulting Well-Known Text (WKT) Polygon and note the limited precision in the coordinates.

Additional Information

Expected Behavior: The bbox2wktpolygon function should represent coordinates with full precision, providing accurate WKT Polygons.