-
Notifications
You must be signed in to change notification settings - Fork 3
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
ci: build and push to cachix on merge #47
base: main
Are you sure you want to change the base?
Conversation
ce4839d
to
f52c83a
Compare
🤔 I don't understand how the checks are failing |
f52c83a
to
8f8847f
Compare
@simifalaye the new Here, the same checks have passed for the I can reproduce the flakiness in the nix devshell, by running mkdir luarocks
luarocks make --tree luarocks --deps-mode-all
busted # run this repeatedly
|
@mrcjkb the issue is that when using key-tables in lua, the order of the key-value pairs isn't guaranteed in the same way as if you were using list tables with an integer index and is up to the optimization of the language. So, when it goes to compare the strings, the version and pin may show up in a different order causing the entire string to not be equal to the expected. There are a few ways this could be resolved, but I'm not sure which one would be the simplest/cleanest way for testing. You could even go as far as adding a toml library to the test dependencies then pass both toml strings into the library so that you can compare them for equality (there's toml for example). This is what I was considering doing before but I'm not sure if that's worth it just for testing purposes. You could maybe sort the lines of the resultant toml string to guarantee the order? Let me know if you think of something simpler/cleaner and I could implement it too if you're too busy now (as I know you have a lot on your plate) EDIT: Yeah, I think the best bet is using the lua toml library for comparison of the two result strings. Just looked at the library and it should be quick to add into your PR. You can parse the expected and resultant strings into the table using the |
@simifalaye thanks for the input 🙏 |
No description provided.