disruptek / atoz

Amazon Web Services (AWS) APIs in Nim
MIT License
48 stars 5 forks source link

\atoz\s3_20060301.nim(248, 11) Error: the special identifier '_' is ignored in declarations and cannot be used #13

Closed refacktor closed 1 month ago

refacktor commented 1 month ago

Steps to reproduce:

  1. nimble file:
    
    requires "nim >= 2.0.4"
    requires "npeg == 0.27.0"  # see https://github.com/disruptek/atoz/issues/12
    requires "db_connector == 0.1.0"
    requires "awslambda == 0.2.0"
    requires "atoz == 2626.4.1"
2. Code:

import atoz/[s3_20060301, filetypes] ... other stuff...

3. Command:

nimble install

**Expected results**
- the nim code should compile

**Actual Result**

Verifying dependencies for nimdexer@0.1.0 Info: Dependency on npeg@0.27.0 already satisfied Verifying dependencies for npeg@0.27.0 Info: Dependency on db_connector@0.1.0 already satisfied Verifying dependencies for db_connector@0.1.0 Info: Dependency on awslambda@0.2.0 already satisfied Verifying dependencies for awslambda@0.2.0 Info: Dependency on atoz@2626.4.1 already satisfied Verifying dependencies for atoz@2626.4.1 Info: Dependency on sigv4@>= 1.3.0 & < 2.0.0 already satisfied Verifying dependencies for sigv4@1.4.1 Info: Dependency on https://github.com/jangko/nimSHA2@< 1.0.0 already satisfied Verifying dependencies for nimSHA2@0.1.1 Info: Dependency on https://github.com/disruptek/balls@>= 3.0.0 & < 4.0.0 already satisfied Warning: Package 'balls' has an incorrect structure. It should contain a single directory hierarchy for source files, named 'ballspkg', but file 'runner.nim' is in a directory named 'balls' instead. This will be an error in the future. Hint: If 'balls' contains source files for building 'balls', rename it to 'ballspkg'. Otherwise, prevent its installation by adding skipDirs = @["balls"] to the .nimble file. Verifying dependencies for balls@3.9.12 Info: Dependency on https://github.com/disruptek/grok@>= 0.5.0 & < 1.0.0 already satisfied
Verifying dependencies for grok@0.6.4 Info: Dependency on https://github.com/disruptek/ups@< 1.0.0 already satisfied Verifying dependencies for ups@0.4.0 Info: Dependency on npeg@>= 0.23.2 & < 2.0.0 already satisfied Verifying dependencies for npeg@0.27.0 Info: Dependency on https://github.com/disruptek/rest@>= 1.0.0 already satisfied Verifying dependencies for rest@1.0.5 Info: Dependency on foreach@>= 1.0.0 already satisfied Verifying dependencies for foreach@1.0.2 Info: Dependency on https://github.com/disruptek/openapi@>= 3.3.0 & < 4.0.0 already satisfied Verifying dependencies for openapi@3.3.1 Info: Dependency on npeg@< 1.0.0 already satisfied Verifying dependencies for npeg@0.27.0 Info: Dependency on foreach@>= 1.0.1 & < 2.0.0 already satisfied Verifying dependencies for foreach@1.0.2 Installing https://github.com/disruptek/rest.git@>= 1.0.3 & < 2.0.0 Downloading https://github.com/disruptek/rest.git using git Verifying dependencies for rest@1.0.5 Info: Dependency on foreach@>= 1.0.0 already satisfied Verifying dependencies for foreach@1.0.2 Installing rest@1.0.5 Warning: A package "rest@1.0.5" with checksum "154d8e5cede954d1dfd51c38b54239617e905a5a" already exists the the cache. Info: Dependency on npeg@>= 0.22.2 & < 2.0.0 already satisfied Verifying dependencies for npeg@0.27.0 Installing nimdexer@0.1.0 Building nimdexer/nimdexer.exe using c backend C:\Users\user.nimble\pkgs2\atoz-2626.4.1-ff0e0daf22a489a82c2804e53843526e3cf0be41\atoz\s320060301.nim(248, 11) Error: the special identifier '' is ignored in declarations and cannot be used Tip: 41 messages have been suppressed, use --verbose to show them. nimble.nim(229) buildFromDir

Error:  Build failed for the package: nimdexer
disruptek commented 1 month ago

I'm pushing 2626.5.2 which uses some prior generator changes. This also fixes the unavailability of _ as a procedure argument in later Nims. I don't have a good way to test this at the moment, but maybe you can take it for a spin and report back?

refacktor commented 1 month ago

Thank you for pushing a fix so quickly.

I bumped the version. At first I got the error \.nimble\pkgs2\atoz-2626.5.2-42fd535221574157cd17052485cc74eea724d5de\atoz\s3_20060301.nim(9447, 10) Error: use ssl, but this was easily overcome by using nimble install --define:ssl

So it seems to compile now!

I think my next issue might be user error...