eaton-lab / ipcoal

simulation framework for investigating genealogical and sequence variation within and across genomes
MIT License
2 stars 2 forks source link

ipcoal.Model() - TypeError: unhashable type: 'MassMigration' #4

Closed isaacovercast closed 2 years ago

isaacovercast commented 2 years ago

Something must have changed recently somewhere, because ipcoal.Model() is now raising a TypeError upon even simple invocation. Steps to reproduce (tested with Python 3.9):

import ipcoal
import toytree

tree = toytree.rtree.baltree(ntips=10, treeheight=10e6)
model = ipcoal.Model(tree=tree, nsamples=2, Ne=4e5, admixture_edges=(2, 3, 0.5, 0.15))

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/isaac/miniconda3/envs/ipyrad/lib/python3.9/site-packages/ipcoal/Model.py", line 242, in __init__
    self._get_demography()
  File "/home/isaac/miniconda3/envs/ipyrad/lib/python3.9/site-packages/ipcoal/Model.py", line 579, in _get_demography
    demog.add(ms.MassMigration(time, source, dest))
TypeError: unhashable type: 'MassMigration'
isaacovercast commented 2 years ago

Nevermind, this is for ipcoal v0.1.5