Skip to content

Commit

Permalink
bump version, merge branch 'devel'
Browse files Browse the repository at this point in the history
  • Loading branch information
casperdcl committed Sep 10, 2018
2 parents a2514e8 + ecc99b0 commit 96d8a3c
Show file tree
Hide file tree
Showing 9 changed files with 34 additions and 17 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
*.py[cod]
*.so
/wiki/
/docs/
/feedstock/

# Packages
tqdm.egg-info
Expand Down
13 changes: 12 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -271,4 +271,15 @@ For expereinced devs, once happy with local master:
6. `git tag vM.m.p && git push --tags`
7. `[python setup.py] make distclean`
8. `[python setup.py] make build`
9. `[python setup.py] make pypi`
9. upload to PyPI using one of the following:
a) `[python setup.py] make pypi`
b) `twine upload -s -i $(git config user.signingkey) dist/tqdm-*`
10. create new release on https://github.com/tqdm/tqdm/releases
a) add helpful release notes
b) attach dist/tqdm-* binaries (usually only *.whl*)
11. run `make` in the `wiki` submodule to update release notes
12. run `make deploy` in the `docs` submodule to update website
13. accept the automated PR in the `feedstock` submodule to update conda

The last thee steps require a one-time `make submodules` to clone
`docs`, `wiki`, and `feedstock`.
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,11 @@ toxclean:
installdev:
python setup.py develop --uninstall
python setup.py develop
submodules:
git clone git@github.com:tqdm/tqdm.wiki wiki
git clone git@github.com:tqdm/tqdm.github.io docs
git clone git@github.com:conda-forge/tqdm-feedstock feedstock
cd feedstock && git remote add autotick-bot git@github.com:regro-cf-autotick-bot/tqdm-feedstock

install:
python setup.py install
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ Authors
-------

The main developers, ranked by surviving lines of code
(`git fame -wMC <https://github.com/casperdcl/gitfame>`__), are:
(`git fame -wMC <https://github.com/casperdcl/git-fame>`__), are:

- Casper da Costa-Luis (`casperdcl <https://github.com/casperdcl>`__, ~2/3, |Gift-Casper|)
- Stephen Larroque (`lrq3000 <https://github.com/lrq3000>`__, ~1/5)
Expand Down
9 changes: 1 addition & 8 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ commands =
- coveralls
codecov

# no cython/numpy/pandas for py{py,py3,26,33,37}
# no cython/numpy/pandas for py{py,py3,26,33,34}

[testenv:py26]
# no codecov and timer for py26
Expand All @@ -60,13 +60,6 @@ commands = {[extra]commands}

[testenv:py34]
# py34-compatible pandas
deps =
{[extra]deps}
cython
numpy
pandas<0.21

[testenv:py37]
deps = {[extra]deps}
commands = {[extra]commands}

Expand Down
5 changes: 5 additions & 0 deletions tqdm/_tqdm.py
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,10 @@ def inner(df, func, *args, **kwargs):
not isinstance(df, _Rolling_and_Expanding):
# DataFrame or Panel
axis = kwargs.get('axis', 0)
if axis == 'index':
axis = 0
elif axis == 'columns':
axis = 1
# when axis=0, total is shape[axis1]
total = df.size // df.shape[axis]

Expand Down Expand Up @@ -948,6 +952,7 @@ def __iter__(self):
if avg_time is None \
else smoothing * delta_t / delta_it + \
(1 - smoothing) * avg_time
self.avg_time = avg_time

self.n = n
with self._lock:
Expand Down
2 changes: 1 addition & 1 deletion tqdm/_tqdm_notebook.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def status_printer(_, total=None, desc=None, ncols=None):
except NameError:
# #187 #451 #558
raise ImportError(
"IntProgress not found. Please update juputer and ipywidgets."
"IntProgress not found. Please update jupyter and ipywidgets."
" See https://ipywidgets.readthedocs.io/en/stable"
"/user_install.html")

Expand Down
2 changes: 1 addition & 1 deletion tqdm/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
__all__ = ["__version__"]

# major, minor, patch, -extra
version_info = 4, 25, 0
version_info = 4, 26, 0

# Nice string for the version
__version__ = '.'.join(map(str, version_info))
Expand Down
10 changes: 5 additions & 5 deletions tqdm/tests/tests_pandas.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ def test_pandas_rolling_expanding():
tqdm.pandas(file=our_file, leave=True, ascii=True)

series = pd.Series(randint(0, 50, (123,)))
res1 = series.rolling(10).progress_apply(lambda x: 1)
res2 = series.rolling(10).apply(lambda x: 1)
res1 = series.rolling(10).progress_apply(lambda x: 1, raw=True)
res2 = series.rolling(10).apply(lambda x: 1, raw=True)
assert res1.equals(res2)

res3 = series.expanding(10).progress_apply(lambda x: 2)
res4 = series.expanding(10).apply(lambda x: 2)
res3 = series.expanding(10).progress_apply(lambda x: 2, raw=True)
res4 = series.expanding(10).apply(lambda x: 2, raw=True)
assert res3.equals(res4)

expects = ['114it'] # 123-10+1
Expand Down Expand Up @@ -104,7 +104,7 @@ def task_func(x):
assert res1.equals(res2)

# apply
for axis in [0, 1]:
for axis in [0, 1, 'index', 'columns']:
res3 = df.progress_apply(task_func, axis=axis)
res4 = df.apply(task_func, axis=axis)
assert res3.equals(res4)
Expand Down

0 comments on commit 96d8a3c

Please sign in to comment.