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
I'm running into this weird error when running my python code with ray.
Basically I get AttributeError: type object 'Signature' has no attribute '_encoding'.
But it works fine when I run my script without ray...
The error can be reproduced with the code below.
Ray can be installed from PyPi: pip install ray
importpygit2importrayfrompygit2importSignaturedeffunction_without_ray():
org_name="libgit2"repo_name="pygit2"repo=pygit2.clone_repository(
f"https://github.com/{org_name}/{repo_name}",
f"/tmp/{repo_name}.git",
)
new_branch=repo.branches.create(
"dummy-branch", repo.revparse_single("HEAD")
)
repo.checkout(new_branch)
index=repo.indexindex.add_all()
index.write()
author=Signature("John Doe", "john@doe.com")
ref=repo.head.nametree=index.write_tree()
parents= [repo.head.target]
repo.create_commit(
ref,
author,
author,
"Just a dummy commit",
tree,
parents,
)
@ray.remotedeffunction_with_ray():
function_without_ray()
# Comment out one of these function calls to check if it works:ray.get(function_with_ray.remote())
function_without_ray()
The text was updated successfully, but these errors were encountered:
Hi folks!
I'm running into this weird error when running my python code with ray.
Basically I get
AttributeError: type object 'Signature' has no attribute '_encoding'
.But it works fine when I run my script without ray...
pygit2 version: v1.12.2
environment: python:3.9.16 docker container.
The error can be reproduced with the code below.
Ray can be installed from PyPi:
pip install ray
The text was updated successfully, but these errors were encountered: