Opened 16 years ago

Closed 16 years ago

#129 closed defect (fixed)

Installation Error ... OSError: [Errno 13] Permission denied: '/Users/Uni/.asap/db'

Reported by: brent.nicholas@… Owned by: Malte Marquarding
Priority: high Milestone: ASAP 2.2
Component: General Version: 2.0
Severity: critical Keywords: Installation Errors
Cc:

Description

Hello, trying to get ASAP working on my Intel Macbook.

I followed the instruction steps from: http://svn.atnf.csiro.au/trac/asap/wiki/ASAPOSXInstall

Installed a) b) c) --(didn't have to change the WxAgg? was already TkAgg?)

unzipped and installed ipython using the given commands unzipped and installed the INTEL asap

run asap_update_data ... which updates fine

try to run asap and get the following error message

Loading ASAP...


exceptions.OSErrorPython 2.4.4: /Library/Frameworks/Python?.framework/Versions/2.4/Resources/Python.app/Contents/MacOS/Python

Wed May 14 11:04:31 2008

A problem occured executing Python code. Here is the sequence of function calls leading up to the error, with the most recent (innermost) call last.

/Library/Frameworks/Python?.framework/Versions/Current/bin/ipython

12 IPython.Shell.IPShell().mainloop(sys_exit=1) 13 14 [or simply IPython.Shell.IPShell().mainloop(1) ] 15 16 and IPython will be your working environment when you start python. The final 17 sys.exit() call will make python exit transparently when IPython finishes, so 18 you don't have an extra prompt to get out of. 19 20 This is probably useful to developers who manage multiple Python versions and 21 don't want to have correspondingly multiple IPython versions. Note that in 22 this mode, there is no way to pass IPython any command-line options, as those 23 are trapped first by Python itself. 24 """ 25 26 import IPython

---> 27 IPython.Shell.start().mainloop()

IPython.Shell.start.mainloop = undefined

28 29 30 31 32 33 34 35 36 37 38 39 40 41 42

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/Shell.py in start(user_ns=None)

1096 arg1 = argv[1] 1097 if arg1.endswith('-gthread'): 1098 shell = IPShellGTK 1099 elif arg1.endswith( '-qthread' ): 1100 shell = IPShellQt 1101 elif arg1.endswith( '-q4thread' ): 1102 shell = IPShellQt4 1103 elif arg1.endswith('-wthread'): 1104 shell = IPShellWX 1105 elif arg1.endswith('-pylab'): 1106 shell = _matplotlib_shell_class() 1107 else: 1108 shell = IPShell 1109 else: 1110 shell = IPShell

-> 1111 return shell(user_ns = user_ns)

shell = <class IPython.Shell.IPShell at 0x1274720> user_ns = None

1112 1113 # Some aliases for backwards compatibility 1114 IPythonShell = IPShell 1115 IPythonShellEmbed = IPShellEmbed 1116 # End of file <Shell.py> * 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/Shell.py in init(self=<IPython.Shell.IPShell instance at 0x47f58>, argv=None, user_ns=None, user_global_ns=None, debug=1, shell_class=<class 'IPython.iplib.InteractiveShell?'>)

59 # Tag when runcode() is active, for exception handling 60 CODE_RUN = None 61 62 #----------------------------------------------------------------------------- 63 # This class is trivial now, but I want to have it in to publish a clean 64 # interface. Later when the internals are reorganized, code that uses this 65 # shouldn't have to change. 66 67 class IPShell: 68 """Create an IPython instance.""" 69 70 def init(self,argv=None,user_ns=None,user_global_ns=None, 71 debug=1,shell_class=InteractiveShell?): 72 self.IP = make_IPython(argv,user_ns=user_ns, 73 user_global_ns=user_global_ns,

---> 74 debug=debug,shell_class=shell_class)

debug = 1 shell_class = <class 'IPython.iplib.InteractiveShell?'>

75 76 def mainloop(self,sys_exit=0,banner=None): 77 self.IP.mainloop(banner) 78 if sys_exit: 79 sys.exit() 80 81 #----------------------------------------------------------------------------- 82 class IPShellEmbed: 83 """Allow embedding an IPython shell into a running program. 84 85 Instances of this class are callable, with the call method being an 86 alias to the embed() method of an InteractiveShell? instance. 87 88 Usage (see also the example-embed.py file for a running example): 89

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/ipmaker.py in make_IPython(argv=['/Library/Frameworks/Python?.framework/Versions/Current/bin/ipython', '-ipythondir', '/Users/Uni/?.asap', '-p', 'asap'], user_ns=None, user_global_ns=None, debug=1, rc_override=None, shell_class=<class 'IPython.iplib.InteractiveShell?'>, embedded=False, kw={})

497 # tweaks. Basically options which affect other options. I guess this 498 # should just be written so that options are fully orthogonal and we 499 # wouldn't worry about this stuff! 500 501 if IP_rc.classic: 502 IP_rc.quick = 1 503 IP_rc.cache_size = 0 504 IP_rc.pprint = 0 505 IP_rc.prompt_in1 = '>>> ' 506 IP_rc.prompt_in2 = '... ' 507 IP_rc.prompt_out = 508 IP_rc.separate_in = IP_rc.separate_out = IP_rc.separate_out2 = '0' 509 IP_rc.colors = 'NoColor?' 510 IP_rc.xmode = 'Plain' 511

--> 512 IP.pre_config_initialization()

IP.pre_config_initialization = <bound method InteractiveShell?.pre_config_initialization of <IPython.iplib.InteractiveShell? object at 0x4f110>>

513 # configure readline 514 # Define the history file for saving commands in between sessions 515 if IP_rc.profile: 516 histfname = 'history-%s' % IP_rc.profile 517 else: 518 histfname = 'history' 519 IP.histfile = os.path.join(opts_all.ipythondir,histfname) 520 521 # update exception handlers with rc file status 522 otrap.trap_out() # I don't want these messages ever. 523 IP.magic_xmode(IP_rc.xmode) 524 otrap.release_out() 525 526 # activate logging if requested and not reloading a log 527 if IP_rc.logplay:

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/iplib.py in pre_config_initialization(self=<IPython.iplib.InteractiveShell? object at 0x4f110>)

648 self.user_ns, # globals 649 # Skip our own frame in searching for locals: 650 sys._getframe(depth+1).f_locals # locals 651 )) 652 653 def pre_config_initialization(self): 654 """Pre-configuration init method 655 656 This is called before the configuration files are processed to 657 prepare the services the config files might need. 658 659 self.rc already has reasonable default values at this point. 660 """ 661 rc = self.rc 662 try:

--> 663 self.db = pickleshare.PickleShareDB(rc.ipythondir + "/db")

self.db = undefined global pickleshare.PickleShareDB = <class pickleshare.PickleShareDB at 0x1286b40> rc.ipythondir = '/Users/Uni/?.asap'

664 except exceptions.UnicodeDecodeError?: 665 print "Your ipythondir can't be decoded to unicode!" 666 print "Please set HOME environment variable to something that" 667 print r"only has ASCII characters, e.g. c:\home" 668 print "Now it is",rc.ipythondir 669 sys.exit() 670 671 672 def post_config_initialization(self): 673 """Post configuration init method 674 675 This is called after the configuration files have been processed to 676 'finalize' the initialization.""" 677 678 rc = self.rc

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/Extensions/pickleshare.py in init(self=PickleShareDB('/Users/Uni/?.asap/db'), root='/Users/Uni/?.asap/db')

34 """ 35 36 from path import path as Path 37 import os,stat,time 38 import cPickle as pickle 39 import UserDict? 40 import warnings 41 import glob 42 43 class PickleShareDB(UserDict?.DictMixin?): 44 """ The main 'connection' object for PickleShare? database """ 45 def init(self,root): 46 """ Return a db object that will manage the specied directory""" 47 self.root = Path(root).expanduser().abspath() 48 if not self.root.isdir():

---> 49 self.root.makedirs()

self.root.makedirs = <bound method path.makedirs of path('/Users/Uni/?.asap/db')>

50 # cache has { 'key' : (obj, orig_mod_time) } 51 self.cache = {} 52 53 def getitem(self,key): 54 """ dbkey? reading """ 55 fil = self.root / key 56 try: 57 mtime = (fil.stat()[stat.ST_MTIME]) 58 except OSError: 59 raise KeyError?(key) 60 61 if fil in self.cache and mtime == self.cache[fil][1]: 62 return self.cache[fil][0] 63 try: 64 # The cached item has expired, need to read

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/site-packages/IPython/Extensions/path.py in makedirs(self=path('/Users/Uni/?.asap/db'), mode=511)

875 os.chown(self, uid, gid) 876 877 def rename(self, new): 878 os.rename(self, new) 879 880 def renames(self, new): 881 os.renames(self, new) 882 883 884 # --- Create/delete operations on directories 885 886 def mkdir(self, mode=0777): 887 os.mkdir(self, mode) 888 889 def makedirs(self, mode=0777):

--> 890 os.makedirs(self, mode)

global os.makedirs = <function makedirs at 0x3c530> self = path('/Users/Uni/?.asap/db') mode = 511

891 892 def rmdir(self): 893 os.rmdir(self) 894 895 def removedirs(self): 896 os.removedirs(self) 897 898 899 # --- Modifying operations on files 900 901 def touch(self): 902 """ Set the access/modified times of this file to the current time. 903 Create the file if it does not exist. 904 """ 905 fd = os.open(self, os.O_WRONLY | os.O_CREAT, 0666)

/Library/Frameworks/Python?.framework/Versions/2.4/lib/python2.4/os.py in makedirs(name=path('/Users/Uni/?.asap/db'), mode=511)

144 """makedirs(path [, mode=0777]) 145 146 Super-mkdir; create a leaf directory and all intermediate ones. 147 Works like mkdir, except that any intermediate path segment (not 148 just the rightmost) will be created if it does not exist. This is 149 recursive. 150 151 """ 152 head, tail = path.split(name) 153 if not tail: 154 head, tail = path.split(head) 155 if head and tail and not path.exists(head): 156 makedirs(head, mode) 157 if tail == curdir: # xxx/newdir/. exists if xxx/newdir exists 158 return

--> 159 mkdir(name, mode)

global mkdir = <built-in function mkdir> name = path('/Users/Uni/?.asap/db') mode = 511

160 161 def removedirs(name): 162 """removedirs(path) 163 164 Super-rmdir; remove a leaf directory and empty all intermediate 165 ones. Works like rmdir except that, if the leaf directory is 166 successfully removed, directories corresponding to rightmost path 167 segments will be pruned away until either the whole path is 168 consumed or an error occurs. Errors during this latter phase are 169 ignored -- they generally mean that a directory was not empty. 170 171 """ 172 rmdir(name) 173 head, tail = path.split(name) 174 if not tail:

OSError: [Errno 13] Permission denied: '/Users/Uni/?.asap/db' Could not create crash report on disk.

===============================

Sorry if you didn't need all that but i'm new to error/bug reporting (if thats indeed whats going on!) The file/folder /Users/Uni/?.asap/db referenced in the error does not exist and the folder .asap has read/write permissions for this account.

I also have a *stupud question*

The extracted contents from the zip files (ipython and intel asap) is just in my ~/Downloads/ASAP Stuff/<folder> (where <folder> is what gets extracted). Do i need to keep these here or can they be moved. If i can remove them completely thats great but if i need them to use the program, i would like to move them into my ~/software/<folder> with all the rest of my analysis software. Do i need to edit PATH variables or anything if i do this?

Thank you for your help and assistance.

Brent

Change History (2)

comment:1 Changed 16 years ago by Malte Marquarding

Owner: changed from Malte Marquarding to Malte Marquarding
Status: newassigned

Hi,

It looks like it can't write to /Users/Uni/?. Is that your home directory. Are you executing the commands as you run whoami .

Try removing the directory ~/.asap and run {{asap}}} again.

comment:2 Changed 16 years ago by Malte Marquarding

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.