本文整理汇总了Python中stat.ST_CTIME属性的典型用法代码示例。如果您正苦于以下问题:Python stat.ST_CTIME属性的具体用法?Python stat.ST_CTIME怎么用?Python stat.ST_CTIME使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在模块stat的用法示例。
在下文中一共展示了stat.ST_CTIME属性的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。
示例1: fetch
点赞 6
# 需要导入模块: import stat [as 别名]
# 或者: from stat import ST_CTIME [as 别名]
def fetch(self, is_dl_forced=False):
'''connection details for DISCO'''
cxn = {}
cxn['host'] = 'nif-db.crbs.ucsd.edu'
cxn['database'] = 'disco_crawler'
cxn['port'] = '5432'
cxn['user'] = config.get_config()['user']['disco']
cxn['password'] = config.get_config()['keys'][cxn['user']]
pg_iri = 'jdbc:postgresql://'+cxn['host']+':'+cxn['port']+'/'+cxn['database']
self.dataset.set_ingest_source(pg_iri)
# process the tables
# self.fetch_from_pgdb(self.tables,cxn,100) #for testing
self.fetch_from_pgdb(self.tables, cxn)
self.get_files(is_dl_forced)
fstat = os.stat('/'.join((self.rawdir, 'dvp.pr_nlx_157874_1')))
filedate = datetime.utcfromtimestamp(fstat[ST_CTIME]).strftime("%Y-%m-%d")
self.dataset.set_ingest_source_file_version_date(pg_iri, filedate)
开发者ID:monarch-initiative,项目名称:dipper,代码行数:24,
示例2: test_version_level_source_version_download_timestamp
点赞 6
# 需要导入模块: import stat [as 别名]
# 或者: from stat import ST_CTIME [as 别名]
def test_version_level_source_version_download_timestamp(self):
path_to_dl_file = '/'.join(
(self.source.rawdir, self.source.files.get('test