[session, repository] deprecate repo.connect and move .close reponsibility to session object
Repository.new_session just returns a plain session object, and
`.connect` (which returns a sessionid) is deprecated.
For .close::
session.close() # done !
The session will bear the responsibility to call the "session_close"
event but that's better than the previous idiom::
repo.close(session.sessionid)
which involves both objects.
Related to #1381328.
Related to #2919309.
[tox]
envlist = py27,py34,flake8
[testenv]
sitepackages = true
deps =
pytest
commands =
{envpython} -m pytest {posargs:test}
[testenv:flake8]
skip_install = true
whitelist_externals =
flake8
deps =
flake8
commands = flake8
[flake8]
exclude = migration/*,test/data/*,setup.py,.tox/*