Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix 1 Square Km Draw Tool #3157

Merged
merged 2 commits into from
Aug 27, 2019
Merged

Fix 1 Square Km Draw Tool #3157

merged 2 commits into from
Aug 27, 2019

Commits on Aug 27, 2019

  1. Isolate failing code and add failing test

    The bit of code that generates a 1 square km box from a
    given point is isolated into a utility function so it can
    be tested separately. Also add a test that exercises the
    code with sample values taken from production (where the
    failure does not occur).
    
    The failure is likely due to a subtle change in Lodash
    behavior caused by the upgrade in 6ac8212.
    rajadain committed Aug 27, 2019
    Configuration menu
    Copy the full SHA
    096d84e View commit details
    Browse the repository at this point in the history
  2. Unroll and simplify swNe calculation

    This was previously done by a dense sequence of Lodash
    methods, some of which were affected by the Lodash upgrade
    and had stopped working correctly.
    
    Now we make the final array by hand using direct values,
    foregoing any Lodash functionality. This makes the code
    easier to read and understand, and the tests pass.
    rajadain committed Aug 27, 2019
    Configuration menu
    Copy the full SHA
    3b8252d View commit details
    Browse the repository at this point in the history