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

add github action #98

Merged
merged 8 commits into from
Sep 24, 2021
Merged

add github action #98

merged 8 commits into from
Sep 24, 2021

Conversation

ringabout
Copy link
Contributor

hello, @flyx

Some tests are broken on devel.

nim lexerTests shows

/home/runner/.nimble/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/runner/.local/bin:/opt/pipx_bin:/usr/share/rust/.cargo/bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/home/runner/.dotnet/tools:/snap/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
/home/runner/work/NimYAML/NimYAML/yaml/private/lex.nim(136, 6) Hint: 'lineWithMarker' is declared but not used [XDeclaredButNotUsed]
io.nim(866)              writeFile
Error: unhandled exception: cannot open: /home/runner/.cache/nim/tlex_d/test/tlex.json [IOError]

nim r test/tserialization shows

stack trace: (most recent call last)
C:\Users\blue\.choosenim\toolchains\nim-#devel\lib\core\macros.nim(1685, 10) getCustomPragmaVal
C:\Users\blue\Documents\GitHub\NimYAML\test\tserialization.nim(134, 7) template/generic instantiation of `suite` from here
C:\Users\blue\Documents\GitHub\NimYAML\test\tserialization.nim(559, 8) template/generic instantiation of `test` from here
C:\Users\blue\Documents\GitHub\NimYAML\test\tserialization.nim(562, 9) template/generic instantiation of `load` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(1341, 14) template/generic instantiation of `construct` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(1319, 19) template/generic instantiation of `constructChild` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(1166, 18) template/generic instantiation of `constructObject` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(416, 19) template/generic instantiation of `constructChild` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(1145, 20) template/generic instantiation of `constructObject` from here
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(904, 25) template/generic instantiation of `constructObjectDefault` from here   
C:\Users\blue\Documents\GitHub\NimYAML\yaml\serialization.nim(840, 29) template/generic instantiation of `getCustomPragmaVal` from here       
C:\Users\blue\.choosenim\toolchains\nim-#devel\lib\core\macros.nim(1685, 10) Error: O doesn't have any custom pragmas

Ref nim-lang/Nim#18543

@ringabout
Copy link
Contributor Author

ringabout commented Jul 20, 2021

@flyx
Copy link
Owner

flyx commented Jul 20, 2021

I am a bit confused. You are describing an issue but this PR does not fix that issue, instead it adds a GitHub action for… some reason? And that GitHub action does only run selected tests, not all of them… What is the goal with this? I first thought you want to reproduce the error, but in your fork the action seems to be successful.

@ringabout
Copy link
Contributor Author

Yeah, this PR just added the GitHub action. The issues I mentioned are some regressions on Nim devel. After the issues are solved or workarounded, other tests can be enabled.

@flyx
Copy link
Owner

flyx commented Jul 21, 2021

Does this GitHub action help Nim development in some way? For NimYAML development it should certainly also execute parserTests and quickstartTests so I would add those unless you have a use-case for which that is inconvenient.

@ringabout
Copy link
Contributor Author

ringabout commented Jul 21, 2021

For NimYAML development it should certainly also execute parserTests and quickstartTests

I agree, let me test whether these tests work on stable branch.

For parserTests on 1.4.8 branch

/home/runner/.choosenim/toolchains/nim-1.4.8/lib/pure/collections/tables.nim(423, 3) Warning: Cannot prove that 'result' is initialized. This will become a compile time error in the future. [ProveInit]
[tparser] Generating tests from "/home/runner/work/NimYAML/NimYAML/test/yaml-test-suite"
/home/runner/work/NimYAML/NimYAML/test/tparser.nim(93, 9) template/generic instantiation of `genTests` from here
/home/runner/work/NimYAML/NimYAML/test/tparser.nim(85, 22) Error: cannot open file: ls: cannot access '/home/runner/work/NimYAML/NimYAML/test/yaml-test-suite/*': No such file or directory/===

@flyx
Copy link
Owner

flyx commented Jul 21, 2021

That looks like the GitHub action failed to fetch the yaml-test-suite git submodule in test. According to the docs actions/checkout@v2 seems to need

  with:
    submodules: true

@ringabout
Copy link
Contributor Author

@flyx
Copy link
Owner

flyx commented Jul 21, 2021

So Windows has two issues:

  • D:\a\NimYAML\NimYAML\test\tparser.nim(85, 22) Error: cannot open file: ls: cannot access '\d\a\NimYAML\NimYAML\test\yaml-test-suite*': No such file or directory\===

    Looks like an error when building the path.

  • D:\a\NimYAML\NimYAML\test\tquickstart.nim(113, 32) Error: cannot open file: \d\a\NimYAML\NimYAML\doc\snippets\quickstart\title

    That seems to miss appending an .exe.

And the third issue is that, despite those errors, the GitHub action succeeds. I would expect it to fail, not sure why it doesn't.

@ringabout
Copy link
Contributor Author

devel bugs are already fixed. Feel free to close this PR.

@flyx
Copy link
Owner

flyx commented Sep 24, 2021

Yeah I kinda forgot about this PR, wanted to do some own exploration but didn't really find the time. Nonwithstanding the Windows weirdness, I'll merge this since it's nice to have a github action :).

@flyx flyx merged commit 8d15e6a into flyx:devel Sep 24, 2021
@flyx
Copy link
Owner

flyx commented Sep 24, 2021

Hmm there's some choosenim weirdness on macos devel, going to assume that's a transient error in devel since it works with other builds.

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

Successfully merging this pull request may close these issues.

2 participants