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
47 changes: 31 additions & 16 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,39 @@
language: python

python:
- '2.7'
- '3.8'
- '3.7'
- '3.6'
- '3.5'
- '3.4'
- '2.7'

install:
- pip install -r requirements.txt
- pip install -r test-requirements.txt
- pip install tox-travis

script: tox

script:
- nosetests
- flake8
jobs:
include:
- stage: test
name: pep8
python: 3.8
script: tox -e pep8
- name: latest
python: 3.8
script: tox -e latest

deploy:
provider: pypi
user: internaphosting
password:
secure: fZxfMePJQroeiLQb+lmpNiEEMvRONOVt4yTQY8CmemyVMOe4TVZUfsBzCMa7eZkUaFZuHfNaUo/4Jmhn15EruzGhqBLRe5fpuFxFqJqDJ7ZmPMTRBIMKUsRuYrG6vc9YmG8CLfLvxwG8OUoLzND+rz+QwWaFruFeDlkCN3xMpzRHcdopcKlKoKwUJCkPzqEm0qeziTsRNixLbrBHzfr+FY96FDclE2GDywUBCacPzwP+R9QwPKU74NevlD+MazP/bYcZHY8DKDQ2X4L7NSr/8osJswVvCCoOqqqFPsPLaVzhDLU1hvTSW44K3hUSlRmKWzmdfFutkPix4Zrge9JYzTOodV921WgFLSsSPcpwEoRMZM21hoFhO6PThd9ag33z1rUxXzAJxBYfjM5OP+2g6gqWDptyJp8OgdqjzoCKFsXBrINf+vb+Ossdtl2+W1fzBjHlV9D8t6gf7ekJZmTAKzfYcvrRc++gnZwlwmPWrr5qBUSxT9SEqln7L/u4RbHxZdAOzYivPBvrL1ncdwUx9kvzbelr1wolc0aszodRgx8S7aWZ7V4CbuE6LpNkRREJ+EY71MYInpCRO81XabAIEG7T7i11ZkNexxQAe5Mafy/nSw5cGWirIAcLEO7WU3tSd5rteP7hgp28VJ9XfGZPwH9Q1FqiNMpKk+Db6PwplDE=
on:
tags: true
python: 3.4
distributions: sdist bdist_wheel
repo: internap/python-ubersmithclient
- stage: deploy
python: 3.8
script: skip
deploy:
provider: pypi
user: internaphosting
password:
secure: fZxfMePJQroeiLQb+lmpNiEEMvRONOVt4yTQY8CmemyVMOe4TVZUfsBzCMa7eZkUaFZuHfNaUo/4Jmhn15EruzGhqBLRe5fpuFxFqJqDJ7ZmPMTRBIMKUsRuYrG6vc9YmG8CLfLvxwG8OUoLzND+rz+QwWaFruFeDlkCN3xMpzRHcdopcKlKoKwUJCkPzqEm0qeziTsRNixLbrBHzfr+FY96FDclE2GDywUBCacPzwP+R9QwPKU74NevlD+MazP/bYcZHY8DKDQ2X4L7NSr/8osJswVvCCoOqqqFPsPLaVzhDLU1hvTSW44K3hUSlRmKWzmdfFutkPix4Zrge9JYzTOodV921WgFLSsSPcpwEoRMZM21hoFhO6PThd9ag33z1rUxXzAJxBYfjM5OP+2g6gqWDptyJp8OgdqjzoCKFsXBrINf+vb+Ossdtl2+W1fzBjHlV9D8t6gf7ekJZmTAKzfYcvrRc++gnZwlwmPWrr5qBUSxT9SEqln7L/u4RbHxZdAOzYivPBvrL1ncdwUx9kvzbelr1wolc0aszodRgx8S7aWZ7V4CbuE6LpNkRREJ+EY71MYInpCRO81XabAIEG7T7i11ZkNexxQAe5Mafy/nSw5cGWirIAcLEO7WU3tSd5rteP7hgp28VJ9XfGZPwH9Q1FqiNMpKk+Db6PwplDE=
on:
tags: true
distributions: sdist bdist_wheel
repo: internap/python-ubersmithclient
allow_failures:
- name: latest
26 changes: 26 additions & 0 deletions constraints.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#
# This file is autogenerated by pip-compile
# To update, run:
#
# pip-compile --no-emit-trusted-host --no-index --output-file=constraints.txt setup.py test-requirements.txt
#
certifi==2019.11.28 # via requests
chardet==3.0.4 # via requests
click==7.0 # via pip-tools
entrypoints==0.3 # via flake8
flake8==3.7.9
idna==2.8 # via requests
mccabe==0.6.1 # via flake8
mock==3.0.5
nose==1.3.7
pip-tools==3.9.0
pycodestyle==2.5.0 # via flake8
pyflakes==2.1.1 # via flake8
pyhamcrest==1.9.0
requests==2.21.0
six==1.14.0 # via mock, pip-tools, pyhamcrest
typing==3.7.4.1 # via flake8
urllib3==1.24.3 # via requests

# The following packages are considered to be unsafe in a requirements file:
# setuptools==43.0.0 # via pyhamcrest
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
pbr>=1.8
requests
6 changes: 6 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ classifier =
Operating System :: POSIX
Programming Language :: Python :: 2.7
Programming Language :: Python :: 3.4
Programming Language :: Python :: 3.5
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
description-file = README.rst
description-content-type = text/x-rst; charset=UTF-8

[files]
packages =
Expand Down
7 changes: 4 additions & 3 deletions test-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
nose==1.2.1
pyhamcrest==1.8.1
mock==1.3.0
nose
pyhamcrest<2.0.0
mock
flake8
pip-tools
19 changes: 18 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,15 +1,32 @@
[tox]
envlist = py34,py27,pep8
envlist = py34,py35,py36,py37,py38,py27,pep8

[testenv]
deps = -r{toxinidir}/test-requirements.txt
install_command = python -m pip install -c constraints.txt {opts} {packages}
commands =
nosetests

[testenv:latest]
deps = -r{toxinidir}/test-requirements.txt
basepython = python3.8
install_command = python -m pip install {opts} {packages}
commands =
nosetests

[testenv:pep8]
deps = -r{toxinidir}/test-requirements.txt
commands = flake8 {posargs}

[testenv:bump-dependencies]
basepython = python3.4
skip_install = true
deps =
pip-tools
commands =
pip-compile --upgrade --no-index --no-emit-trusted-host --output-file constraints.txt setup.py test-requirements.txt


[flake8]
show-source = True
max-line-length = 120
Expand Down
2 changes: 1 addition & 1 deletion ubersmith_client/_http_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def form_encode(data):


def form_encode_without_files(data):
return form_encode({k: v for k, v in data.items() if k is not 'files'})
return form_encode({k: v for k, v in data.items() if k != 'files'})


def _explode_enumerable(k, v):
Expand Down