[Zope] Re: My Sad Tale Of Woe

2006-11-30 Thread Nancy Donnelly
I just tried to run fsrecover on my Data.fs and got this error:

[EMAIL PROTECTED]:zope/instance2/var (145) /usr/local/zope/py235/bin/python 
/usr/local/zope/278/lib/python/ZODB/fsrecover.py Data.fs Data.fs.recover
Traceback (most recent call last):
  File /usr/local/zope/278/lib/python/ZODB/fsrecover.py, line 80, in ?
import ZODB
ImportError: No module named ZODB

Huh? What do here?
TIA,
Nancy




 

Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Re: My Sad Tale Of Woe

2006-11-30 Thread Nancy Donnelly
Okay, yahooing around I found I have to set the path. But I still get this 
error:

[EMAIL PROTECTED]:zope/instance2/var (177) set 
PYTHONPATH=/usr/local/zope/278/lib/python   
 [EMAIL PROTECTED]:zope/instance2/var (178) python 
/usr/local/zope/278/lib/python/ZODB/fsrecover.py Data.fs Data.fs.recover
Traceback (most recent call last):
  File /usr/local/zope/278/lib/python/ZODB/fsrecover.py, line 80, in ?
import ZODB
ImportError: No module named ZODB

The python is the correct one. I re-set python so that the one that comes up 
first in the path is the one Zope uses.
TIA,
Nancy




 

Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: My Sad Tale Of Woe

2006-11-30 Thread Paul Winkler
On Thu, Nov 30, 2006 at 01:04:48AM -0800, Nancy Donnelly wrote:
 Okay, yahooing around I found I have to set the path. But I still get this 
 error:
 
 [EMAIL PROTECTED]:zope/instance2/var (177) set 
 PYTHONPATH=/usr/local/zope/278/lib/python
 [EMAIL PROTECTED]:zope/instance2/var (178) python 
 /usr/local/zope/278/lib/python/ZODB/fsrecover.py Data.fs Data.fs.recover
 Traceback (most recent call last):
   File /usr/local/zope/278/lib/python/ZODB/fsrecover.py, line 80, in ?
 import ZODB
 ImportError: No module named ZODB
 
 The python is the correct one. I re-set python so that the one that comes up 
 first in the path is the one Zope uses.

What shell are you using? That's not how you set an environment
variable in any of the bourne-style shells (sh, bash, ksh).
For those, you would use:

 export PYTHONPATH=/usr/local/zope/278/lib/python:$PYTHONPATH

And it's not how you set environment vars in tcsh either.
For that, you would use:

 setenv PYTHONPATH /usr/local/zope/278/lib/python:$PYTHONPATH

In both cases you would normally append the existing PYTHONPATH as
shown here, but that's not your current problem.

I'm not clear on what exactly set does in tcsh;
in bash it sets positional parameters, which isn't what you want:

[EMAIL PROTECTED] ~ $ echo $FOO

[EMAIL PROTECTED] ~ $ set FOO=bar
[EMAIL PROTECTED] ~ $ echo $FOO

[EMAIL PROTECTED] ~ $ echo $1
FOO=bar
[EMAIL PROTECTED] ~ $ export FOO=bar
[EMAIL PROTECTED] ~ $ echo $FOO
bar



-- 

Paul Winkler
http://www.slinkp.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: My Sad Tale Of Woe

2006-11-30 Thread Paul Winkler
On Thu, Nov 30, 2006 at 08:52:40AM -0800, Nancy Donnelly wrote:
 From: Paul Winkler [EMAIL PROTECTED]
 
  What shell are you using? That's not how you set an environment
  variable in any of the bourne-style shells (sh, bash, ksh).
  For those, you would use:
 
  export PYTHONPATH=/usr/local/zope/278/lib/python:$PYTHONPATH
 
 
 
 I'm using bash. I tried export and it didn't recognize it. I thought set was 
 the same. What do?

If the command:

 export FOO=bar

... does not work, AFAIK you can't possibly be running bash.

Try running ps with no arguments to be sure.  The first thing it
shows should be your current shell, with the program name identified
in the CMD column.

-- 

Paul Winkler
http://www.slinkp.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: My Sad Tale Of Woe

2006-11-30 Thread Dieter Maurer
Nancy Donnelly wrote at 2006-11-30 08:52 -0800:
- Original Message 
From: Paul Winkler [EMAIL PROTECTED]

 What shell are you using? That's not how you set an environment
 variable in any of the bourne-style shells (sh, bash, ksh).
 For those, you would use:

 export PYTHONPATH=/usr/local/zope/278/lib/python:$PYTHONPATH



I'm using bash. I tried export and it didn't recognize it.

If you use bash, then it will recognize export.

Use it the way, you see it above or

PYTHONPATH=/usr/local/zope/278/lib/python:$PYTHONPATH
export PYTHONPATH

Be careful: no whitespace around the =!


-- 
Dieter
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )