Skip to content

Commit

Permalink
Merge pull request #530 from Ecogenomics/staging
Browse files Browse the repository at this point in the history
Merge staging to fix pydantic depencies
  • Loading branch information
pchaumeil committed Jul 5, 2023
2 parents c3597ba + 1ef29e0 commit 2ded0f9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion gtdbtk/external/mash.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,14 +234,17 @@ def _generate(self):
args = list(map(str, args))
proc = subprocess.Popen(args, stdout=subprocess.PIPE,
stderr=subprocess.PIPE, encoding='utf-8')
stderr_lines = []
with tqdm_log(total=len(self.genomes), unit='genome') as p_bar:
for line in iter(proc.stderr.readline, ''):
stderr_lines.append(line)
if line.startswith('Sketching'):
p_bar.update()
proc.wait()

if proc.returncode != 0 or not os.path.isfile(self.path):
raise GTDBTkExit(f'Error generating Mash sketch: {proc.stderr.read()}')
raise GTDBTkExit(f'Error generating Mash sketch:\n'
f'{"".join(stderr_lines)}')


class QrySketchFile(SketchFile):
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def readme():
'gtdbtk = gtdbtk.__main__:main'
]
},
install_requires=["dendropy>=4.1.0", 'numpy>=1.9.0', 'tqdm>=4.35.0', 'pydantic'],
install_requires=["dendropy>=4.1.0", 'numpy>=1.9.0', 'tqdm>=4.35.0', 'pydantic>=1.9.2,<2'],
license=meta['license'],
long_description=readme(),
long_description_content_type='text/markdown',
Expand Down

0 comments on commit 2ded0f9

Please sign in to comment.