nimble
nimble copied to clipboard
Cannot compile with nim 1.6
/nimble/src/nimblepkg/sha1hashes.nim(6, 42) Error: cannot open file: ../../dist/checksums/src/checksums/sha1
412af022a44157dd17118432fba825da9f204125
That's really weird. That means that nimble can't download the checksums package. I thought Nimble must not depend on outside packages, but for some reason it attempts to clone a package over here for some reason. I think this should be moved in-house into Nimble, shouldn't it?
@ringabout What should be done about this? Should I copy the portion of checksums that Nimble uses to the source tree? That also poses the additional problem of security as we'll have to manually update the file per-security/feature update.
Nevermind, std/sha1 exists. Why does Nimble still use the external package if the hashing algorithm is already implemented in the stdlib?
You can use condition to support 1.6.x
like
when (NimMajor, NimMinor) >= (2, 0):
import ...
else:
import ...
Yeah, but what about we remove the foreign dependency altogether? Is there any good reason to keep it considering there's a 1:1 alternative in the standard library?
std/sha1 is deprecated. It's not supposed to be used in official projects.
Ah. I see. I never realized that, sorry!
no longer relevant - as long as nimble builds with any nim version it's fine.