You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Well, it seems adding python as a dependency only got me past step 3. When I try the first command on the next page, I get:
$ snakemake -np mapped_reads/A.bam
Building DAG of jobs...
Traceback (most recent call last):
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/snakemake/__init__.py", line 701, in snakemake
success = workflow.execute(
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/snakemake/workflow.py", line 1066, in execute
logger.run_info("\n".join(dag.stats()))
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/snakemake/dag.py", line 2191, in stats
yield tabulate(rows, headers="keys")
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/tabulate/__init__.py", line 2048, in tabulate
list_of_lists, headers = _normalize_tabular_data(
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/tabulate/__init__.py", line 1471, in _normalize_tabular_data
rows = list(map(lambda r: r if _is_separating_line(r) else list(r), rows))
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/tabulate/__init__.py", line 1471, in <lambda>
rows = list(map(lambda r: r if _is_separating_line(r) else list(r), rows))
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/tabulate/__init__.py", line 107, in _is_separating_line
(len(row) >= 1 and row[0] == SEPARATING_LINE)
File "/Users/rleach/.mambaforge/envs/snakemake-tutorial/lib/python3.8/site-packages/snakemake/rules.py", line 1138, in __eq__
return self.name == other.name and self.output == other.output
AttributeError: 'str' object has no attribute 'name'
Activity
[-]Tutorial step 3 hangs - solved[/-][+]Tutorial step 3 hangs[/+]hepcat72 commentedon Dec 13, 2022
Well, it seems adding python as a dependency only got me past step 3. When I try the first command on the next page, I get:
Total mamba newb. First time installing/using it.
hepcat72 commentedon Dec 13, 2022
It seems that following the tutorial, it installed an older version of snakemake?
So I got past the above AttributeError by installing the latest:
^^ This took me out of the
snakemake-tutorialenvironment and back into base, where I......and that succeeded without the attribute error.
hepcat72 commentedon Dec 13, 2022
Yet, if I go back into the
snakemake-tutorialenvironment, I get the old version again...hepcat72 commentedon Dec 13, 2022
I got the tutorial environment to work by doing:
dariober commentedon Dec 14, 2022
This is an unfortunate incompatibility between the recent tabulate >= 0.9 and older versions of snakemake ( <= 7.15.1). It has been reported in a few places like https://stackoverflow.com/questions/74226320/snakemake-tutorial-error-attributeerror-str-object-has-no-attribute-name and #1899
Instead of downgrading tabulate, it's probably better to upgrade snakemake to the latest version instead.
Besides, it appears that the tutorial version currently quoted in the docs 5.24.1 is a bit old. At the moment there is 7.4.2.
docs: Rework tutorial (#4068)