Python conda error:- SSLError(MaxRetryError('HTTPSConnectionPool) +SSLError(SSLError("bad handshake:)

During the installation of TensorFlow, I try to create separate python Conda Environment 

But I have faced an issue, so I have done some research and troubleshooting here am going to share how to troubleshoot if you are getting similar Conda issue 


SSLError(MaxRetryError('HTTPSConnectionPool(host=\'repo.anaconda.com\', port=443): Max retries exceeded with url: /pkgs/main/noarch/repodata.json (Caused by SSLError(SSLError("bad handshake: SysCallError(54, \'ECONNRESET\')")))'))





Solution

    1. Open the terminal and execute these command 
       1.1) Check python version 
         
          $> python -V                # To make sure for python 3X version for installed TensorFlow.
         o/t--->  Python 3.7.3      # it's mine local your might differ.

      1.2) Check OpenSSL version.
        $> python -c 'import ssl; print(ssl.OPENSSL_VERSION)'
         o/t---> OpenSSL 1.1.1c    # it's mine local your might be differ.
      1.3) Intalled latest OpenSSL
         $> !pip installed pyOpenSSL-17.2.0


  2. Create new python environments for TensorFlow.
       $>  conda create -n python_tf_env python=3.7.3        # here 3.7.3 my local version 

    3. Activate newly created python environments for TensorFlow.     
      $> conda activate python_tf_env                            # here python_tf_env my environment  name 
  
   4. Install TensorFlow now.
       $> pip install tensorflow==2.0.0                         # here 2.0.0 latesty version for tensorflow




   5. Verify TensorFlow
     $> pip show tensorflow 



     
    6.  Verify the same on Anaconda IDE.




  7 ) Import TensorFlow  
  




Happy Coding!!!! 

Comments

  1. Perfect...!! Thanks for sharing this article ..for me also getting the same error finally this helps.

    ReplyDelete

Post a Comment

Popular posts from this blog