Can't get IPython to start: “ImportError: cannot import name start_ipython”












1















I'm trying to start IPython from the terminal. I input:



ipython



into the terminal and I get this output:



Traceback (most recent call last):
File "/usr/local/bin/ipython", line 4, in <module>
from IPython import start_ipython
ImportError: cannot import name start_ipython


The weird thing is, sometimes IPython does work and I can get it to start, but I don't really know why it doesn't work sometimes.



Can anyone give me a hand?










share|improve this question



























    1















    I'm trying to start IPython from the terminal. I input:



    ipython



    into the terminal and I get this output:



    Traceback (most recent call last):
    File "/usr/local/bin/ipython", line 4, in <module>
    from IPython import start_ipython
    ImportError: cannot import name start_ipython


    The weird thing is, sometimes IPython does work and I can get it to start, but I don't really know why it doesn't work sometimes.



    Can anyone give me a hand?










    share|improve this question

























      1












      1








      1








      I'm trying to start IPython from the terminal. I input:



      ipython



      into the terminal and I get this output:



      Traceback (most recent call last):
      File "/usr/local/bin/ipython", line 4, in <module>
      from IPython import start_ipython
      ImportError: cannot import name start_ipython


      The weird thing is, sometimes IPython does work and I can get it to start, but I don't really know why it doesn't work sometimes.



      Can anyone give me a hand?










      share|improve this question














      I'm trying to start IPython from the terminal. I input:



      ipython



      into the terminal and I get this output:



      Traceback (most recent call last):
      File "/usr/local/bin/ipython", line 4, in <module>
      from IPython import start_ipython
      ImportError: cannot import name start_ipython


      The weird thing is, sometimes IPython does work and I can get it to start, but I don't really know why it doesn't work sometimes.



      Can anyone give me a hand?







      command-line python ipython






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Feb 26 '15 at 15:11









      KestrelKestrel

      1138




      1138






















          2 Answers
          2






          active

          oldest

          votes


















          0














          The default installation of IPython from the Ubuntu Software Center does not install ipython to /usr/local/bin/ so it looks like you have installed IPython in another way, and now it isn't starting properly. The easiest way to get things back to normal would be to uninstall IPython and then reinstall IPython from the Ubuntu repositories. You can find IPython in the Ubuntu Software Center or reference it by its package name ipython.






          share|improve this answer































            0














            This happened to me after an update. The problem was that there were two versions of ipython which were clashing, one was version 0.13.2 that I had installed using synaptic, and the other was version 3.1.0, which I had installed from the source.



            In my /usr/local/bin/ipython, I had the following code:



            #!/usr/bin/python
            # This script was automatically generated by setup.py
            if __name__ == '__main__':
            from IPython import start_ipython
            start_ipython()


            From what I gathered from http://nullege.com/codes/search/IPython.start_ipython, it seems that start_ipython has been implemented in recent versions of ipython, but for some reason, when I was importing IPython in the python shell, it was version 0.13.2 which was being imported. This didn't have a start_ipython function, hence it raised an ImportError.



            Now that I have removed the old version of ipython, the new version works fine.






            share|improve this answer

























              Your Answer








              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "89"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














              draft saved

              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f590229%2fcant-get-ipython-to-start-importerror-cannot-import-name-start-ipython%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              0














              The default installation of IPython from the Ubuntu Software Center does not install ipython to /usr/local/bin/ so it looks like you have installed IPython in another way, and now it isn't starting properly. The easiest way to get things back to normal would be to uninstall IPython and then reinstall IPython from the Ubuntu repositories. You can find IPython in the Ubuntu Software Center or reference it by its package name ipython.






              share|improve this answer




























                0














                The default installation of IPython from the Ubuntu Software Center does not install ipython to /usr/local/bin/ so it looks like you have installed IPython in another way, and now it isn't starting properly. The easiest way to get things back to normal would be to uninstall IPython and then reinstall IPython from the Ubuntu repositories. You can find IPython in the Ubuntu Software Center or reference it by its package name ipython.






                share|improve this answer


























                  0












                  0








                  0







                  The default installation of IPython from the Ubuntu Software Center does not install ipython to /usr/local/bin/ so it looks like you have installed IPython in another way, and now it isn't starting properly. The easiest way to get things back to normal would be to uninstall IPython and then reinstall IPython from the Ubuntu repositories. You can find IPython in the Ubuntu Software Center or reference it by its package name ipython.






                  share|improve this answer













                  The default installation of IPython from the Ubuntu Software Center does not install ipython to /usr/local/bin/ so it looks like you have installed IPython in another way, and now it isn't starting properly. The easiest way to get things back to normal would be to uninstall IPython and then reinstall IPython from the Ubuntu repositories. You can find IPython in the Ubuntu Software Center or reference it by its package name ipython.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Feb 26 '15 at 15:36









                  karelkarel

                  57.9k12128146




                  57.9k12128146

























                      0














                      This happened to me after an update. The problem was that there were two versions of ipython which were clashing, one was version 0.13.2 that I had installed using synaptic, and the other was version 3.1.0, which I had installed from the source.



                      In my /usr/local/bin/ipython, I had the following code:



                      #!/usr/bin/python
                      # This script was automatically generated by setup.py
                      if __name__ == '__main__':
                      from IPython import start_ipython
                      start_ipython()


                      From what I gathered from http://nullege.com/codes/search/IPython.start_ipython, it seems that start_ipython has been implemented in recent versions of ipython, but for some reason, when I was importing IPython in the python shell, it was version 0.13.2 which was being imported. This didn't have a start_ipython function, hence it raised an ImportError.



                      Now that I have removed the old version of ipython, the new version works fine.






                      share|improve this answer






























                        0














                        This happened to me after an update. The problem was that there were two versions of ipython which were clashing, one was version 0.13.2 that I had installed using synaptic, and the other was version 3.1.0, which I had installed from the source.



                        In my /usr/local/bin/ipython, I had the following code:



                        #!/usr/bin/python
                        # This script was automatically generated by setup.py
                        if __name__ == '__main__':
                        from IPython import start_ipython
                        start_ipython()


                        From what I gathered from http://nullege.com/codes/search/IPython.start_ipython, it seems that start_ipython has been implemented in recent versions of ipython, but for some reason, when I was importing IPython in the python shell, it was version 0.13.2 which was being imported. This didn't have a start_ipython function, hence it raised an ImportError.



                        Now that I have removed the old version of ipython, the new version works fine.






                        share|improve this answer




























                          0












                          0








                          0







                          This happened to me after an update. The problem was that there were two versions of ipython which were clashing, one was version 0.13.2 that I had installed using synaptic, and the other was version 3.1.0, which I had installed from the source.



                          In my /usr/local/bin/ipython, I had the following code:



                          #!/usr/bin/python
                          # This script was automatically generated by setup.py
                          if __name__ == '__main__':
                          from IPython import start_ipython
                          start_ipython()


                          From what I gathered from http://nullege.com/codes/search/IPython.start_ipython, it seems that start_ipython has been implemented in recent versions of ipython, but for some reason, when I was importing IPython in the python shell, it was version 0.13.2 which was being imported. This didn't have a start_ipython function, hence it raised an ImportError.



                          Now that I have removed the old version of ipython, the new version works fine.






                          share|improve this answer















                          This happened to me after an update. The problem was that there were two versions of ipython which were clashing, one was version 0.13.2 that I had installed using synaptic, and the other was version 3.1.0, which I had installed from the source.



                          In my /usr/local/bin/ipython, I had the following code:



                          #!/usr/bin/python
                          # This script was automatically generated by setup.py
                          if __name__ == '__main__':
                          from IPython import start_ipython
                          start_ipython()


                          From what I gathered from http://nullege.com/codes/search/IPython.start_ipython, it seems that start_ipython has been implemented in recent versions of ipython, but for some reason, when I was importing IPython in the python shell, it was version 0.13.2 which was being imported. This didn't have a start_ipython function, hence it raised an ImportError.



                          Now that I have removed the old version of ipython, the new version works fine.







                          share|improve this answer














                          share|improve this answer



                          share|improve this answer








                          edited Apr 24 '15 at 6:20

























                          answered Apr 24 '15 at 6:12









                          JishnuJishnu

                          1012




                          1012






























                              draft saved

                              draft discarded




















































                              Thanks for contributing an answer to Ask Ubuntu!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid



                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f590229%2fcant-get-ipython-to-start-importerror-cannot-import-name-start-ipython%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Biblatex bibliography style without URLs when DOI exists (in Overleaf with Zotero bibliography)

                              How to change which sound is reproduced for terminal bell?

                              Can I use Tabulator js library in my java Spring + Thymeleaf project?