Skip to content

[Bug] Cannot use overrides containing '@' character #1074

@pringshia

Description

@pringshia

🐛 Bug

Description

I am unable to override a value that contains the '@' character, e.g. in the case of providing email addresses

To reproduce

Borrowed from #962:

** Minimal Code/Config snippet to reproduce **

# test.py

import hydra

@hydra.main()
def foo(*args, **kargs):
    pass

foo()
$ python test.py +bar=example@example.com

** Stack trace/error message **

LexerNoViableAltException: +bar=example@example.com
                                       ^
See https://hydra.cc/docs/next/advanced/override_grammar/basic for details

Set the environment variable HYDRA_FULL_ERROR=1 for a complete stack trace.

Expected Behavior

No error and bar's value should be set to "example@example.com".

System information

  • Hydra Version : 1.0.0
  • Python version : 3.7.4
  • Virtual environment type and version :
  • Operating system :

Additional context

Similar to #962

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions