Closed samuela closed 2 years ago
It appears that this version constraint is worthwhile however since if I override it I get a slew of test failures: https://gist.github.com/samuela/2cbb09f8f635bde4dab63cfc6ee105ed. They all look something like
def apply(self: A, f: tp.Callable[..., None], *rest: A, inplace: bool = False) -> A:
"""
`apply` is a wrapper over `treeo.apply` that passes `self` as the second argument.
Arguments:
f: The function to apply.
*rest: additional pytrees.
inplace: If `True`, the input `obj` is mutated.
Returns:
A new pytree with the updated Trees or the same input `obj` if `inplace` is `True`.
"""
> return api.apply(f, self, *rest, inplace=inplace)
E AttributeError: module 'treeo.api' has no attribute 'apply'
Hey @samuela!
Ah this should have been a version bump on treeo
then, I wonder if I should do the version bump to 0.1.0
and remove 0.0.11
from pypi and github?
I think Treex is not at fault here.
Hey @samuela!
Ah this should have been a version bump on
treeo
then, I wonder if I should do the version bump to0.1.0
and remove0.0.11
from pypi and github?
Up to you! Just wanted to let you know of the situation, since I figured that you probably intended for the latest versions of treeo/treex to be compatible.
@samuela thanks a lot for reporting this! For some reason I initially thought it was a breaking change on the API but it was just bug. Fix found here: cgarciae/treeo#14
Awesome, thanks @cgarciae! https://github.com/cgarciae/treeo/pull/14 indeed does the trick for me. The version constraints in https://github.com/cgarciae/treex/blob/b89c65ccad06beea2492d3a6594cd83432c6ec3b/pyproject.toml#L23 still cap the treeo version allowed, but that's easy enough to patch around. Thanks!
@samuela I initially thought ^0.0.10
was equivalent to >=0.0.10,<0.1.0
but it seems to actually be >=0.0.10,<0.0.11
which is rather restrictive. I don't think its a problem right now, latest updates are not relevant to the current version of Treex, however Treeo's version will be bumped to the newest in #70 (might take a while).
Yeah I've fallen for this exact same thing! It's super confusing... It's not as issue for me here. Everything seems to be working as is now
At the time of writing the latest treex version is 0.6.10 and it depends on treeo which is at version 0.0.11. However, it is not possible to install treex with the latest treeo version due to the version constraint here: https://github.com/cgarciae/treex/blob/b89c65ccad06beea2492d3a6594cd83432c6ec3b/pyproject.toml#L23
Doing so produces an error: