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
10 changes: 9 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,15 @@ notifications:
before_script:
- echo ./ci/install-julia.sh "$JULIA_VERSION"
- ./ci/install-julia.sh "$JULIA_VERSION"
- if [ "$TRAVIS_OS_NAME" = "osx" -a "$PYTHON" = "python3" ]; then brew update; brew upgrade python || echo "Ignoring errors..."; fi
- if [ "$TRAVIS_OS_NAME" = "osx" -a "$PYTHON" = "python3" ];
then
brew update;
brew upgrade python || echo "Ignoring errors...";
if ! which $PYTHON;
then
PYTHON="$(ls -1 /usr/local/opt/python@3.*/bin/python3 | head -n1)";
fi;
fi
- if [ "$TRAVIS_OS_NAME" = "osx" -a "$PYTHON" = "python2" ]; then brew update; brew list python@2 &>/dev/null || brew install python@2 || echo "Ignoring errors..."; fi
# Ignoring errors from brew since it may actually be OK to do so.
# Following which command will catch installation failure:
Expand Down
8 changes: 6 additions & 2 deletions src/julia/magic.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,16 @@
import warnings

from IPython.core.magic import Magics, line_cell_magic, magics_class
from IPython.utils import py3compat as compat
from traitlets import Bool, Enum

from .core import Julia, JuliaError
from .tools import redirect_output_streams

try:
unicode
except NameError:
unicode = str

try:
from IPython.core.magic import no_var_expand
except ImportError:
Expand Down Expand Up @@ -103,7 +107,7 @@ def julia(self, line, cell=None):
Execute code in Julia, and pull some of the results back into the
Python namespace.
"""
src = compat.unicode_type(line if cell is None else cell)
src = unicode(line if cell is None else cell)

# We assume the caller's frame is the first parent frame not in the
# IPython module. This seems to work with IPython back to ~v5, and
Expand Down
1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ envlist = py3
[testenv]
deps =
pytest-cov
coverage < 5
extras =
test
commands =
Expand Down