-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
util.py KeyError returned while indexing error codes #12
Comments
yes, @ivastar emailed me earlier this week and I have a fix for this, but have been conferencing all week. I'll update this when I get a chance |
@sosey Great, thanks! |
@bourque so these are a couple different issues playing with each other. -7 is a unix return error, not a calwf3 return error. parseinput comes from stsci.tools. It's an attempt to take into account different kinds of input that the user might provide and return a parsed list of expected inputs but the code is then attaching the wrong string to the calwf3 call. I think this section of the code got messed up when I applied a recent pull request. In any case, the code was trying to be helpful and check to make sure the files you want to process actually exist on disk before kicking off, for ASN files, this means opening them and returning the list of members to check
while, using an asn file actually open the asn file:
It's supposed to return the list of input files from the association table, I'm unsure why in this example, it's returning the raw file for the first member and the processed (flt) file for the second. The output looks good, which is the association output name. Because of this I'm switching to a different function to check the file existence and fixing the bug that uses the list instead of the user input...as well as the fact that the calwf3 executable should only accept one input file...multiple bugs! showing how often this has been used :/ multiple input files (when not in an ASN file) should be taken care of by the user by calling calwf3 from a list.
check latest pull request out for yourself and see if it's working now? *** parseinput starting returning expected output for me, no idea what was messed up so I switched back to that. |
@ivastar check it out and see if it works for you as well? |
@sosey Thanks for looking into this. The version in your pull request is working! |
@bourque great. |
@sosey I forgot to ask ... when can I expect to see the changes in astroconda? |
@bourque I was going to give @ivastar a couple days to try it out but I can update the version information for astroconda today or tomorrow. Since you've already installed the update locally you shouldn't see any changes if you later do a conda update for wfc3tools. Anyone who wants the update today can pip install from the git master right now, or just do the update after I change the version in astroconda. |
@sosey great, thanks! |
@sosey Myself and others (@cmartlin, @mrafelski, @ivastar) are running into an issue where
wfc3tools.util.py
crashes when attempting to return an error code, e.g.:Digging into the valid error codes in
wfc3tools.util.py
, it does't look like-7
is a choice:Any idea what might be going on here?
This prompted me to dig into why my call to
calwf3
might be triggering an error in the first place. Upon digging, I noticed that though I explicitly set theinput
variable to point to an association table (which contains the list of files I want to process) e.g ......
calwf3
appears to be gathering any FITS files in the CWD and setting them as theinfiles
, e.g.:When I bypass this code and explicitly set
call_list
, I can avoid an error andcalwf3
works fine:Could you advise?
The text was updated successfully, but these errors were encountered: