Changeset d2647feb in sasview


Ignore:
Timestamp:
May 1, 2018 6:42:33 AM (6 years ago)
Author:
wojciech
Branches:
master, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, unittest-saveload
Children:
c9bf97b
Parents:
c82cf89
Message:

Logging support added

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasview/sasview.py

    rc82cf89 rd2647feb  
    198198def check_sasmodels_compiler(): 
    199199    """ 
    200     Checking c compiler for sasmodels and trying to trigger xcode command line 
    201     for installation 
    202     """ 
     200    Checking c compiler for sasmodels and raises xcode command line 
     201    tools for installation 
     202    """ 
     203    #TODO: This doesn't work if someone uses different compiler e.g. gcc and has no cc installed. Will fix it 
    203204    import subprocess 
    204205    logger = logging.getLogger(__name__) 
     
    210211    except subprocess.CalledProcessError: 
    211212        raise RuntimeError("No compiler installed. Please follow installation instructions\n") 
     213        logger.error("No compiler installed. Please follow installation instructions\n") 
     214        logger.error(traceback.format_exc()) 
    212215 
    213216def setup_sasmodels(): 
     
    233236    setup_sasmodels() 
    234237    setup_wx() 
    235     check_sasmodels_compiler() 
     238    if sys.platform == "darwin": 
     239        check_sasmodels_compiler() 
    236240    SasView() 
    237241 
Note: See TracChangeset for help on using the changeset viewer.