You will also need to add this line to your setup.py:

sys.path.append(r"C:\path\to\paramiko")

 

From: Daniel Casper [mailto:dancasper@gmail.com]
Sent: Monday, January 20, 2014 11:29 AM
To: John Nevius
Cc: py2exe-users@lists.sourceforge.net
Subject: Re: [Py2exe-users] 'paramiko not found' error

 

You might try adding setup options like so:

options = {
  "py2exe": {
     "packages": ['paramiko']
  }
}

setup(console=['test2.py'], options=options)

I haven't worked with paramiko directly, but that's the standard approach to forcing a library to be included in a py2exe executable.

 

On Mon, Jan 20, 2014 at 11:54 AM, John Nevius <john.nevius@johnneviusconsulting.com> wrote:

Apologies to all if this has been covered previously.  I did search the archives and could not find a similar question.

 

Environment Windows 7 / Python 2.7

 

Running py2exe on my target application generates the message:

 

The following modules appear to be missing

['paramiko']

 

A test program that reproduces the problem:

 

 
# Test file for py2exe
 
import sys
import os
import paramiko
 
print "This is a test"
 
The setup module:
 
 
#
from distutils.core import setup
import py2exe
setup(console=['test2.py'])
 
 
 
 
Paramiko was installed via the Windows installer and
does not reside in the /lib/site-packages directory. 
 
Of course the target program operates properly when 
invoked 'normally'.


------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For
Critical Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today.
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
Py2exe-users mailing list
Py2exe-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/py2exe-users