Skip to content
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

Fix GitHub Actions setup and test config #55

Merged
merged 1 commit into from
Jan 10, 2022

Conversation

mbrukman
Copy link
Collaborator

Per the most recent GitHub Actions run, fix the setup and test commands:

The list of available Python versions shows Python 3.5 and later are provided.

Minor changes:

  • add Ubuntu 18.04 LTS to the list of OS versions in case folks still use
    it, since it's still supported and may be in use
  • explicitly specify the x64 architecture to clarify that we're running in
    64-bit mode (also the default), as opposed to x86 which would run in 32-bit
    mode

Closes #52

@rossant
Copy link
Owner

rossant commented Jan 10, 2022

Perhaps old versions of Python like 2.7, 3.5, 3.6, may be dropped?

@mbrukman mbrukman force-pushed the fix-github-actions-test-config branch from 4c54d8e to cdbf79d Compare January 10, 2022 20:40
@mbrukman
Copy link
Collaborator Author

Perhaps old versions of Python like 2.7, 3.5, 3.6, may be dropped?

Done.

@mbrukman mbrukman force-pushed the fix-github-actions-test-config branch from cdbf79d to e71e43b Compare January 10, 2022 20:43
Per the most recent GitHub Actions run, fix the setup and test commands:

* remove `--use-mirrors` flag from the `pip` command as it's no longer a valid
  option [failed pip run](https://github.com/rossant/ipycache/runs/4766646133)
* remove old Python versions (2.7, 3.3, 3.4, 3.5, 3.6)
  * Python 3.3 and 3.4 are not available on macOS ([failed Python 3.3 install],
    [failed Python 3.4 install])

Python 3.10 was removed since `nosetests` is not compatible with it, nor is it
maintained any more. We will need to migrate to nose2 or pytest instead.

The list of [available Python versions] shows provided Python versions.

Minor changes:

* add Ubuntu 18.04 LTS to the list of OS versions in case folks still use
  it, since it's still supported and may be in use
* explicitly specify the `x64` architecture to clarify that we're running in
  64-bit mode (also the default), as opposed to `x86` which would run in 32-bit
  mode

Closes rossant#52

[failed pip run]: https://github.com/rossant/ipycache/runs/4766646133
[failed Python 3.3 install]: https://github.com/rossant/ipycache/runs/4766646186
[failed Python 3.4 install]: https://github.com/rossant/ipycache/runs/4766646247
[available Python versions]: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json
@mbrukman mbrukman force-pushed the fix-github-actions-test-config branch from e71e43b to 49a47a5 Compare January 10, 2022 20:51
@mbrukman
Copy link
Collaborator Author

@rossant — since we've removed testing with Python 2.7, should we also remove special-casing for Python 2 (see below), or should we bring back the tests for Python 2.7 to keep backwards-compatibility? I know Python 2.x was EOL as of Jan 2020, but maybe some folks somewhere are still depending on using it (somehow)?

ipycache/ipycache.py

Lines 28 to 52 in ebefe10

PY2 = sys.version_info[0] == 2
PY3 = sys.version_info[0] == 3
if PY3:
import pickle, builtins
from io import StringIO
_iteritems = "items"
exec_ = getattr(builtins, "exec")
else:
import cPickle as pickle
from StringIO import StringIO
_iteritems = "iteritems"
def exec_(_code_, _globs_=None, _locs_=None):
"""Execute code in a namespace."""
if _globs_ is None:
frame = sys._getframe(1)
_globs_ = frame.f_globals
if _locs_ is None:
_locs_ = frame.f_locals
del frame
elif _locs_ is None:
_locs_ = _globs_
exec("""exec _code_ in _globs_, _locs_""")

@rossant
Copy link
Owner

rossant commented Jan 10, 2022

I think it's fine to drop Python 2.x support. Maybe add a tag before doing it to be on the safe side..

@mbrukman mbrukman merged commit 7b968d0 into rossant:master Jan 10, 2022
@mbrukman mbrukman deleted the fix-github-actions-test-config branch January 10, 2022 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate from Travis CI to GitHub Actions
2 participants