title: Trouble loading Python in RStudio with reticulate
body: <p>I am trying to run a R Markdown document which uses both R and Python code chunks. I am on macOS Catalina version 10.15.2, R version is 3.6.2 and RStudio version is 1.2.5033. I am using the <code>reticulate</code> package version 1.14.</p>
  
  <p><code>which python</code> on the Terminal reveals <code>/Users/dhirajkhanna/opt/anaconda3/bin/python</code> and the same is entered in my <code>.Renviron</code> file as <code>RETICULATE_PYTHON=/Users/dhirajkhanna/opt/anaconda3/bin/python</code>. Strangely when I do <code>Sys.which('python')</code> in my RStudio console, it shows me a different path, viz. <code>/usr/bin/python</code>. When I load the <code>reticulate</code> package, the output of <code>py_config()</code> is:</p>
  
  <pre><code>python:         /usr/local/bin/python3
  libpython:      /usr/local/opt/python/Frameworks/Python.framework/Versions/3.7/lib/python3.7/config-3.7m-darwin/libpython3.7.dylib
  pythonhome:     /usr/local/Cellar/python/3.7.4/Frameworks/Python.framework/Versions/3.7:/usr/local/Cellar/python/3.7.4/Frameworks/Python.framework/Versions/3.7
  version:        3.7.4 (default, Jul  9 2019, 18:13:23)  [Clang 10.0.1 (clang-1001.0.46.4)]
  numpy:          /usr/local/lib/python3.7/site-packages/numpy
  numpy_version:  1.16.4
  
  python versions found: 
   /usr/bin/python3
   /usr/local/bin/python3
   /usr/bin/python
   /usr/local/bin/python
   /Users/dhirajkhanna/anaconda3/bin/python
   /Users/dhirajkhanna/.virtualenvs/object_recognition_detection/bin/python
   /Users/dhirajkhanna/.virtualenvs/object_recognition_detection1/bin/python
   /Users/dhirajkhanna/.virtualenvs/r-tensorflow/bin/python
   /Users/dhirajkhanna/venv/bin/python
  </code></pre>
  
  <p>If I specify, <code>use_python('/Users/dhirajkhanna/opt/anaconda3/bin/python')</code>, the output of <code>py_config()</code> is:</p>
  
  <pre><code>python:         /Users/dhirajkhanna/opt/anaconda3/bin/python
  libpython:      /Users/dhirajkhanna/opt/anaconda3/lib/libpython3.7m.dylib
  pythonhome:     /Users/dhirajkhanna/opt/anaconda3:/Users/dhirajkhanna/opt/anaconda3
  version:        3.7.5 (default, Oct 25 2019, 10:52:18)  [Clang 4.0.1 (tags/RELEASE_401/final)]
  numpy:          /Users/dhirajkhanna/opt/anaconda3/lib/python3.7/site-packages/numpy
  numpy_version:  1.17.3
  
  python versions found: 
   /Users/dhirajkhanna/opt/anaconda3/bin/python
   /usr/bin/python3
   /usr/local/bin/python3
   /usr/bin/python
   /usr/local/bin/python
   /Users/dhirajkhanna/anaconda3/bin/python
   /Users/dhirajkhanna/.virtualenvs/object_recognition_detection/bin/python
   /Users/dhirajkhanna/.virtualenvs/object_recognition_detection1/bin/python
   /Users/dhirajkhanna/.virtualenvs/r-tensorflow/bin/python
   /Users/dhirajkhanna/venv/bin/python
  </code></pre>
  
  <p>Now when I try to load Python packages in a Python code chunk, RStudio crashes:</p>
  
  <pre><code>import pandas as pd
  import matplotlib.pyplot as plt
  </code></pre>
  
  <p>I get the "R Session Aborted" message. All this was working fine till I upgraded R. Any idea how to rectify this?</p>
  
  <p><strong>Edit</strong></p>
  
  <p>While trying this in R, I get a segmentation error:</p>
  
  <pre><code>&gt; library(reticulate)
  &gt; repl_python()
  Python 3.7.6 (/Users/dhirajkhanna/opt/anaconda3/bin/python)
  Reticulate 1.14 REPL -- A Python interpreter in R.
  &gt;&gt;&gt; import pandas as pd
  
   *** caught segfault ***
  address 0x0, cause 'memory not mapped'
  
  Traceback:
   1: py_eval_impl(code, convert)
   2: py_eval("_", convert = FALSE)
   3: doTryCatch(return(expr), name, parentenv, handler)
   4: tryCatchOne(expr, names, parentenv, handlers[[1L]])
   5: tryCatchList(expr, classes, parentenv, handlers)
   6: tryCatch(py_eval("_", convert = FALSE), error = function(e) r_to_py(NULL))
   7: py_last_value()
   8: py_compile_eval(code)
   9: doTryCatch(return(expr), name, parentenv, handler)
  10: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  11: tryCatchList(expr, classes, parentenv, handlers)
  12: tryCatch(py_compile_eval(code), error = handle_error)
  13: repl()
  14: repl_python()
  
  Possible actions:
  1: abort (with core dump, if enabled)
  2: normal R exit
  3: exit R without saving workspace
  4: exit R saving workspace
  Selection: 
  </code></pre>
  
  <p>I have also tried running a different version of Python (3.6) in a virtualenv but still no joy.</p>