For anyone who had the same problem as me where it would tell you that "stack" is an unrecognised keyword or smth along those lines, try restarting VS and it should work. Worked for me.
Thanks this still works on macOS in late 2021. This was the toughest programming language to install. Thanks for the tutorial. Really crystal clear and understandable. Reference on how to create a new Haskell project. :^) 9:03 9:45 15:08
Thank you so much for this! I was looking for a tutorial on how to use VSCode for hours now and I finally came across yours!! I really appreciate the effort you put into making this! Thank you so so much :)
So I built it, ran it, and it prints "SomeFunc," but the first line of Main.hs ("module Main where") is underlined in red with this message: "ghcide compiled by GHC 8.10 failed to load packages: : cannot satisfy -package TestHaskell-0.1.0.0 (use -v for more information). Please ensure that ghcide is compiled with the same GHC installation as the project.cradle". Any ideas on how to fix this? Haven't been able to find anything on this. I'm able to use stack ghci to test the functions.
I also faced this issue. There is nothing I could find on this. I switched to using simple-ghc extension for ide, and Brittany for code formatting. I am 😊 now
i did everything exactly as you said. It was going fine but at the 15:15 mark. I got an error that said: Variable not in scope: add :: t0 ->t1 -> t Perhaps you meant one of these: 'and' (imported from prelude), 'odd' (imported from prelude)
How do you get the buttons (Load GHCI, Run File, QuickCheck) on the status bar to appear? Is it an extension? Saw you using it in next video but they dont appear for me
You don't need them, you can just use the terminal, but make sure the Haskelly (yes with a y) extension is installed and do a stack build from the terminal manually at least once
No idea if this is useful at all for new programmers but i've spent 8 hours trying to install this piece of trash language and your video for a college course and your video finally got me through it
Glad to help. The reason alot of programming languages/tools are difficult to install is most of them assume you are already a competent programmer and are using a "package manager". This is far from a unique haskell problem, especially on windows I find many students have a lot of trouble getting a good python setup going, and that's one of the more accessible languages. If you are interested in figuring out how to use a package manager for installing these kinds of tools, maybe check out this video ruclips.net/video/Ze42MmGG0zQ/видео.html
When i do a stack build in a powershell outside of VSC I get this result: Preparing to download msys2-20210604 ... Download expectation failure: HttpExceptionRequest Request { ... } ConnectionTimeout. NO build . Stack is installed and path set etc... I do wonder ?
Hello. Nice video. After i reopen a project, all the buttons in the status bar are missing (Load GHCI, Stack Test, Stack Build, Stack Run). I can still build and run my program by using command lines in the terminal. Any idea how to get the buttons back? I tried to reload the extensions with no luck. Also how do i get ghci to show the type of an expression? (Nvm found the :info command helpful!)
Make sure the Haskelly extension (yes with a y at the end) is installed (it usually installs with the Haskell extension but not always) and build the project with stack build from the terminal manually at least once
Hi Curtis, I was following along but had to stop at 15:35 you demonstrate using the status bar to load GHCI "commands", my status bar does not have any commands, other than the normal from a basic install. LHS has icons for "Problems" and RHS has editor information. Is this functionality a seperate plug in? I googled for about an hour to try to find the solution but came up with nothing specific to this.
Sometimes you need to load a project and build it manually from the terminal with stack build, then restart before it appears. As a side note: you don’t really need any of those buttons you can just use the commands from terminal manually
@@CurtisDAlves I don't have these buttons either, but they would be very neat. I don't really understand what you mean by "load a project and build it manually". Is it the project I created with stack new ProjectName?
@@pendax "load the project and build it manually" means open the terminal and type in "stack build" to build it or "stack ghci src/Lib.hs" to load it into ghci
at 13:35 I am not able to type the code stack build and get any results therefore not being able to edit the code. and I also don't see any shortcuts on the bottom blue bar. Any suggestions?
Gonna have to be more specific than "not able to type the code stack build" ... did you make sure stack is installed?? did you open the terminal?? Did you make sure you are on the terminal tab and not the output tab like i showed?? do you have a haskell project open in the first place?? Also you should be able to "edit the code" regardless of if you can run stack build/ghci
Curtis D'Alves do you have office hours where maybe I can show it to you or speak directly. I’m sure I followed all the steps but I’m new to coding so I’m a little lost.
If I am still using the command line to run, why am I using an IDE? I can use notepad++ instead. Why doesn't run button working? I installed haskelly. No change! Any idea?
The haskelly extension (yes with a y) gives those buttons, but my advice is just use the terminal instead as I do most of the time in my videos, those buttons are just shortcuts and not needed
Hi Curtis, i've got a Problem, when I try to execute "stack new Projekt" this leads to this excepetion : "Downloading template "new-template" to create project "helloworld" in helloworld\ ... There was an unexpected HTTP error while downloading template new-template: HttpExceptionRequest Request { host = "raw.githubusercontent.com" port = 443 secure = True requestHeaders = [("User-Agent","The Haskell Stack")] path = "/commercialhaskell/stack-templates/master/new-template.hsfiles" queryString = "" method = "GET" proxy = Nothing rawBody = False redirectCount = 10 responseTimeout = ResponseTimeoutDefault requestVersion = HTTP/1.1 } (ConnectionFailure user error (Network.Socket.gai_strerror not supported: 11003))"
Just delete the ~/.stack directory after, although if you're in computer science i highly recommend learning Haskell beyond one assignment. Functional programming is here to stay
hello . Thank you for ur help when i tried to change the name after writing the command cd documents it shows error . It shows cant find the path ...... it doesnt exist what should i have to do as i am beginner for this . Please reply it as soon as you can thank you
@@jonathantea913 it's possible your code has an error elsewhere that's preventing the type checker from inferring whatever you've selected, or the Haskell extension just didn't install correctly
when I go in PowerShell and run 'stack ghci' it just keeps trying to download things, I have already ran it multiple times but it doesn't ever launch the Haskell interpreter, just tries to do the download again and again. Any help?
The first time you run stack it will download ghc, just let it do it's thing and you shouldn't have to download it again unless you specify a different resolver
Hi! your video was really helpful, thanks!! Though I don't have the options you used at minute 13:16. Plus whenever i try to run the add function it always returns this error message: "variable not in scope: add :: Integer -> Integer -> t". Can someone help me out?
You don't really need those buttons, you can just enter `stack build`, `stack run` or `stack ghci src/Lib.hs` in terminal directly. However making sure the Haskelly extension (yes with a y) and the Haskell extension are both installed and then restarting vs code might help. Also you might have to run `stack build` from terminal at least once with a new project. As for your other issue, did you make sure to save the file before loading into ghci??
if you don't have those options, you could install try installing the haskell extension. However you don't really need them, you could load ghci through the terminal like I show you. If you are getting "variable not in scope" you probably didn't load the file properly into ghci (possibly there was an error that prevented it from loading or you didn't properly point stack ghci to the correct file)
Hi, Thanks for sharing! I have a question regarding to load GHCI, when I type stack ghci src/Lib.hs, it works well and load the Lib module, however when I try the second way by just clicking the load GHCI in the blue bar, it says 1 of 3] Compiling Lib ( D:\\data\AAhaskell\haskell1\src\Lib.hs, interpreted ) [2 of 3] Compiling Main ( D:\data\AAhaskell\haskell1\app\Main.hs, interpreted ) [3 of 3] Compiling Paths_haskell1 ( D:\\data\AAhaskell\haskell1\.stack-work\dist\274b403a\build\autogen\Paths_haskell1.hs, interpreted ) Ok, three modules loaded. Loaded GHCi configuration from C:\\Users\\Ruiyi Shen\\AppData\\Local\\Temp\\haskell-stack-ghci\\e75debef\\ghci-script : error: can't find file: Lib.hs Failed, no modules loaded. May I ask why this error happen?
@@NoneStopDamage I'm guessing you're not executing the command from the project root, P.S did you see there's an updated version of this video that clears up some of these issues? It's in the video description
Hello Curtis, i have followed your steps in installing haskell, its already been hours but it is still downloading, there's nothing wrong in this right? probably just the internet connection? or do i have to reinstall i again?, im very sorry im a beginner. ghc-8.8.4: 2.18 MiB / 195.22 MiB ( 1.12%) downloaded... Network.Socket.recvBuf: invalid argument (Invalid argument)
so before you execute the command, use the command pwd to see the path of the directory you are currently in. The folder will be created inside of that directory
Hi Curtis Thank you very much for your video, but I had an issue while following your instructions on setting up the first Haskell Project. My problem is that I failed to build TestHaskell and I received an error message saying 'C:\Users mili\AppData\Local\Programs\stack\x86_64-windows\ghc-8.8.4\bin\ghc-pkg.exe' exited with an error: ghc-pkg.exe: hLock: permission denied (Access is denied.) ), Can you help thank you !
and at the top of Main.hs and Lib.hs, the lines " module Main where" and "module Lib" both have curly lines underneath, with error message: readCreateProcess: stack "exec" "ghc" "--" "-rtsopts=ignore" "-outputdir" "C:\\Users\ mili\\AppData\\Local\\Temp\\hie-bios-98c9848bfed41b00" "-o" "C:\\Users\ mili\\AppData\\Local\\hie-bios\\wrapper-4da94d68375fab32d2147da1837e9611.exe" "C:\\Users\ mili\\AppData\\Local\\hie-bios\\wrapper-4da94d68375fab32d2147da1837e9611.hs" (exit 1): failedcompiler Peek Problem (Alt+F8) No quick fixes available
Sounds like you tried to create a stack project in a directory you don’t have permission to. Try using the cd command to change directories (say to your Documents by doing cd ~/Documents) and create it there
@@CurtisDAlves hi Curtis, thank you for your reply. It seemed that antivirus is the problem for me, as whenever I tried to build a new hs file, there will be a pop up from Norton, saying data protector has blocked an action by Haskell server. After I asked Norton to exclude specifically such action, I could successfully compile and run my hs files. However, the problem is that the curly lines under "module Main where" and "module Lib" remain. How can I remove the curly lines and its associated error messages as shown in my second question above?
For some reason when I type "Stack New TestHaskell" to create a new folder, it gives the error "The term Stack is not recognize as the name of the cmdlet, function..... verify that the path is correct and try again." Any solutions?
So first thing first, are you capitalizing stack and new?? Don’t do that. Otherwise, it seems you failed to properly install stack. Try reinstalling and making sure the install location is in your PATH variable
@@CurtisDAlves Well it worked, I actually downloaded it another folder in another drive. The curious thing is though installing Haskell Packing tool automatically creates a folder called "Bin" which I also had to specify in my directory for the new Test Haskell folder to be created. That part still eludes me a bit. Edit: Nope now it works if I just specify the drive, don't even need to mention the folder in which the stacking tool is installed, guess I messed up somewhere before. Edit 2: And now it works even in other drives. I am now officially confused as to why it did not work before.
I've had a similar problem, on Windows 10, where stack worked in every scenario except in VS Code, and as stupid as it sounds, a simple restart fixed it, so it may be something to do with Windows as opposed to the applications. I also have no idea though, so take it with a grain of salt, It worked after a restart.
@@CurtisDAlvesIn my case, the error message is this: Lib> add 1 2 :2:1: error: * Variable not in scope: add :: Integer -> Integer -> t * Perhaps you meant one of these: `and' (imported from Prelude), `odd' (imported from Prelude)
Hi, I want to ask when we watch all videos, what level of knowledge do we have in Haskell? After this tutorial, can we move on to learning the Yesod framework? Thanks.
I'm not done these tutorials yet, but by the time we are finished you should have a beginners level's knowledge of Haskell. Yesod is a fairly advanced framework, I would recommend continuing to learn more intermediate level haskell through a book like Real World Haskell before tackling it
@@CurtisDAlves I start with Real World Haskell book, but at some point the book became very complicated, so I came to your tutorial. Do you maybe familiar with Yesod and can you recommend me some literature?
@@nemanjam6574 these tutorials and Learn You A Haskell are good for beginners, then Real World Haskell movingore intermediate, then try your own projects and maybe some simpler frameworks
You are literally the only one on RUclips who has very clearly explained how to get Haskell setup and running. VS is a bonus, thank you!
This is the best tutorial on RUclips for downloading and using Haskell on VSCode. So easy to follow, thank you!
For anyone who had the same problem as me where it would tell you that "stack" is an unrecognised keyword or smth along those lines, try restarting VS and it should work. Worked for me.
thanks a lot man
Thanks this still works on macOS in late 2021. This was the toughest programming language to install. Thanks for the tutorial. Really crystal clear and understandable.
Reference on how to create a new Haskell project. :^)
9:03
9:45
15:08
Thanks so much man, very easy to follow! Now I can start my coursework lol
Plutus pioneers?
Thank you so much for this! I was looking for a tutorial on how to use VSCode for hours now and I finally came across yours!! I really appreciate the effort you put into making this! Thank you so so much :)
A modern and good way to explain Haskell
Man I love you, I was struggling to make it work, and your video saved me!
Russia here, hi everyone. Good luck! Thanks for this video.
So I built it, ran it, and it prints "SomeFunc," but the first line of Main.hs ("module Main where") is underlined in red with this message:
"ghcide compiled by GHC 8.10 failed to load packages: : cannot satisfy -package TestHaskell-0.1.0.0
(use -v for more information).
Please ensure that ghcide is compiled with the same GHC installation as the project.cradle".
Any ideas on how to fix this? Haven't been able to find anything on this. I'm able to use stack ghci to test the functions.
Got this issue as well
I have got this error too on MacOS vs. Although it is still runnable and gives the output of the someFunc.
I also faced this issue. There is nothing I could find on this. I switched to using simple-ghc extension for ide, and Brittany for code formatting. I am 😊 now
i did everything exactly as you said. It was going fine but at the 15:15 mark. I got an error that said:
Variable not in scope: add :: t0 ->t1 -> t
Perhaps you meant one of these:
'and' (imported from prelude), 'odd' (imported from prelude)
I'm guessing you just forgot to save your file or didn't load it into GHCi
How do you get the buttons (Load GHCI, Run File, QuickCheck) on the status bar to appear? Is it an extension? Saw you using it in next video but they dont appear for me
You don't need them, you can just use the terminal, but make sure the Haskelly (yes with a y) extension is installed and do a stack build from the terminal manually at least once
Thanks man.
Exactly what I was expecting to setup before starting to learn Haskell.
Thanks M. D'Alves. Look forward to learning more
No idea if this is useful at all for new programmers but i've spent 8 hours trying to install this piece of trash language and your video for a college course and your video finally got me through it
Glad to help. The reason alot of programming languages/tools are difficult to install is most of them assume you are already a competent programmer and are using a "package manager". This is far from a unique haskell problem, especially on windows I find many students have a lot of trouble getting a good python setup going, and that's one of the more accessible languages. If you are interested in figuring out how to use a package manager for installing these kinds of tools, maybe check out this video ruclips.net/video/Ze42MmGG0zQ/видео.html
@@CurtisDAlves that definitely helped too, never saw any motivation for using these either before now.
Thank you very much. I really need this help in macOS.
I don't see the "Stack build" or "Load GHCI" on VScode, is there any way to make them appear for me
when i input stack build @ 12:24 i do not get any response back it.
can someone help me.
When i do a stack build in a powershell outside of VSC I get this result: Preparing to download msys2-20210604 ...
Download expectation failure: HttpExceptionRequest Request { ... } ConnectionTimeout. NO build . Stack is installed and path set etc... I do wonder ?
Hello. Nice video. After i reopen a project, all the buttons in the status bar are missing (Load GHCI, Stack Test, Stack Build, Stack Run). I can still build and run my program by using command lines in the terminal. Any idea how to get the buttons back? I tried to reload the extensions with no luck.
Also how do i get ghci to show the type of an expression? (Nvm found the :info command helpful!)
Make sure the Haskelly extension (yes with a y at the end) is installed (it usually installs with the Haskell extension but not always) and build the project with stack build from the terminal manually at least once
Thanks man, super helpful!!! best tutorial out there
Hi Curtis, I was following along but had to stop at 15:35 you demonstrate using the status bar to load GHCI "commands", my status bar does not have any commands, other than the normal from a basic install. LHS has icons for "Problems" and RHS has editor information. Is this functionality a seperate plug in? I googled for about an hour to try to find the solution but came up with nothing specific to this.
Sometimes you need to load a project and build it manually from the terminal with stack build, then restart before it appears. As a side note: you don’t really need any of those buttons you can just use the commands from terminal manually
@@CurtisDAlves I don't have these buttons either, but they would be very neat. I don't really understand what you mean by "load a project and build it manually". Is it the project I created with stack new ProjectName?
@@pendax "load the project and build it manually" means open the terminal and type in "stack build" to build it or "stack ghci src/Lib.hs" to load it into ghci
@@CurtisDAlves I see. Well, it doesn't help. I'm on a Mac. Maybe there is a conflict with some other extension I have? I will try to disable some.
Answering myself: Disabling all extensions except Haskell and Haskell Syntax Highlighting didn't help.
at 13:35 I am not able to type the code stack build and get any results therefore not being able to edit the code. and I also don't see any shortcuts on the bottom blue bar. Any suggestions?
Gonna have to be more specific than "not able to type the code stack build" ... did you make sure stack is installed?? did you open the terminal?? Did you make sure you are on the terminal tab and not the output tab like i showed?? do you have a haskell project open in the first place?? Also you should be able to "edit the code" regardless of if you can run stack build/ghci
Curtis D'Alves do you have office hours where maybe I can show it to you or speak directly. I’m sure I followed all the steps but I’m new to coding so I’m a little lost.
Šhrëya J please contact me either on Microsoft Teams or by email about that
Any suggestion, I wanna execute add function, Instead of showing Lib > showing ghci> with a warning printing the result.
Same issue... Do you have any solution?
Thank you so much! The only video that really helped me!!
Thanks for the video man , keep it up . loved the content
If I am still using the command line to run, why am I using an IDE? I can use notepad++ instead. Why doesn't run button working? I installed haskelly. No change! Any idea?
how do you create a project with ghci, instead of stack on macOS
hmm getting perm denied error on stack build ... looks like the location of where the build files are stored didn't get installed ... thoughts?
Are you on windows? Reinstall and change the install location, make sure you have permissions on those folders
Hey Curtis, I have tried restarting VS Code but the Stack buttons dont appear, what shoud I do?
The haskelly extension (yes with a y) gives those buttons, but my advice is just use the terminal instead as I do most of the time in my videos, those buttons are just shortcuts and not needed
how did he save the add function?
Hi Curtis, i've got a Problem, when I try to execute "stack new Projekt" this leads to this excepetion :
"Downloading template "new-template" to create project "helloworld" in helloworld\ ...
There was an unexpected HTTP error while downloading template new-template: HttpExceptionRequest Request {
host = "raw.githubusercontent.com"
port = 443
secure = True
requestHeaders = [("User-Agent","The Haskell Stack")]
path = "/commercialhaskell/stack-templates/master/new-template.hsfiles"
queryString = ""
method = "GET"
proxy = Nothing
rawBody = False
redirectCount = 10
responseTimeout = ResponseTimeoutDefault
requestVersion = HTTP/1.1
}
(ConnectionFailure user error (Network.Socket.gai_strerror not supported: 11003))"
This is most likely due to your internet connection, try again making sure you are connected to the internet
Is this fairly simple to uninstall? I only need Haskel for one assignment and dont want all this on my PC.
Just delete the ~/.stack directory after, although if you're in computer science i highly recommend learning Haskell beyond one assignment. Functional programming is here to stay
hello . Thank you for ur help when i tried to change the name after writing the command cd documents it shows error . It shows cant find the path ...... it doesnt exist what should i have to do as i am beginner for this . Please reply it as soon as you can thank you
How did u get vs code to show the preview function type above the code? are u using an extension? thanks
Yea I explain in the video how to install the Haskell extenstion
@@CurtisDAlves ive downloaded the haskell ext but i dont get the type on hover
@@jonathantea913 it's possible your code has an error elsewhere that's preventing the type checker from inferring whatever you've selected, or the Haskell extension just didn't install correctly
when I go in PowerShell and run 'stack ghci' it just keeps trying to download things, I have already ran it multiple times but it doesn't ever launch the Haskell interpreter, just tries to do the download again and again. Any help?
The first time you run stack it will download ghc, just let it do it's thing and you shouldn't have to download it again unless you specify a different resolver
@@CurtisDAlves I figured it out, it was having problems decompressing. So every time I tried to run 'stack ghci' it would fail and try again
Hi! your video was really helpful, thanks!!
Though I don't have the options you used at minute 13:16.
Plus whenever i try to run the add function it always returns this error message: "variable not in scope: add :: Integer -> Integer -> t".
Can someone help me out?
You don't really need those buttons, you can just enter `stack build`, `stack run` or `stack ghci src/Lib.hs` in terminal directly. However making sure the Haskelly extension (yes with a y) and the Haskell extension are both installed and then restarting vs code might help. Also you might have to run `stack build` from terminal at least once with a new project.
As for your other issue, did you make sure to save the file before loading into ghci??
if you don't have those options, you could install try installing the haskell extension. However you don't really need them, you could load ghci through the terminal like I show you. If you are getting "variable not in scope" you probably didn't load the file properly into ghci (possibly there was an error that prevented it from loading or you didn't properly point stack ghci to the correct file)
I had the same problem, just simply save the file and write "stack build" and it will work.
How do you open the VS Code terminal on a mac
The same as windows, there should be a terminal tab at the top
hi i still got somefunc even when i wrote hello world why did that happen can someone help please
Hi, Thanks for sharing!
I have a question regarding to load GHCI, when I type stack ghci src/Lib.hs, it works well and load the Lib module, however when I try the second way by just clicking the load GHCI in the blue bar, it says
1 of 3] Compiling Lib ( D:\\data\AAhaskell\haskell1\src\Lib.hs, interpreted )
[2 of 3] Compiling Main ( D:\data\AAhaskell\haskell1\app\Main.hs, interpreted )
[3 of 3] Compiling Paths_haskell1 ( D:\\data\AAhaskell\haskell1\.stack-work\dist\274b403a\build\autogen\Paths_haskell1.hs, interpreted )
Ok, three modules loaded.
Loaded GHCi configuration from C:\\Users\\Ruiyi Shen\\AppData\\Local\\Temp\\haskell-stack-ghci\\e75debef\\ghci-script
: error: can't find file: Lib.hs
Failed, no modules loaded.
May I ask why this error happen?
I keep getting the error " warning: Multiple files use the same module name:
* Paths_test found at the following paths"
It's prety safe to ignore that warning, however if you run "stack clean" (or manually remove the .stack-work directory) it should get rid of it
@@CurtisDAlves When i try to run GHCI src/Lib. hs I get an error it wont run. I can do everything up until that point
@@NoneStopDamage I'm guessing you're not executing the command from the project root, P.S did you see there's an updated version of this video that clears up some of these issues? It's in the video description
Hello Curtis, i have followed your steps in installing haskell, its already been hours but it is still downloading, there's nothing wrong in this right? probably just the internet connection? or do i have to reinstall i again?, im very sorry im a beginner.
ghc-8.8.4: 2.18 MiB / 195.22 MiB ( 1.12%) downloaded...
Network.Socket.recvBuf: invalid argument (Invalid argument)
Looks like poor internet connection or the server it's downloading GHC from is overloaded
Thank you so much for the tutorial
Hi, when I try the command "stack new TestHaskell", the folder doesn't pop up in my Documents.
so before you execute the command, use the command pwd to see the path of the directory you are currently in. The folder will be created inside of that directory
Hi Curtis Thank you very much for your video, but I had an issue while following your instructions on setting up the first Haskell Project. My problem is that I failed to build TestHaskell and I received an error message saying 'C:\Users
mili\AppData\Local\Programs\stack\x86_64-windows\ghc-8.8.4\bin\ghc-pkg.exe'
exited with an error:
ghc-pkg.exe: hLock: permission denied (Access is denied.)
), Can you help thank you !
and at the top of Main.hs and Lib.hs, the lines " module Main where" and "module Lib" both have curly lines underneath, with error message: readCreateProcess: stack "exec" "ghc" "--" "-rtsopts=ignore" "-outputdir" "C:\\Users\
mili\\AppData\\Local\\Temp\\hie-bios-98c9848bfed41b00" "-o" "C:\\Users\
mili\\AppData\\Local\\hie-bios\\wrapper-4da94d68375fab32d2147da1837e9611.exe" "C:\\Users\
mili\\AppData\\Local\\hie-bios\\wrapper-4da94d68375fab32d2147da1837e9611.hs" (exit 1): failedcompiler
Peek Problem (Alt+F8)
No quick fixes available
Sounds like you tried to create a stack project in a directory you don’t have permission to. Try using the cd command to change directories (say to your Documents by doing cd ~/Documents) and create it there
@@CurtisDAlves hi Curtis, thank you for your reply. It seemed that antivirus is the problem for me, as whenever I tried to build a new hs file, there will be a pop up from Norton, saying data protector has blocked an action by Haskell server. After I asked Norton to exclude specifically such action, I could successfully compile and run my hs files.
However, the problem is that the curly lines under "module Main where" and "module Lib" remain. How can I remove the curly lines and its associated error messages as shown in my second question above?
@@rmiliming I'd try just restarting vs code and creating a new project
For some reason when I type "Stack New TestHaskell" to create a new folder, it gives the error "The term Stack is not recognize as the name of the cmdlet, function..... verify that the path is correct and try again." Any solutions?
So first thing first, are you capitalizing stack and new?? Don’t do that. Otherwise, it seems you failed to properly install stack. Try reinstalling and making sure the install location is in your PATH variable
@@CurtisDAlves Well it worked, I actually downloaded it another folder in another drive. The curious thing is though installing Haskell Packing tool automatically creates a folder called "Bin" which I also had to specify in my directory for the new Test Haskell folder to be created. That part still eludes me a bit.
Edit: Nope now it works if I just specify the drive, don't even need to mention the folder in which the stacking tool is installed, guess I messed up somewhere before.
Edit 2: And now it works even in other drives. I am now officially confused as to why it did not work before.
I've had a similar problem, on Windows 10, where stack worked in every scenario except in VS Code, and as stupid as it sounds, a simple restart fixed it, so it may be something to do with Windows as opposed to the applications. I also have no idea though, so take it with a grain of salt, It worked after a restart.
Great Brother you are life sever Thank you
Hi, at 15.37, when i type add 1 2 in to VS code, it returns error. I did exactly what you did but it didn't work at all
What was the error exactly?? Did you make sure to load the file into ghci properly? (i.e was the file saved, did you write stack ghci src/Lib.hs)
@@CurtisDAlvesIn my case, the error message is this:
Lib> add 1 2
:2:1: error:
* Variable not in scope: add :: Integer -> Integer -> t
* Perhaps you meant one of these:
`and' (imported from Prelude), `odd' (imported from Prelude)
I did catch my mistake. I didn't save the project before the stack ghci src/lib.hs. Simple mistakes build giant debugging. LOL
Hi, I want to ask when we watch all videos, what level of knowledge do we have in Haskell?
After this tutorial, can we move on to learning the Yesod framework? Thanks.
I'm not done these tutorials yet, but by the time we are finished you should have a beginners level's knowledge of Haskell. Yesod is a fairly advanced framework, I would recommend continuing to learn more intermediate level haskell through a book like Real World Haskell before tackling it
@@CurtisDAlves I start with Real World Haskell book, but at some point the book became very complicated, so I came to your tutorial. Do you maybe familiar with Yesod and can you recommend me some literature?
@@nemanjam6574 these tutorials and Learn You A Haskell are good for beginners, then Real World Haskell movingore intermediate, then try your own projects and maybe some simpler frameworks
Was helpful, thanks
A Good start
Thks, great video. Easy to follow. -ve => font too small.
Super helpful!
Thank you so much
Great tutorial and set up to get started with Haskell, got here through to the Plutus Pioneer Program, like if you are enrolled as well 🔥😉
Many thanks for this
thanks :)