JuliaPy / JuliaPy/PyCall.jl

Perhaps a seaborn problem

Ouverte
#538 1 commentaire 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Julia
Étoiles
1.5k
Forks
186
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

When attempting @pyimport seaborn, I am told that Python is not installed as a framework. But, it certainly is installed as a framework. PyPlot works. Plots with pyplot backend works. I can pyimport Matplotlib and sys--and probably lots of other Python packages. I'd like to use seaborn, but I can survive without it.

Messages follow and examples of importing Matplotlib and sys (to show the Python version that is invoked):

```
julia> using PyCall

julia> @pyimport seaborn
ERROR: PyError (PyImport_ImportModule)
RuntimeError("Python is not installed as a framework. The Mac OS X backend will not be able to function correctly if Python is not installed as a framework. See the Python documentation for more information on installing Python as a framework on Mac OS X. Please either reinstall Python as a framework, or try one of the other backends. If you are using (Ana)Conda please install python.app and replace the use of 'python' with 'pythonw'. See 'Working with Matplotlib on OSX' in the Matplotlib FAQ for more information.")
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/seaborn/__init__.py", line 6, in
from .rcmod import *
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/seaborn/rcmod.py", line 5, in
from . import palettes, _orig_rc_params
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/seaborn/palettes.py", line 12, in
from .utils import desaturate, set_hls_values, get_color_cycle
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/seaborn/utils.py", line 11, in
import matplotlib.pyplot as plt
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/matplotlib/pyplot.py", line 115, in
_backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup()
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/matplotlib/backends/__init__.py", line 62, in pylab_setup
[backend_name], 0)
File "/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/matplotlib/backends/backend_macosx.py", line 17, in
from matplotlib.backends import _macosx

Stacktrace:
[1] pyimport(::String) at /Users/lewis/.julia/packages/PyCall/akNFy/src/PyCall.jl:479
[2] top-level scope at /Users/lewis/.julia/packages/PyCall/akNFy/src/PyCall.jl:529

julia> @pyimport matplotlib

julia> @pyimport sys

julia> sys.version
"3.7.0 (default, Jul 23 2018, 20:22:55) \n[Clang 9.1.0 (clang-902.0.39.2)]"

julia>
```

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

Commencez par le chemin @pyimport dans PyCall.jl aux lignes 479 et 529, puis reproduisez l’importation de seaborn en utilisant les versions de Python et de matplotlib indiquées dans le rapport. Comparez-la aux importations réussies de matplotlib et de sys ; le travail est terminé lorsqu’il est identifié si PyCall ou le backend matplotlib de macOS provoque l’erreur de framework et que ce comportement est documenté ou corrigé.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
julia, macos, matplotlib, python
Domaine
data-visualization, desktop
Type d'issue
Bug
Difficulté
4/5
Temps estimé
3-5 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
30/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.