input-output-hk / tullia

Standard library and CLI for Cicero
Apache License 2.0
10 stars 5 forks source link

hotfix: missing double quote #17

Closed GTrunSec closed 1 year ago

GTrunSec commented 1 year ago

@dermetfan

dermetfan commented 1 year ago

I can't reproduce this... Instead I found two more instances where quotes can be removed. Are you on the latest main and not overriding any flake inputs?

GTrunSec commented 1 year ago

In my instance. This issue only hits the preset.nix.enable job(not 100% sure, but 99%). https://github.com/GTrunSec/DeSci/blob/layers/nix/julia/pipelines.nix#L39

dermetfan commented 1 year ago

That makes sense because the affected script is built when the nix preset is enabled.

I can't try it in your repo though:

❯ cd DeSci
❯ nix develop .#x86_64-linux.automation.devshells.default
error: hash mismatch in file downloaded from 'https://raw.githubusercontent.com/GTrunSec/flake-compat/lockFile/default.nix':
         specified: sha256:0i65hifh0z5nxnnn4dy1rgcp0jqkypb95xrk8ksyland8l1ziap6
         got:       sha256:0c1rfhipjxfn3z249b3wvk5x2a8cbdl5dcw7nf1iyz6q05c8ln56

But I think tullia is too old in your repo. Try nix flake lock --update-input tullia.

If that doesn't help, try not overriding tullia's nixpkgs input:

diff --git a/flake.nix b/flake.nix
index 272098f..700aedf 100644
--- a/flake.nix
+++ b/flake.nix
@@ -35,7 +35,6 @@

     tullia.url = "github:input-output-hk/tullia";
     # tullia.url = "/home/gtrun/ghq/github.com/input-output-hk/tullia";
-    tullia.inputs.nixpkgs.follows = "nixpkgs";
     tullia.inputs.nix2container.follows = "n2c";
     tullia.inputs.nix-nomad.follows = "nix-nomad";
     nix-nomad.url = "github:tristanpemble/nix-nomad";
GTrunSec commented 1 year ago

I can't try it in your repo though:

my current working branch is layers not main.

If that doesn't help, try not overriding tullia's nixpkgs input:

it works. wired, thanks.

GTrunSec commented 1 year ago

@dermetfan
Because the tullia's shellcheck was 0.8.0, which doesn't support the newest syntax check.

The problem is that my overriding spellcheck of nixpkgs is 0.9.0. that's why I got this issue.

warning: Git tree '/home/guangtao/ghq/github.com/GTrunSec/dataflow2nix' is dirty
ShellCheck - shell script analysis tool
version: 0.9.0

So, This PP is going to be necessary.

dermetfan commented 1 year ago

Interesting, shellcheck doesn't seem to be very consistent here. 0.9.0 complains about what this PR fixes but accepts the changes I made in 12644cda23f386e4d67e8701c23691713a59361b. :shrug: