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

import nre gives: Error: raised object of type SyntaxError does not inherit from Exception #9551

Closed
timotheecour opened this issue Oct 29, 2018 · 6 comments
Assignees

Comments

@timotheecour
Copy link
Member

timotheecour commented Oct 29, 2018

/cc @flaviut

  • looks like a regression introduced in the past 24 hours (maybe 48)

main.nim:

import nre
/Users/timothee/git_clone/nim/timn/bugs/stdlib/t21_SyntaxError.nim(1, 1) template/generic instantiation from here
/Users/timothee/git_clone/nim/Nim/lib/impure/nre.nim(445, 5) Error: raised object of type SyntaxError does not inherit from Exception

using latest nim devel:
git rev-parse HEAD
80b78b5

Note: there is $nimc_D/tests/stdlib/tnre.nim and (locally at least) it fails

EDIT

as in this other regression (see #9339 (comment)), this would've been caught by CI but I'm suspecting what happened is testament was only run (locally?) on a subset of categories instead of running the whole test suite and the commits were merged manually

@flaviut
Copy link
Contributor

flaviut commented Oct 29, 2018

Bisected it; the issue is in fe855d8.

Use 2fa1304, that's the last good revision.

@timotheecour
Copy link
Member Author

timotheecour commented Oct 29, 2018

@flaviut how did you check? if I do:

git checkout 2fa1304 -b pr_fix_9551_b
./koch boot -d:release

Error: system module needs: raiseExceptionEx

@flaviut
Copy link
Contributor

flaviut commented Oct 29, 2018

@timotheecour

I'm not sure what's wrong with your system, maybe git stash; git clean -fxd and try again? 2fa1304 works fine for me with ./koch boot -d:useGnuReadline --stackTrace:on --debuginfo --linedir:on -d:release (which are my typical arguments)

I bisected it using these commands:

git bisect good 2fa13040b99350c96e20550f4768043d708f0742
git bisect bad f9eec2aa1e42c3ad5753f8aa3bf36c0090b888fc
vim test.nim
./koch boot -d:useGnuReadline --stackTrace:on --debuginfo --linedir:on -d:release
nim c -r test.nim
git bisect bad

where test.nim is

import nre

@timotheecour
Copy link
Member Author

@flaviut I had to update csources (which have been updated to 0.9 release) to make that commit work; just pushed a PR that fixes this issue by just reverting that 1 commit; would be nice if we can merge it ASAP once green

@flaviut
Copy link
Contributor

flaviut commented Oct 29, 2018 via email

@Araq
Copy link
Member

Araq commented Oct 29, 2018

Sorry for the inconvenience, I forgot to push the commit that fixes it...

@Araq Araq closed this as completed Oct 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants