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

Traceback deb9 py3.5 | __init__.py", line 739, in run_script #20

Open
ghost opened this issue May 24, 2018 · 1 comment
Open

Traceback deb9 py3.5 | __init__.py", line 739, in run_script #20

ghost opened this issue May 24, 2018 · 1 comment

Comments

@ghost
Copy link

ghost commented May 24, 2018

Hello.
I install Gel on Debian 9 with all depend on py 3.5

root@mirror:/tmp/Gelatin/demo/simple# gel --version
2.2.10
root@mirror:/tmp/Gelatin/demo/simple# 

but when i run convert, have next error

gel -s input1.txt out.txt
Traceback (most recent call last):
  File "/usr/local/bin/gel", line 4, in <module>
    __import__('pkg_resources').run_script('Gelatin==2.2.10', 'gel')
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 739, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1494, in run_script
    exec(code, namespace, namespace)
  File "/usr/local/lib/python3.5/dist-packages/Gelatin-2.2.10-py3.5.egg/EGG-INFO/scripts/gel", line 77, in <module>
    converter = compile(options.syntax)
  File "/usr/local/lib/python3.5/dist-packages/Gelatin-2.2.10-py3.5.egg/Gelatin/util.py", line 53, in compile
    encoding=encoding)
  File "/usr/local/lib/python3.5/dist-packages/Gelatin-2.2.10-py3.5.egg/Gelatin/parser/Parser.py", line 56, in parse
    return self.parse_string(string, compiler)
  File "/usr/local/lib/python3.5/dist-packages/Gelatin-2.2.10-py3.5.egg/Gelatin/parser/Parser.py", line 48, in parse_string
    error(input, end)
  File "/usr/local/lib/python3.5/dist-packages/Gelatin-2.2.10-py3.5.egg/Gelatin/parser/util.py", line 45, in error
    raise Exception(msg)
Exception: Syntax error in line 1:
'User'
 ^

File input1.txt from repo

root@mirror:/tmp/Gelatin/demo/simple# cat input1.txt 
User
----
Name: John, Lastname: Doe
Office: 1st Ave
Birth date: 1978-01-01

User
----
Name: Jane, Lastname: Foo
Office: 2nd Ave
Birth date: 1970-01-01
root@mirror:/tmp/Gelatin/demo/simple# 

On py 2.7 i have this error too.
This is bug or my py version not supported?

@Daniel314
Copy link

I'm using the same version (2.2) and it works.

What follows the '-s' on the command line should be the path to a grammar file, not the text that should be parsed by the grammar. E.g. gel -s my_grammar_file input1.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant