-
Notifications
You must be signed in to change notification settings - Fork 696
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
Regression: cabal-3.12.1.0 install
ignores --program-suffix
when checking whether exe is already installed
#10290
Comments
I bisected it to 09c04e9, cc @philderbeast Sorry @wismill! @philderbeast any chance you could look into this regression from your patch? |
Sorry, I have no time at the moment to work on this. But the key is maybe from this comment:
I wonder it the following reported error:
merely reports an overwrite that would happen in the store, not in It definitely needs a fix and a test for the use case of the current issue. |
I've had a quick look but this looks too big for me to handle within my schedule for the next month.
I could only find one test1 for
cabal/cabal-install/tests/IntegrationTests2.hs Lines 1984 to 1985 in cc2c9d8
cabal/cabal-install/tests/IntegrationTests2.hs Line 2065 in cc2c9d8
Footnotes
|
When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. fixup
When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set.
When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set.
…10483) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313)
…10483) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313)
…10483) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313)
…10483) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313)
…10483) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313)
…10483) (#10510) * fix cabal install --program-suffix/prefix (fix #10290 and #10476) When checking for existing installations, cabal would not account for an affix (suffix or prefix). So, if you had a `hello` binary installed, installing a second one with a non-empty affix (a perfectly legal operation) would fail. The reason seemed to be a typo in 09c04e9, which passed the arguments to the Symlink structure in a wrong order. When failing to install a binary because of an existing one, cabal would report suffix-less existing target even if a suffix was set. * Add regression tests for overwrite policies and porgram-affixes Add regression tests for the `program-prefix` and `program-suffix` flags combined with the overwrite-policy. In short, the overwrite-policy needs to take potential program affixes into account when deciding whether it will need to overwrite a program path during installation. --------- Co-authored-by: Fendor <[email protected]> (cherry picked from commit ee3c313) Co-authored-by: Artem Pelenitsyn <[email protected]>
cabal-3.12.1.0 install
wrongly ignores--program-suffix
when checking whether exe is already installed:cabal-3.10.3.0 can still do this correctly:
Regression possibly introduced by:
Fix --program-suffix resulting in invalid symlink #10056 ATTN: @wismillThe
--program-suffix
feature likely needs more systematic regression tests.The text was updated successfully, but these errors were encountered: