0
Fork 0
mirror of https://github.com/uber/h3-py.git synced 2026-11-16 07:44:46 +00:00
Commit graph

132 commits

Author SHA1 Message Date
AJ Friend
c3593ecae5
Add notes on making a release (#179)
* adding some notes on making a release

* capital

* Update dev_notes.md
2021-03-02 20:23:23 -08:00
AJ Friend
a7cac3e6df
bump version for v3.7.2 release (#178) v3.7.2
* bump version for v3.7.2 release

* capitalize

* catch and assert h3.unstable warning
2021-03-01 20:53:51 -08:00
Kyle Barron
709f343e59
Add vectorized h3_to_parent and h3_get_resolution (#166)
* Add vectorized h3 to parent

* Lint

* Release GIL

* Add default argument for vectorized h3_to_parent to adding h3_get_resolution

* Add test file

* Use np.array_equal in tests

* Add test with array passed to res in h3.h3_to_parent

* Coerce input to np array

* unsigned char -> int

* Fix int type

* Update vect.py

Co-authored-by: AJ Friend <ajfriend@gmail.com>
2021-03-01 16:58:44 -08:00
AJ Friend
fefba23a6c
h3-py release v3.7.1 (#175) v3.7.1
* bumping version

* bump py library versino

* drop windows build for a sec

* and the wheels

* put windows back

* updating ilammy/msvc-dev-cmd to see if it fixes the build

* update to use new Environment Files

https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#environment-files

* put the windows wheels back in

* update ilammy/msvc-dev-cmd in the wheels build

* testing 3.9

* try building wheel for mac py3.9

* bumping to 3.9 in a few places

* demonstrate failing distance test from #169

* fix for #169

* notes

* add PR numbers to changelog

* update h3lib badge version
2020-12-18 14:09:02 -08:00
AJ Friend
9cc3bfdd0a
Update CHANGELOG.md
changelog to reflect v3.7.0 release
2020-10-02 12:57:36 -07:00
AJ Friend
5e0dceb225
New cell area functions with h3==3.7 (#171) v3.7.0
* move to h3lib 3.8pre

* cython functions done

* have tests running

* linting

* bump core library

* skip building wheels for Python 3.9 for now (buggy)

* try bumping codecov action version

* try testing for 3.9

* ah, no 3.9 up yet

* bump some action versions

* add some docstrings

* changelog

* bump badges
2020-10-02 12:51:54 -07:00
AJ Friend
496dab0468
Update CI badges to reflect latest github actions (#163)
* readme

* Revert "readme"

This reverts commit 9ef3c0e4c7.

* update readme badges

* move the wheels announcement

* cut needless words!
2020-08-17 21:30:13 -07:00
AJ Friend
1f2a75a71e
v3.6.4 release and add requirements.in (#157) v3.6.4
* changelog and requirements.in

* bump h3-c to 3.6.4

* add pr number
2020-07-20 13:55:25 -07:00
AJ Friend
12a34ee699
Vectorized functions (#147)
* some simple code and benchmarks working

* clean up notebook

* moving code to h3.unstable.vect

* clean things up a bit

* ah, need a `with nogil` context manager to actually release the gil

* fewer imports

* remove example notebook

* add some docstrings

* whoopsie!
2020-07-20 12:25:55 -07:00
AJ Friend
dd08189b37
local ij conversion functions (#155)
* local ij conversion functions

* lint

* add implementation notes
2020-07-20 11:44:30 -07:00
Alejandro Hall
3b41a87a52
Fix walkthrough notebook broken link (#156) 2020-07-20 08:49:41 -07:00
AJ Friend
6a90952939
Windows Py3.5 fix for cibuildwheel (#151)
* don't need the dependencies, since they should get picked up from pyproject.toml now

* separating out a few steps to make dependencies clear

* drop a line

* try a thing

* looks like we need that thing!
2020-07-15 20:51:56 -07:00
AJ Friend
6bebac0435
first draft of v4 names (#146)
* first draft of v4 names

* add a warning around unstable code

* clean up lint complaints

* retry CI

* yeah, sure. that seems legit

* clean up the coverage

* more traditional names
2020-07-15 15:45:32 -07:00
AJ Friend
2fc211c2d3
little downloads badge (#142)
* little downloads badge

* fix link

* incense
2020-06-18 21:31:27 -07:00
AJ Friend
72db3f72d2
Add missing function bindings (#134) v3.6.3
* Add get_res0_indexes

* add h3_to_center_child

* add h3_get_faces

* lint

* changelog

* clean up error reporting a bit

* fixing error reporting hex formatting

* add release date
2020-06-04 12:36:25 -07:00
AJ Friend
012b497a23
add conda link (#132) 2020-06-03 10:36:11 -07:00
AJ Friend
a2770bd776
Build Python 2.7 wheels on Linux (#130) v3.6.2
* try building py27 wheels on linux

* py27 whell works on linux!

* bump version for release
2020-06-02 23:29:24 -07:00
AJ Friend
d3bc6cf4e2
build wheels when landing to master (#129) 2020-05-31 14:55:49 -07:00
AJ Friend
86ec88e0da
Put deg2coord and coord2deg into util.pyx (#128) 2020-05-31 14:03:28 -07:00
AJ Friend
1b78cceb0e
Fix error checking on hex2int (#127) 2020-05-31 13:57:33 -07:00
AJ Friend
944d917352
Final steps for releasing v3.6.1 (#126) v3.6.1
* changelog

* update the readme a bit

* versioning

* changelog and version

* 3

* wheels note

* api note

* Notes from Nick

* no deps

* words

* move stuff around

* unit to uint

* conventional usage: `## Usage`

* the

* omit needless words!

* nix they

* update release date
2020-05-29 14:39:19 -07:00
AJ Friend
caa171faa0
Clean up workflows on GitHub actions (#124)
* separate coverage/lint workflow

* move the coverage/lint out of the normal tests

* try a consolidated tests.yml

* skip 2.7 on windows

* reduce duplicate workflows/jobs by adding some guards

* better names for tests?

* better wheel names

* T to t

* update submodule to 3.6.3
2020-05-27 19:11:10 -07:00
AJ Friend
480bf972db
add a twine check (#123) v3.6.1a5
* add a twine check

* let's actually try to do a release

* wheelhouse not dist
2020-05-26 23:03:07 -07:00
AJ Friend
11a3df63c9
try some new wheels logic (#122) v3.6.1a4
* try some new wheels logic

* try it!

* wheels!

* just need one file for wheels

* typos
2020-05-26 22:15:25 -07:00
AJ Friend
7521efdfaa
see if it works without the conditions (#120) v3.6.1a3
* see if it works without the conditions

* fix classifiers

* the pypi github action only works on linux...

* don't upload to pypi for now

* try some fancier logic

* spread the fancy logic
2020-05-26 20:41:14 -07:00
AJ Friend
08daf33b32
Prepare for 3.6.1 alpha release (#119) v3.6.1a2 v3.6.1a1
* prepare for alpha release

* playing with version tag events

* setup PyPI push step

* only upload on push

* forgot the v!!

* hmmm
2020-05-25 18:13:38 -07:00
AJ Friend
f6a9a2a096
Use setup.py for optional requirements instead of requirements-dev.txt (#117)
* remove requirements-dev.txt and move to setup.py

* use [all] option for pip install instead of requirements-dev.txt

* update readme

* NumPy

* readme

* add to readme
2020-05-25 10:51:16 -07:00
AJ Friend
2f89a42da9
Windows wheels (#116)
* try windows wheels

* skip 2.7

* try again

* try without pip upgrade

* try a thing

* try again

* hmmm. github seems to be down...

* few more things

* meh

* bump

* no 32bit builds

* clean up a bit

* and this one

* msvc

* cl

* do we need ilammy/msvc-dev-cmd?

* add it all back in...

* try 2.7 again

* add back in 2.7

* try without the pip installs

* move the pip installs back in

* remove some pip upgrades

* look at artifacts again

* cython

* need cmake

* mess with pyproject.toml

* need ninja?

* turn off upload
2020-05-24 11:04:55 -07:00
AJ Friend
2d3c6a5727
Wheels for Mac/Linux (#115)
* try wheels for mac

* try cibuildwheel

* bah

* skip building PyPy

* --print-build-identifiers

* upload artifacts

* bah

* run tests on the wheels?

* need numpy for tests

* simplify wheel build

* does actions/upload-artifact@v2 work?

* try linux

* actually try to build linux wheels

* try a different image

* gotta do a `-lrt` link option, i think

* image shouldn't matter

* try with a cflags env variable

* try adding -lrt in cmake

* skip 27 on linux

* oh, and the env variable doesn't do anything

* skip building for 32-bit

* try -lrt just with cibuildwheels

* revert the cmake file

* no quotes?

* try some cmake options

* remove -lrt flags with cibw

* BUILD!

* set options

* cmake note

* turn off artifact upload for now

* add tests for 3.5, as we're building wheels for it

* build sdist

* bump

* beep
2020-05-22 11:48:19 -07:00
AJ Friend
3afd1833b5
Trying windows CI (#113)
* trying windows ci

* don't worry about 2.7 for now

* turn off appveyor for now (takes too long!)

* try again

* spacing

* try again

* adding back in appveyor for reference

* try a lower sdk

* try msvc-dev-cmd

* try a pip hack

* throwing libraries at it

* try a cmake solution

* try setting env variables

* echo?

* meh?

* boop

* blerp

* just try cl.exe

* this should work!

* try moving the env definitions

* remove manual install of build deps

* run lint and tests

* remove appveyor.yml

* windows CI badge

* appveyor webhook removed

* use latest action versions

* let's see if py2.7 works...

* try ms viz c++ 9.0

* just 2.7

* try again

* try again again

* try again again again

* try a new thing

* split out py2.7 logic

* try 2.7 again

* simplify

* boop!

* beep

* try 2.7 again

* add msbuild

* spacing

* blerp

* try version option

* vs-version not working?

* gahhhh!

* ahhhhhh!

* bump msbuild version

* booop

* bleep

* grrrrr

* windows!

* filename

* comment out

* try 9.0

* try readme example

* boop

* so sensitive!

* try one more thing

* giving up on 2.7 for now
2020-05-20 13:40:04 -07:00
AJ Friend
08c1f75954
Github actions for linux and macos (#112)
* start working with github actions on linux and macos

* oops. wrong folder

* use pip to install

* do i need ninja?

* put dev requirements after h3 install

* spaces

* drop `tests/*` from `pytest` call?

* try some code coverage

* find coverage report

* drop `tests/*` again

* update codecov badge

* do i need `codecov` in requirements? (now that we have the gh-action)

* trying coverage again

* oops. forgot macos

* try a gh-badge

* remove travis and update badges

* U -> u

* just use plain pip

* we do need `pytest-cov` for local coverage reports

* update ci

* just a change to re-run gh-actions
2020-05-18 00:24:52 -07:00
AJ Friend
cd051988af
Use pyproject.toml (#111)
* use pyproject.toml

* update build instructions in readme

* remove tox, since we don't actually use it. can add back in later

* clean up requirements-dev.txt and refactor makefile

* update travis

* set(CMAKE_POSITION_INDEPENDENT_CODE ON)

* update appveyor

* testing the CI scripts

* working with appveyor

* simplify appveyor testing commands
2020-05-17 10:39:55 -07:00
AJ Friend
7168f9c550
PyPI badge (#109)
* add pypi badge

* correct version of old bindings

* organize badges a bit
2020-05-12 16:51:21 -07:00
Isaac Brodsky
5a833e2e53
Remove unnecessary CMake lines (#108)
Fixes #103 - These should be handled by `target_link_libraries`.
2020-05-12 11:31:28 -07:00
AJ Friend
78c09341c4
The big Cython move (#99)
* Use Hunter

* Use position independent code to link shared object correctly

* Fix issues in module naming

* Temporary fix

* Use src directory and fix CMake build for subdirectory

* Fix build, remove dependency on Hunter

* aj first stab at cython

* Added class to manage H3Index array memory.
Added a bunch of wrapping functions.

* hacky version of polyfill working

* remove some naming redundancy

* Adding compact and uncompact functions

* notes

* clean up HexMem class

* reworked geofence and geopolygon. now memorysafe (i think)

* reorder definitions

* formatting

* Use scikit-build for setup

* Changes for getting build partially working on macOS

* Add scikit-build to requirements-dev.txt

* Build the core library as static and update notes.md

* update cython notes

* Cleaning up the Cython instructions and tests a bit

* cleaning out extra files for now

* readme

* Cleaning out more files to focus on Cython dev in this branch

* makefile

* simplify install process with makefile

* adding back in a bunch of files

* Add appveyor.yml for Cython

* Disable Python 2.7 test

* reorganize cython build; working on os x

* get new changes running on my OSX machine

* add hexmem.pyx

* just throwing it all in h3core...

* newlines

* separate HexMem into separate module

* change import to `h3py.h3core` for tests

* update readme for new folder structure

* starting to layout separate APIs

* `set_int` and `set_str` working

* notes

* cleaning up a bit

* moving the HexMem helper functions

* moving lat/lng functions to separate module

* move output formatting functions

* use `size_t` in HexMem

* trying input/output formatters

* rename to make api modules obvious

* adding some functions providing hexagon stats

* adding some TODOs to use C functions instead of python

* fix api typos

* adds unidirectional edge functions

* cleaning up geo functions a bit

* add todo

* create `api` directory and move modules

* try using `_api_template.py` to generate different APIs

* remove HexMem class and use memoryviews of cython.view.array objects instead

* make single mercator function

* remove redundant exception handling

* automatic input validation

* add validation for unidirectional edges

* simplify API generation

* a little cleaning

* defaults for parent and child functions

* add back in H3str as input type to hex2int

* simplify validation and conversion code

* adding tests for geo functions

* rename hexmem -> util

* move exceptions to util.pyx

* move geo functions to a separate module

* move hex2int and int2hex to each api

* rename validation functions

* rename h3api -> libh3 to reserve "api" for the different python APIs we expose

* cleaning up memory allocation

* fix clean up code

* clean up comments

* add some resolution checking

* adding a diagram of the code to remove zeros

* adding some docstrings

* update H3 C library

* add line function

* docstring

* some function name changes

* rename k_ring -> disk

* rename hex_ring -> ring

* cleaning up modules

* ... cleaning up all the modules

* add in backward-compatible `old` API

* add some thoughts on slower fallback for `ring`

* some naming changes

* fix up mean_hex_area and mean_edge_length

* rename base_cell -> get_base_cell

* remove special case for n=0 memory allocation

* rename edge_hexes -> edge_cells

* rename edges_from_hex -> edges_from_cell

* rename functions to match current python implementation

* remove h3py.api.old in favor of defaulting to set_str

* update resolution docstring

* use macro in CMake (I have no idea what I'm doing tho...)

* try this one weird trick for Python 2 compatibility!

* add note on .rstrip('L') for handling python 2

* Use `__version__.py` (#57)

* use __version__.py to define python version

* add Python/C version check test

* newline

* some questions on the CMake file

* actually, use _version.py for less confusing naming

* note

* Change directory structure, make tests work (#61)

* travis with multiple python versions (#62)

* Add appveyor.yml for Cython

* Disable Python 2.7 test

* Use `__version__.py` (#57)

* use __version__.py to define python version

* add Python/C version check test

* newline

* some questions on the CMake file

* actually, use _version.py for less confusing naming

* note

* Change directory structure, make tests work (#61)

* linting

* linting

* fix purge command

* clean up requirements a bit

* messing with travis

* more travis

* try travis again

* clean up requirements a bit more

* test more python versions, including 2.7

* cmake version thing

* py3.5 doesn't seem to work with cmake

* run all tests in test directory

* remove fabfile

* make sure fails on lint

* get lint to pass

* fix purge command

* bare bones requirements-dev.txt

* use `pytest tests/*` in CI configs

* no need for a `MANIFEST.in` anymore

* fix windows wildcard?

* whatever you want, Windows.

* Basic code coverage (#63)

* basic code coverage

* rename error types and drop prefix on h3ilb.H3int

* Rework some internal names (#65)

* rename `h3utils` to `util`

* typo in cmakelists

* rename `h3_core` to `memview_int` to match format of other interfaces

* linting passes on tests

* make sure travis lints the tests

* getting better coverage on the interfaces

* newline

* add `array_int` (numpy) tests

* install numpy

* make sure appveyor is running all the tests

* dev readme changes

* setup.py changes

* more setup.py changes

* Polyfill working on polygons with holes (#71)

* jupyter lab makefile target for testing

* got polyfill with holes working

* linting

* docstring for h3_to_geo

* improve coverage

* ignoring more flake rules, whilst listening to one

* make polyfill resolution a required positional argument

* use boolean lnglat_order instead of string

* move polyfill tests to own file

* test polyfill polygon input permutations (clockwise vs counterclockwise elements and closed or open loops)

* update description of polyfill inputs

* comment on test

* lint things up

* add some test comments

* don't need to check for null before free

* Add `h3_set_to_multi_polygon` (#74)

* got to_multipolygon workin

* clean up code and add a simple test

* don't need this import

* moved the to_multipoly stuff to own file

* got the geo_json bit working

* add some tests

* linting

* file rename

* update renaming thoughts

* clean up usage of H3int

* no globs!

* don't need this "mercator" business

* rename `check_addr` to `check_cell`

* `destroyLinkedPolygon` note

* rename geo2coord to deg2coord and coord2geo to coord2deg

* Get original test suite working (#79)

* got to_multipolygon workin

* clean up code and add a simple test

* don't need this import

* moved the to_multipoly stuff to own file

* got the geo_json bit working

* add some tests

* linting

* file rename

* update renaming thoughts

* clean up usage of H3int

* getting some more of the original tests to work

* get a bunch of tests working!

* got some more tests working

* got all but one test passing; modified some tests that no longer need to fail

* update test, based on what I think the right result is

* update test for uni edge

* all linty fresh now

* split `out_collection` into `out_ordered` and `out_unordered`

* upgrade to h3core 3.6.1

* bump version

* add notes on empty array inputs

* 100% code coverage (#82)

* add int/str conversion test

* 100% codecov!

* linting

* remove notes

* to `not` or not to `not`

* gotta have a badge!

* Get tox working (#83)

* use relative imports

* clean up some messages

* simplify dynamic api modules a bit

* making some adjustments for tox

* update appveyor script

* remove linux wheel-building code, as i think it is out of date

* fix edge_is_valid test

* linting

* add some badges

* mess with travisci a little bit

* more messing with travis

* flake8 issue

* continue trying to fix flake issue

* we'll get it eventually

* messing with cmake

* revert the travis.yml file; add flake8 to tox

* and revert cmake pin

* messing with appveyor

* revert appveyor change. not sure how to wildcard in appveyor

* separate flake8 in tox envs

* move `cell` and `edge` functions to separate files

* have api import almost everything from core.py

* get outta here, flake8!

* clean up `_api_template.py`

* clean up int -> hex conversion function

* notes on `move_nonzeros()`

* more notes

* refactor so that all cython code is used via `h3.core`

* move noqa

* Convert original test suite to use pytest syntax (#84)

* convert original test suite to use pytest syntax

* making some key hexes obvious

* have travis print the full stack trace on error

* make a few more hex keys obvious

* rework test_compact_malformed_input a bit

* lint!

* formatting

* adding back in a few comments

* move uses of `map` to list comprehensions

* Slightly improve invalid index error reporting (#86)

* slight improvement to invalid index error reporting

* linting

* install notes

* parallel tox doesn't seem that much faster

* use relative imports

* hide h3.core from user api namespace

* noqa on __init__.py

* hides internal modules, but seems to break tox

* remove the testing notebook

* revert files back

* rename `core` to `internal_api`

* add the H3 error types to the public API (for testing)

* add a few function docstrings

* rework errors in tests

* address some comments

* have `create_ptr` do an `except? NULL`, which should be faster than `*`

* version docstring

* Get _cy folder layout working (#87)

* try to get _cy folder layout working

* Fix CMake build

* specify the LIBRARY DESTINATION to be the _cy folder

* move `_internal_api` to `_cy/__init__.py`

* remove version checks in CMakeLists.txt (#88)

* Better API names (#89)

* rename APIs

* rename test files

* remove obsolete comments

* update test files in appveyor

* Use `basic_` prefix instead of `py_`

* makefile

* appveyor!

* API docs

* linting

* tweak docstrings

* missed one!

* Immutability questions for the future

* linting

* module docstrings have to go first

* clarifying API collection input expectations

* input collection tests

* Add more docstrings to the APIs (#91)

* new docstrings

* use pandas docstring guide formatting for the first few functions

* Adding a few more docstrings

* addressing comments

* taking care of comments

* use `H3Cell` instead of `H3Index` to be more precise

* Update h3_get_base_cell

* `h3_is_res_class_III` docstring

* spacing

* move todos to comments

* notes on collections

* module docstring

* polyfill and to_multi_polygon docs

* clean up some docstrings

* address comments

* Segfaults (#92)

* making some segfault notes on `polyfill`

* Allow Cython to handle the error

* notes on tests

* rename test to `test_test_invalid_polygon` and group into single test

* typo

* Add `get_pentagons` function (#95)

* add `get_pentagons`

* linting

* rename to `get_pentagon_indexes`

* Prep cython branch readme before merging cython into master (#98)

* needs more badges!

* prep the readme before merge to master

* add logo

* remove docs folder

* use hex notation in the integer interface test

* conforming to the tyranny of `E222 multiple spaces after operator`

* adding long description to setup.py

* lint

* python 2.7 compatibility

* cell/edge boundary: clean up geo_json branch

* describe why we use `hex` in the error messages instead of `int2hex`

* geofence free notes

* update changelog

* typo

* alg -> algorithm

* remove irrelevant todo

* add distance >= 0 error checking

* add a missing file to appveyor tests

* trying out appveyor

* why won't you listen to reason, appveyor!?

Co-authored-by: Isaac Hier <ihier@uber.com>
Co-authored-by: Isaac Hier <isaachier@gmail.com>
Co-authored-by: Isaac Brodsky <isaac@uber.com>
Co-authored-by: Isaac Brodsky <isaac@isaacbrodsky.com>
Co-authored-by: Kurt Smith <kusmith@homeaway.com>
Co-authored-by: ankitmehta21 <ankitmehta@uber.com>
2020-05-10 11:47:45 -07:00
Isaac Brodsky
ff13deb211
Merge pull request #93 from nastasi-oq/wheel-win64-vs19 v3.4.2
Changes to build wheel for Windows 10 64bit
2020-02-06 08:26:30 -08:00
Matteo Nastasi
77529402bc replaced 'cmake ... -G <visual studio version>' with more generic 'cmake ... -A x64' for 'h3' windows compilation 2020-02-03 11:19:07 +01:00
Matteo Nastasi
98755c6a02 revert to old visual studio 14 for CI reasons, new command as comment 2020-01-20 09:54:51 +01:00
Matteo Nastasi
894d2462dd changes to build wheel for Windows 10 64bit 2020-01-20 09:34:52 +01:00
Isaac Brodsky
440bc11b2f
Merge pull request #77 from isaacbrodsky/readme-git-cmake
README change to mention Git and Cmake version
2019-10-23 13:27:59 -07:00
Isaac Brodsky
9e61b4e5fb Upgrade pytest and pytest-cov 2019-10-22 17:50:59 -07:00
Isaac Brodsky
750a112d1c README change to mention Git and Cmake version 2019-10-21 15:15:08 -07:00
Niel Hu
392fe162f4
Merge pull request #52 from uber/notebooks
Add link of h3-py-notebooks on readme
2019-07-01 14:49:56 -07:00
Niel Hu
8f26f7308c delete docs, add link of h3-py-notebooks on readme 2019-07-01 13:48:07 -07:00
Taikun Liu
a9dae138b9
Upgrade to V3.4.3 (#46)
* upgrade to v3.4.3
2019-04-19 17:16:42 -07:00
Taikun Liu
d087c3051c
remove null values in k_ring_distances and hex_range_distance (#44)
* remove null values in k_ring distance and hex_distance

* add test cases

* rever hex_range changes
2019-04-18 21:54:25 -07:00
Taikun Liu
cb665bec14
update changelog (#45) 2019-04-18 14:09:20 -07:00
Isaac Brodsky
6a2689f834
Merge pull request #39 from isaacbrodsky/appveyor-badge
Add Appveyor badge to README, update H3 badge
2019-03-26 15:40:56 -07:00
Isaac Brodsky
49a0d65c5b Add Appveyor badge to README, update H3 badge 2019-03-26 09:49:41 -07:00
Isaac Brodsky
7ce8f31466 Windows build (#37)
* Improve the tests to check Python 2.7 and 3.6 on all platforms

* Attempt to fix OS X test failures

* Wrong xcode version for mac

* Nevermind on OS X testing, Travis CI removed Python support for it: https://github.com/travis-ci/travis-ci/issues/9929#issuecomment-410386317

* Attempt to adjust the build steps to work for Windows

* Attempt to fix weird error from appveyor after install is finished

* Import the correct library in Windows

* Fix path formatting for Windows

* Modify the ls command to debug

* Try adding a flag that might be missing for Windows

* On Windows it uses a C++ compiler, not C

* No, it was regular C flags needed, but it looks like it tried to expand the flag into a path? So trying with single quotes to hopefully prevent that

* Maybe an escaping backslash will help?

* Forward slash gets converted into a path, backslash did not but also caused problems, lets try backslash by itself?

* Backslash caused windows to think it was a path, maybe nested quotes will solve this shell escaping hell?

* Some more reading implies I shouldn't be setting that variable, but forcing msvcrt.dll to be loaded before running the Windows code

* Fix copy-paste issue

* Another fix

* Make sure it builds a shared lib in Windows, too

* Actually store and load the dll file

* fix lint

* fix lint

* Add Windows dll to project output, as well

* Change H3Index interop type to c_ulonglong

c_long will be the long type, which on Windows is 32 bits. This resulted
in some methods returning broken data (half of the H3Index bits) and in
other methods segfaulting (the polyfill call in the compact test caused
all tests to exit immediately).

Minor adjustment to build script to use `cmake --build` instead of
calling `msbuild.exe` directly.

Adjusted a test to not assert on floating point equality.

* Don't set PATH in Appveyor

* Set path to indicated Python version

* Switch on PYTHON_ARCH and do not build on x86 hosts

* Format the index using `format`

And fix lint

* Test for numbers.Number in num_hexagons test

* Support h3Line

* Standardize on forward slashes

* Detect Windows via the `OS` environment variable

* Automatically determine 32-bit/64-bit interpreter
2019-03-26 01:09:01 -07:00