mirror of
https://github.com/LCPQ/QUESTDB_website.git
synced 2024-08-25 13:41:50 +02:00
Use os.makedirs instead of mkdir
This commit is contained in:
parent
093dc61602
commit
b250227f47
@ -6,6 +6,7 @@ from TexSoup import TexNode,TexEnv
|
|||||||
from enum import IntEnum,auto,unique,IntFlag
|
from enum import IntEnum,auto,unique,IntFlag
|
||||||
from .formats import getFormatHandlers
|
from .formats import getFormatHandlers
|
||||||
import re
|
import re
|
||||||
|
import os
|
||||||
import numpy as np
|
import numpy as np
|
||||||
import json
|
import json
|
||||||
|
|
||||||
@ -172,7 +173,7 @@ class dataFileBase(object):
|
|||||||
def toFile(self,datadir,suffix=None):
|
def toFile(self,datadir,suffix=None):
|
||||||
subpath=datadir/self.GetFileType().name.lower()
|
subpath=datadir/self.GetFileType().name.lower()
|
||||||
if not subpath.exists():
|
if not subpath.exists():
|
||||||
subpath.mkdir()
|
os.makedirs(str(subpath))
|
||||||
molsoup=TexSoup(self.molecule)
|
molsoup=TexSoup(self.molecule)
|
||||||
molcomp=list(molsoup.contents)[0]
|
molcomp=list(molsoup.contents)[0]
|
||||||
molfilename=self.molecule if isinstance(molcomp,str) else molcomp.args[0].value
|
molfilename=self.molecule if isinstance(molcomp,str) else molcomp.args[0].value
|
||||||
|
Loading…
Reference in New Issue
Block a user