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

Haskell windows 2019 fails with version check #3223

Closed
2 of 7 tasks
AHuusom opened this issue Apr 21, 2021 · 8 comments
Closed
2 of 7 tasks

Haskell windows 2019 fails with version check #3223

AHuusom opened this issue Apr 21, 2021 · 8 comments

Comments

@AHuusom
Copy link
Contributor

AHuusom commented Apr 21, 2021

Description
The sorting mechanism on the versioning is off and shows 3 different outcomes on 3 different VMS.
The if statement testing if version is < 8 is testing against a unused variable.

Area for Triage:
Haskell

Question, Bug, or Feature?:
Bug

Virtual environments affected

  • Ubuntu 16.04
  • Ubuntu 18.04
  • Ubuntu 20.04
  • macOS 10.15
  • macOS 11.0
  • Windows Server 2016 R2
  • Windows Server 2019

Image version
?

Expected behavior
That it sets the newest version as default

Actual behavior
As the sorting mechanism isn't working, if version 9 is shown as the newest it works as haskell path is always set to the versions 9's executable.
This is because it tests against a $null variable and thus always sets the path to version 9

Repro steps
Just run the haskel section on windows 2019

I've made a PR with the corrections [/pull/3219] please review it

@miketimofeev
Copy link
Contributor

@AHuusom Thanks for your fix. However, it looks like we need to raise the issue in the choco repository because we should have 3 latest versions, but not 3 random versions

@AHuusom
Copy link
Contributor Author

AHuusom commented Apr 21, 2021

@miketimofeev Choco definetely gives you over 3 versions... but the sorting done by the code to get the latest was faulty, as it sorted on the count instead of the version naming.

@miketimofeev
Copy link
Contributor

@AHuusom yeah, it gives, but sometimes not all the versions
#2882 (comment)

@miketimofeev miketimofeev self-assigned this May 5, 2021
@miketimofeev
Copy link
Contributor

miketimofeev commented May 12, 2021

Created a bug in the choco repository regarding version 9.0.1
chocolatey/choco#2271

@miketimofeev
Copy link
Contributor

We've implemented a test to make sure version 9.* is installed.
@AHuusom I'm going to close the issue. Thank you for your contribution!

@AHuusom
Copy link
Contributor Author

AHuusom commented May 20, 2021

It's failing now again.
The test fails if version 9.* isn't installed, but when I run the install-haskell script my vm's only get presented with sub version 9.*
So the test will always fail, and I cannot install version 9 as I don't get the option.

@miketimofeev
Copy link
Contributor

@AHuusom test is failed if version 9.0.1 is not found among the others. We did it intentionally to avoid a sudden GHC downgrade. I've created an issue in choco repo regarding inconsistent search chocolatey/choco#2271

@AHuusom
Copy link
Contributor Author

AHuusom commented May 21, 2021

Thanks, I followed the link to the issue and integrated the Odata query in our solution so our build doesn't fail.
Version 9.0.1 will now be installed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants