Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NameError: name 're' is not defined #823

Closed
felinfo opened this issue Mar 4, 2017 · 1 comment
Closed

NameError: name 're' is not defined #823

felinfo opened this issue Mar 4, 2017 · 1 comment
Labels

Comments

@felinfo
Copy link

felinfo commented Mar 4, 2017

Hello. I got this error:

ranger version: ranger-master 1.9.0b5
Python version: 3.6.0 (default, Jan 16 2017, 12:12:55) [GCC 6.3.1 20170109]
Locale: es_ES.UTF-8

Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/ranger/core/main.py", line 114, in main
load_settings(fm, args.clean)
File "/usr/lib/python3.6/site-packages/ranger/core/main.py", line 321, in load_settings
import commands as commands_custom
File "/home/felipe/.config/ranger/commands.py", line 353, in
class setlocal(set_):
File "/home/felipe/.config/ranger/commands.py", line 358, in setlocal
PATH_RE = re.compile(r'^\spath="?(.?)"?\s*$')
NameError: name 're' is not defined

How can I solve it?. I use Arch Linux and I installed Ranger from Aur.

Thanks.

@nfnty nfnty added the question label Mar 4, 2017
@nfnty
Copy link
Member

nfnty commented Mar 4, 2017

The problem is caused by an outdated commands.py, more precisely by the module re not being imported. It's fixed by updating your commands.py. Remove the current one completely if you have no customizations, otherwise move the current one and run ranger --copy-config=commands and then add back your customizations.

@nfnty nfnty closed this as completed Mar 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants