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

-d option causes syntax error with -b #19

Closed
tripleee opened this issue Feb 3, 2014 · 2 comments
Closed

-d option causes syntax error with -b #19

tripleee opened this issue Feb 3, 2014 · 2 comments

Comments

@tripleee
Copy link

tripleee commented Feb 3, 2014

The -d option produces a syntax error if you attempt to use it with -b; it refers to a variable nb_classes which was probably in scope before the code was refactored. (It does exist in some other methods but I am unable to figure out how to stitch it back together.)

 vnix$ ./langid/langid.py -d -b sample.txt
Traceback (most recent call last):
  File "./langid/langid.py", line 587, in <module>
    main()
  File "./langid/langid.py", line 558, in main
    writer.writerow(['path']+nb_classes)
NameError: global name 'nb_classes' is not defined
saffsd added a commit that referenced this issue Feb 4, 2014
@saffsd
Copy link
Owner

saffsd commented Feb 4, 2014

Fixed in 65e35ea, thanks!

@saffsd saffsd closed this as completed Feb 4, 2014
@carschno
Copy link

Looks like 600f530 re-introduces this issue.

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

3 participants