Skip to content

MGRS and the South Pole #2

@dtvasquez

Description

@dtvasquez

Please fill out as much known and relevant information as possible.

Version Information:

  • MGRS Java Version: 212
  • MGRS Java Source: (e.g. Central Repository, Release, Source Code Build) maven
  • IDE Name & Version: Android Studio
  • Maven Version: (mvn -version)
  • Java Version: (java -version) 11
  • Platform & OS: Android 7+
  • Other Relevant Libraries:

Expected Results:

  • What did you expect to happen?

Create an MGRS object near the Poles. Example: AQE 33377 29769
Using the GEOTrans utility/source code, this value can be parsed as valid MGRS

Observed Results:

  • What happened instead?
    MGRS.parse() throws a ParseException
  • How often does this occur?
    Anytime a valid location near the poles is used, it fails the regex in use ^(\\d{1,2})([C-HJ-NP-X])(?:([A-HJ-NP-Z][A-HJ-NP-V])((\\d{2}){0,5}))?$

Output:

  • Any logs, errors, or output messages?
    ParseException("Invaliid MGRS")

Steps to Reproduce:

  1. Try to parse an MGRS string that represents a location at the poles
  2. ParseException

Relevant Code:

MGRS mgrs = MGRS.parse("AQE3337729769");

Test Files:

  • Links to any files needed for testing?

Additional Information:

  • Any additional configuration, data, or information that might help with the issue?

MGRS uses UPS project to cover the poles, where A|B cover the South Pole, and Y|Z cover the North Pole. I didn't see references to ups in the source for this project. Are there plans to add support for the poles?

image
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions