There seems to be an update required where "except" should now be rewritten as except CatchableError as per these warnings:
: The bare except clause is deprecated; use `except CatchableError:` instead [BareExcept]
But what is the version to use if writing something like:
when NimVersion >= "x.x.x"
because I haven't found that documented searching about yet, although it might be around somewhere I haven't looked of course, and it seems like it would not be infinitely backward compatible as a fairly new idea, although perhaps it is?Something like 0.19.0.
Note that this isn't a complete alternative to except: and something might be changed about this warning
It was added to nim version 2
https://github.com/nim-lang/Nim/issues/19580
From the changelog fo v2:
So:
when NimVersion >= "1.9.1"
Thank you, if it's before 1.0 then it shouldn't need version checking anyway for my use. I'd read the discussion on GitHub and seen the reference to CatchableError in the docs as a class, but it's not shown being used in the specific syntax mentioned by the warning alongside the description of except and it wasn't clear to me if that had been introduced along with the warning.