Ignore:
Timestamp:
Jun 23, 2016 9:25:06 PM (6 years ago)
Author:
toby
Message:

improve powder imports: suppress printing of binary data; improve validation of old GSAS binary files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/imports/G2pwd_xye.py

    r1620 r2341  
    5656            else:
    5757                self.errors = 'Unexpected information in line: '+str(i+1)
    58                 self.errors += '  '+str(S)
     58                if all([ord(c) < 128 and ord(c) != 0 for c in str(S)]): # show only if ASCII
     59                    self.errors += '  '+str(S)
     60                else:
     61                    self.errors += '  (binary)'
    5962                return False
    6063        return True # no errors encountered
Note: See TracChangeset for help on using the changeset viewer.