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
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
max-parallel: 4
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: [3.8, 3.9, '3.10']
platform: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.platform }}

Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/upload_pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ jobs:
max-parallel: 4
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]
platform: [macos-latest, windows-latest] # No wheels on linux yet
python-version: [3.7, 3.8, 3.9, '3.10']
platform: [macos-latest, windows-latest] # Wheels on linux below
runs-on: ${{ matrix.platform }}

steps:
Expand Down Expand Up @@ -55,9 +55,9 @@ jobs:
python -m pip install --upgrade pip
pip install twine
- name: Python wheels manylinux build
uses: RalfG/python-wheels-manylinux-build@v0.3.4
uses: RalfG/python-wheels-manylinux-build@v0.4.0
with:
python-versions: 'cp36-cp36m cp37-cp37m cp38-cp38'
python-versions: 'cp37-cp37m cp38-cp38 cp39-cp39 cp310-cp310'
build-requirements: 'setuptools cython'
- name: Build and publish wheel
env:
Expand All @@ -73,7 +73,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: '3.8'
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
4 changes: 1 addition & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@
install_requires = ['jupyter', 'jupyter-server-proxy', 'numpy', 'ipykernel',
'autobahn>=18.8.2']

if sys.version_info.major == 3 and sys.version_info.minor >= 5:
install_requires.append('autobahn')

setup_args = dict(
name='vpython',
packages=['vpython'],
Expand All @@ -50,6 +47,7 @@
],
ext_modules=extensions,
install_requires=install_requires,
python_requires=">=3.7",
package_data={'vpython': ['vpython_data/*',
'vpython_libraries/*',
'vpython_libraries/images/*']},
Expand Down
16 changes: 1 addition & 15 deletions vpython/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,7 @@
# __gs_version__ exist before importing vpython, which itself imports
# both of those.

from ._notebook_helpers import _isnotebook, __is_spyder
import sys
__v = sys.version_info

# Delete sys now that we are done with it
del sys

__ispython3 = (__v.major == 3)
__require_notebook = (not __ispython3) or (__v.minor < 5) # Python 2.7 or 3.4 require Jupyter notebook

if __require_notebook and (not _isnotebook):
s = "The non-notebook version of vpython requires Python 3.5 or later."
s += "\nvpython does work on Python 2.7 and 3.4 in the Jupyter notebook environment."
raise Exception(s)

from ._notebook_helpers import __is_spyder

from .vpython import canvas

Expand Down
7 changes: 1 addition & 6 deletions vpython/vpython.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,8 @@
'standardAttributes', 'text', 'textures', 'triangle', 'vertex',
'wtext', 'winput', 'keysdown']

__p = platform.python_version()
_ispython3 = (__p[0] == '3')

if _ispython3:
from inspect import signature # Python 3; needed to allow zero arguments in a bound function
else:
from inspect import getargspec # Python 2; needed to allow zero arguments in a bound function
from inspect import signature # Python 3; needed to allow zero arguments in a bound function

# __version__ is the version number of the Jupyter VPython installer, generated in building the installer.
version = [__version__, 'jupyter']
Expand Down