Skip to content

Fix docs #1076

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

Merged
merged 8 commits into from
Feb 26, 2019
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
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ examples/results/*
/_mac/*.xml
/inspection/*.xml
geckodriver.log
geckodriver.tar.gz
geckodriver/
miniconda.sh
71 changes: 42 additions & 29 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,56 +15,63 @@ env:
matrix:
fast_finish: true
include:
- name: default-python2
env: TEST_TARGET=default PY=2.7
- name: legacy-python
env: PY=2.7
- name: default
env: TEST_TARGET=default PY=3.7
env: PY=3.7
- name: notebooks-conding-standard
env: PY=3.7
- name: notebooks-code
env: PY=3.7
- name: latest_branca
- name: latest-branca
env: PY=3.7
- name: docs
env: PY=3.7
allow_failures:
- name: latest_branca
- name: latest-branca
env: PY=3.7

before_install:
- wget http://bit.ly/miniconda -O miniconda.sh
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- conda config --set always_yes yes --set changeps1 no --set show_channel_urls true
- conda update conda
- conda config --remove channels defaults --force
- conda config --add channels conda-forge --force
- conda create --name TEST python=$PY --file requirements.txt --file requirements-dev.txt
- source activate TEST
# firefox headless driver
- wget https://github.com/mozilla/geckodriver/releases/download/v0.23.0/geckodriver-v0.23.0-linux64.tar.gz -O geckodriver.tar.gz
- mkdir geckodriver
- tar -xzf geckodriver.tar.gz -C geckodriver
- export PATH=$PATH:$PWD/geckodriver

- if [[ "$PY" == "2.7" ]]; then
conda install mock ;
fi
# Install miniconda and create TEST env.
- |
wget http://bit.ly/miniconda -O miniconda.sh
bash miniconda.sh -b -p $HOME/miniconda
export PATH="$HOME/miniconda/bin:$PATH"
conda config --set always_yes yes --set changeps1 no --set show_channel_urls true
conda update conda --quiet
conda config --add channels conda-forge --force
conda install pycryptosat
conda config --set safety_checks disabled
conda config --set channel_priority strict
conda create --name TEST python=$PY --file requirements.txt --file requirements-dev.txt
source activate TEST
# Install firefox headless driver.
- |
wget https://github.com/mozilla/geckodriver/releases/download/v0.23.0/geckodriver-v0.23.0-linux64.tar.gz -O geckodriver.tar.gz
mkdir geckodriver
tar -xzf geckodriver.tar.gz -C geckodriver
export PATH=$PATH:$PWD/geckodriver


# Test source distribution.
install:
- python setup.py sdist && version=$(python setup.py --version) && pushd dist && pip install folium-${version}.tar.gz && popd
- python setup.py sdist && version=$(python setup.py --version) && pushd dist && pip install --no-deps --force-reinstall folium-${version}.tar.gz && popd

script:
- if [[ $TRAVIS_JOB_NAME != 'docs' ]]; then
cp -r tests/ examples/ /tmp ;
fi

- if [[ $TEST_TARGET == 'default' ]]; then
- if [[ $TRAVIS_JOB_NAME == 'default' ]]; then
pytest /tmp -vv --ignore=tests/notebooks/test_notebooks.py ;
fi

- if [[ $TRAVIS_JOB_NAME == 'legacy-python' ]]; then
conda install mock ;
pytest /tmp -vv --ignore=tests/notebooks/test_notebooks.py ;
fi

- if [[ $TRAVIS_JOB_NAME == 'latest_branca' ]]; then
- if [[ $TRAVIS_JOB_NAME == 'latest-branca' ]]; then
conda uninstall branca ;
pip install git+https://github.com/python-visualization/branca.git ;
pytest /tmp -vv --ignore=tests/notebooks/test_notebooks.py ;
Expand All @@ -80,15 +87,21 @@ script:
pytest --nbval-lax -p no:python /tmp/examples ;
fi

- if [[ $TEST_TARGET == 'docs' ]]; then
# Docs
- if [[ -z "$TRAVIS_TAG" ]]; then
DEPLOY_DIR=dev ;
else
DEPLOY_DIR="version-$TRAVIS_TAG" ;
fi

- if [[ $TRAVIS_JOB_NAME == 'docs' ]]; then
set -e ;
conda install doctr ;
cp examples/Quickstart.ipynb docs/quickstart.ipynb ;
pushd docs ;
make clean html linkcheck ;
popd ;
python -m doctr deploy --sync .;
python -m doctr deploy --sync --no-require-master --built-docs docs/_build/html "docs-$TRAVIS_BRANCH" ;
python -m doctr deploy --build-tags --key-path github_deploy_key.enc --built-docs docs/_build/html/ $DEPLOY_DIR ;
fi

doctr:
Expand Down
4 changes: 1 addition & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,8 @@ or
Documentation
-------------

https://python-visualization.github.io/folium/docs-v0.6.0/
https://python-visualization.github.io/folium/

The documentation for the development version can be found here:
https://python-visualization.github.io/folium/docs-master/

Gallery
-------
Expand Down
2 changes: 1 addition & 1 deletion examples/Quickstart.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"For more information about popups, please visit [Popups.ipynb](http://nbviewer.jupyter.org/github/python-visualization/folium/blob/master/examples/Popups.ipynb)"
"For more information about popups, please visit [Popups.ipynb](https://nbviewer.jupyter.org/github/python-visualization/folium/blob/master/examples/Popups.ipynb)"
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion folium/features.py
Original file line number Diff line number Diff line change
Expand Up @@ -700,7 +700,7 @@ class GeoJsonTooltip(Tooltip):
This will use JavaScript's .toLocaleString() to format 'clean' values
as strings for the user's location; i.e. 1,000,000.00 comma separators,
float truncation, etc.
*Available for most of JavaScript's primitive types (any data you'll
\*Available for most of JavaScript's primitive types (any data you'll
serve into the template).
style: str, default None.
HTML inline style properties like font and colors. Will be applied to
Expand Down
2 changes: 1 addition & 1 deletion folium/plugins/antpath.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AntPath(Marker):
Latitude and Longitude of line (Northing, Easting)
popup: str or folium.Popup, default None
Input text or visualization for object displayed when clicking.
tooltip: str or folium.Tooltip, optional
tooltip: str or folium.Tooltip, optional
Display a text when hovering over the object.
**kwargs:
Polyline and AntPath options. See their Github page for the
Expand Down
7 changes: 4 additions & 3 deletions folium/plugins/beautify_icon.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,13 @@ class BeautifyIcon(MacroElement):
--------
Plugin Website: https://github.com/marslan390/BeautifyMarker
>>> BeautifyIcon(text_color='#000', border_color='transparent',
background_color='#FFF').add_to(marker)
... background_color='#FFF').add_to(marker)
>>> number_icon = BeautifyIcon(text_color='#000', border_color='transparent',
background_color='#FFF', number=10,
inner_icon_style='font-size:12px;padding-top:-5px;')
... background_color='#FFF', number=10,
... inner_icon_style='font-size:12px;padding-top:-5px;')
>>> Marker(location=[45.5, -122.3], popup=folium.Popup('Portland, OR'), icon=number_icon)
>>> BeautifyIcon(icon='arrow-down', icon_shape='marker').add_to(marker)

"""
ICON_SHAPE_TYPES = ['circle', 'circle-dot', 'doughnut', 'rectangle-dot',
'marker', None]
Expand Down
2 changes: 2 additions & 0 deletions folium/plugins/timestamped_geo_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class TimestampedGeoJson(MacroElement):
into a map with Map.add_child.

A geo-json is timestamped if:

* it contains only features of types LineString, MultiPoint, MultiLineString,
Polygon and MultiPolygon.
* each feature has a 'times' property with the same length as the
Expand All @@ -32,6 +33,7 @@ class TimestampedGeoJson(MacroElement):
----------
data: file, dict or str.
The timestamped geo-json data you want to plot.

* If file, then data will be read in the file and fully embedded in
Leaflet's javascript.
* If dict, then data will be converted to json and embedded in the
Expand Down