Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .stickler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
linters:
flake8:
max-line-length: 100
max-complexity: 10
files:
ignore: ['*.ipynb', 'conf.py']
38 changes: 18 additions & 20 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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

Expand All @@ -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
2 changes: 2 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand All @@ -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
~~~~~
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ recursive-include folium *.py
recursive-include folium *.js
recursive-include folium/plugins *
recursive-include folium/templates *
prune examples/
2 changes: 1 addition & 1 deletion folium/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
TopoJson, WmsTileLayer
)

__version__ = '0.3.0.dev'
__version__ = '0.3.0'

__all__ = [
'CssLink',
Expand Down
2 changes: 0 additions & 2 deletions folium/features.py
Original file line number Diff line number Diff line change
Expand Up @@ -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(
Expand Down
2 changes: 1 addition & 1 deletion folium/plugins/scroll_zoom_toggler.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def __init__(self):
{% macro html(this,kwargs) %}
<img id="{{this.get_name()}}" alt="scroll"
src="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/png/512/arrow-move.png"
style="z-index: 999999"
style="z-index: 999999"
onclick="{{this._parent.get_name()}}.toggleScroll()">
</img>
{% endmacro %}
Expand Down
2 changes: 1 addition & 1 deletion requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
flake8
pycodestyle
pytest
nbconvert
jupyter_client
Expand Down