Changeset 3012 for trunk/GSASIIfiles.py


Ignore:
Timestamp:
Aug 17, 2017 10:21:17 AM (4 years ago)
Author:
odonnell
Message:

Switch GSASIIscriptable.py to argparse, fixed bug with .instprm files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIfiles.py

    r3000 r3012  
    237237             str: Error message if failed
    238238   
    239     (transliterated from GSASII.py:1012, function of the same name)
     239    (transliterated from GSASIIdataGUI.py:1235 (rev 3008), function of the same name)
    240240     '''
    241241    if 'GSAS-II' not in instLines[0]:
     
    251251            if S[0] == '#' and 'Bank' in S:
    252252                banklist.add(int(S.split(':')[0].split()[1]))
    253         bank = sorted(banklist[1])
     253        # Picks the first bank by default
     254        if len(banklist) > 1:
     255            bank = sorted(banklist)[0]
     256        else:
     257            bank = 1
    254258        rd.powderentry[2] = bank
    255259    while il < len(instLines):
Note: See TracChangeset for help on using the changeset viewer.