Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

Enable the choice of action space #363

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

luigiquara
Copy link

This fixes an error occurring when specifying an action space in the creation of the environment.
To reproduce the error:

actions = tuple(nle.nethack.CompassDirection)
env = gym.make('NetHackChallenge-v0', actions=actions)

Error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/lquarantiello/miniconda3/envs/nle/lib/python3.8/site-packages/gym/envs/registration.py", line 676, in make
    return registry.make(id, **kwargs)
  File "/home/lquarantiello/miniconda3/envs/nle/lib/python3.8/site-packages/gym/envs/registration.py", line 520, in make
    return spec.make(**kwargs)
  File "/home/lquarantiello/miniconda3/envs/nle/lib/python3.8/site-packages/gym/envs/registration.py", line 140, in make
    env = cls(**_kwargs)
  File "/home/lquarantiello/miniconda3/envs/nle/lib/python3.8/site-packages/nle/env/tasks.py", line 328, in __init__
    super().__init__(
TypeError: __init__() got multiple values for keyword argument 'actions'

@facebook-github-bot
Copy link

Hi @luigiquara!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at [email protected]. Thanks!

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Sep 4, 2023
@apowers313 apowers313 mentioned this pull request Aug 13, 2024
5 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants