Comments (10)
If your cell stays marked as busy, the kernel is almost certainly dead. The console interface is a bit broken right now - I've been developing mostly for notebook and really need to work on the console as well. :{ code :}
is not supported, either; sorry about that... feel free to create a feature request issue.
As for notebook errors - can you switch back to 03c5a95, run IHaskell setup
and IHaskell notebook
and then find a minimal broken example? Then, paste output of those two commands as well as the files in ~/.ipython/profile_haskell/*.py.
Although everything should work on IPython 1.0.0, you could also try switching to HEAD and seeing if it works. I'm not sure why the kernel is dying and need a bit more info to go on :(
from ihaskell.
:{ code :}
is not supported
Really? I paste this into the console and it seems to work:
In [3]: :{
...: data Value = X Int
...: | Y String
...: | Z Float
...: deriving Show
...:
...: let values = [X 20,
...: Y "Test",
...: Z 0.5]
...: mapM_ print values
...: :}
Out[3]:
X 20
Y "Test"
Z 0.5
I may have been unclear, but I only tried this in the console, and it works with or without :{ :}
. I'm new to Haskell, but I thought I read that it's required for multiline ghci input. But I assumed multiline input is expected in the notebook without :{ :}
by default, so it would be unnecessary anyways.
from ihaskell.
After
git stash
git checkout 03c5a95
IHaskell setup
cabal install
IHaskell notebook
I tried to print again, and terminal output is here. I'll update IPython in a minute and see if that helps.
from ihaskell.
Whoa, you're right! About the :{ ... :}
. ...I think this might be an accident. Python recognizes the ':' characters as Python delimiters and thus enters multiline mode. Then, IHaskell interprets :{
and :}
as directives (along the lines of :t
). It doesn't report an error (that's a bug!) and just does nothing. Then, it interprets the rest of the code block as it would for the notebook. As a result, :{
and :}
work... by accident. Whoa.
from ihaskell.
Interesting on multilines...didn't know python sees ':' as a delimiter, maybe an IPython thing? I think they have really flexible parsing, you can even paste in In [1]: ...
or >>>
in the cells at the start of a line and it doesn't care. (Makes it really nice for copy/pasting stuff from the web.)
from ihaskell.
By 'delimiter', I mean that ':' denotes the beginning of an indented block, as in
if condition:
# Indented block
pass
IPython handles that by starting a multiline input, which helps us in this case!
from ihaskell.
I just upgraded ipython--it was at 1.0.0 (4481c323e0d), now at 1.1.0 (7c2ea3a) (or did you mean I should try the 2.0 version?). cabal install'd and IHaskell setup'd again, and I'm still getting a busy signal. Though output looks similar. Not terribly descriptive...any other ideas on how to get logged info that could be useful?
from ihaskell.
I had been hesitant about upgrading to v2.0 dev since it wouldn't work for either language. Figured out the browser cache was messing things up so I cleared it and have the notebook working on both languages. Not sure if it was the ipython version or cache, but it's working! Thanks!
And for anyone else out there having trouble w/ IPython notebook dev version... clear your cache!
from ihaskell.
Huh, that's very strange. How do you clear the IPython cache? I'd like to add that to the README as a troubleshooting tip.
from ihaskell.
It's just the browser cache for whatever browser you're in. F5 usually works, but I had to go Settings > Show advanced > Clear browsing data > empty the cache in Chrome.
Also, I switched back to IP 1.1.0, and it didn't work, so that probably had more to do with it than the cache, but clearing the cache would be necessary for the IP version upgrade, I think. I've got a virtualenv working for IHaskell using IP 2.0 now, so both languages are happy for the time being...
from ihaskell.
Related Issues (20)
- Cannot allocate memory HOT 3
- Package not include: Failed to Build
- HLS for GHC 9 HOT 4
- nix run github:IHaskell/IHaskell#ihaskell -- install HOT 2
- ihaskell-diagrams-0.3.2.1 fails to build HOT 4
- Adding packages HOT 1
- Update `IHaskell.IPython.EasyKernel.installKernelspec` to use `jupyter` instead of `ipython` HOT 1
- New ghc-parser release? HOT 3
- Installation Fails in Apple Silicon MacBook HOT 6
- Nix instructions seem wildly out of date HOT 1
- Cannot install because of missing file on GitHub HOT 6
- Jupyter cannot connect to kernel from outside IHaskell folder. HOT 2
- Tests run "forever" HOT 5
- Notebooks don't correctly update the status of input cells HOT 3
- `jupyterlab-ihaskell` does not support JupyterLab 4.x HOT 1
- When installing from nix flake the ihaskell kernel does not become available in jupyter HOT 2
- IHaskell.Display.Widgets not available when using Nix packages HOT 3
- `nix/release.nix` doesn't work after #1425 HOT 1
- IHaskell not building on macOS HOT 2
- No persistent command history in jupyter console HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ihaskell.