The default log dir is in the system resource directory
    But the utool global cache allows for the user to override
    where the logs for a specific app should be stored.

    Returns:
        log_dir_realpath (str): real path to logging directory

def get_logging_dir(appname='default'):
    """
    The default log dir is in the system resource directory
    But the utool global cache allows for the user to override
    where the logs for a specific app should be stored.

    Returns:
        log_dir_realpath (str): real path to logging directory
    """
    from utool._internal import meta_util_cache
    from utool._internal import meta_util_cplat
    from utool import util_cache
    if appname is None or  appname == 'default':
        appname = util_cache.get_default_appname()
    resource_dpath = meta_util_cplat.get_resource_dir()
    default = join(resource_dpath, appname, 'logs')
    # Check global cache for a custom logging dir otherwise
    # use the default.
    log_dir = meta_util_cache.global_cache_read(logdir_cacheid,
                                                appname=appname,
                                                default=default)
    log_dir_realpath = realpath(log_dir)
    return log_dir_realpath