diff --git a/.stickler.yml b/.stickler.yml new file mode 100644 index 0000000000..734d07974a --- /dev/null +++ b/.stickler.yml @@ -0,0 +1,6 @@ +linters: + flake8: + max-line-length: 100 + max-complexity: 10 +files: + ignore: ['*.ipynb', 'conf.py'] diff --git a/.travis.yml b/.travis.yml index 525dca3aae..7e2837f436 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,22 +10,24 @@ matrix: fast_finish: true include: - python: 2.7 - env: TEST_TARGET=branca_release - - python: 3.5 - env: TEST_TARGET=branca_release - - python: 3.5 - env: TEST_TARGET=coding_standards + env: TEST_TARGET=default + - python: 3.4 + env: TEST_TARGET=default - python: 3.5 + env: TEST_TARGET=default + - python: 3.6 + env: TEST_TARGET=default + - python: 3.6 env: TEST_TARGET=notebooks - python: 2.7 - env: TEST_TARGET=branca_latest - - python: 3.5 - env: TEST_TARGET=branca_latest + env: TEST_TARGET=latest_branca + - python: 3.6 + env: TEST_TARGET=latest_branca allow_failures: - python: 2.7 - env: TEST_TARGET=branca_latest - - python: 3.5 - env: TEST_TARGET=branca_latest + env: TEST_TARGET=latest_branca + - python: 3.6 + env: TEST_TARGET=latest_branca before_install: - wget http://bit.ly/miniconda -O miniconda.sh @@ -36,10 +38,10 @@ before_install: - conda create --yes -n TEST python=$TRAVIS_PYTHON_VERSION --file requirements.txt --file requirements-dev.txt - source activate TEST - - if [[ "$TRAVIS_PYTHON_VERSION" != "3.5" ]]; then + - if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then conda install --yes mock ; fi - - if [[ "$TRAVIS_PYTHON_VERSION" == "3.5" ]]; then + - if [[ "$TRAVIS_PYTHON_VERSION" == "3.6" ]]; then conda install --yes doctr ; fi @@ -48,21 +50,17 @@ install: - python setup.py sdist && version=$(python setup.py --version) && pushd dist && pip install folium-${version}.tar.gz && popd script: - - if [[ $TEST_TARGET == 'branca_release' ]]; then + - if [[ $TEST_TARGET == 'default' ]]; then py.test -vv --ignore=tests/notebooks/test_notebooks.py ; fi - - if [[ $TEST_TARGET == 'branca_latest' ]]; then + - if [[ $TEST_TARGET == 'latest_branca' ]]; then pip install git+https://github.com/python-visualization/branca.git ; python setup.py test ; fi - - if [[ $TEST_TARGET == 'coding_standards' ]]; then - find . -type f -name "*.py" ! -name 'conf.py' | xargs flake8 --max-line-length=100 ; - for file in $(find . -type f -name "*.ipynb"); do jupyter nbconvert --template=tests/strip_markdown.tpl --stdout --to python $file | grep -v '^get_ipython' | flake8 - --ignore=W391,E226,E402 --max-line-length=100 --show-source ; done ; - fi - - if [[ $TEST_TARGET == 'notebooks' ]]; then + for file in $(find . -type f -name "*.ipynb"); do jupyter nbconvert --template=tests/strip_markdown.tpl --stdout --to python $file | grep -v '^get_ipython' | flake8 - --ignore=W391,E226,E402 --max-line-length=100 --show-source ; done ; py.test -vv tests/notebooks/test_notebooks.py ; doctr deploy --built-docs=examples/results --gh-pages-docs=gallery ; fi diff --git a/CHANGES.txt b/CHANGES.txt index 286ba4cd57..d9421c35c6 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -12,6 +12,7 @@ - Added `fullscreen` plugin (sanga #437) - Added `smooth_factor `option to `GeoJSON`, `TopoJSON` and `Choropleth` (JamesGardiner #428) - `Map` object now accepts Leaflet global switches (sgvandijk #424) +- Added weight option to CircleMarker (palewire #581) Bug Fixes @@ -20,6 +21,7 @@ Bug Fixes - Fixed MIME type (text/plain) is not executable (talespaiva #440) - Update Travis-CI testing to incorporate branca and fix notebook tests (ocefpaf #436) - Removed MultiPolyLine and MultiPolygon, both are handled by PolyLine and PolyLine in leaflet 1.0.* (ocefpaf #554) +- Removed deprecated MapQuest tiles (HashCode55 #562) 0.2.1 ~~~~~ diff --git a/MANIFEST.in b/MANIFEST.in index fc441e0581..b41c3a31f7 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -4,3 +4,4 @@ recursive-include folium *.py recursive-include folium *.js recursive-include folium/plugins * recursive-include folium/templates * +prune examples/ diff --git a/folium/__init__.py b/folium/__init__.py index d8eefd8b21..ea4f8fe8be 100644 --- a/folium/__init__.py +++ b/folium/__init__.py @@ -17,7 +17,7 @@ TopoJson, WmsTileLayer ) -__version__ = '0.3.0.dev' +__version__ = '0.3.0' __all__ = [ 'CssLink', diff --git a/folium/features.py b/folium/features.py index 57c472a100..35668e5df7 100644 --- a/folium/features.py +++ b/folium/features.py @@ -68,8 +68,6 @@ def __init__(self, url, name=None, layers=None, styles=None, format=None, self.format = format if format else 'image/jpeg' self.transparent = transparent self.version = version - # FIXME: Should be map CRS! - # self.crs = crs if crs else 'null self._template = Template(u""" {% macro script(this, kwargs) %} var {{this.get_name()}} = L.tileLayer.wms( diff --git a/folium/plugins/scroll_zoom_toggler.py b/folium/plugins/scroll_zoom_toggler.py index 1390e63707..b68c33cfc6 100644 --- a/folium/plugins/scroll_zoom_toggler.py +++ b/folium/plugins/scroll_zoom_toggler.py @@ -37,7 +37,7 @@ def __init__(self): {% macro html(this,kwargs) %} scroll {% endmacro %} diff --git a/requirements-dev.txt b/requirements-dev.txt index 68c086e794..ef3e0855c6 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,4 +1,4 @@ -flake8 +pycodestyle pytest nbconvert jupyter_client