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

Directory for Perl kernel spec does not exist #118

Open
divyansshhh opened this issue Jul 27, 2023 · 4 comments
Open

Directory for Perl kernel spec does not exist #118

divyansshhh opened this issue Jul 27, 2023 · 4 comments

Comments

@divyansshhh
Copy link

I'm trying to install this using cpanm Devel::IPerl and tried executing perl5/bin/iperl but that fails with the following error -

Directory for Perl kernel spec does not exist...
Failed to find share dir for dist 'Devel-IPerl' at ./bin/iperl line 72.

Also, no files are getting created in the ~/.local/share/jupyter/kernels directory. Any thoughts on what is going wrong?

@E7-87-83
Copy link

Are you using Windows? or Mac?

My main platform has been Ubuntu, anyway, I tried to install IPerl on Windows last weekend and got similar error messages. I "handcrafted" a kernel.json file according to the Perl code, and "cheated" the Jupyter to get started and provide an option of IPerl as one of the kernels, but still had errors ultimately.

@divyansshhh
Copy link
Author

I am trying this out on rhel v8. Do let me know if more information is required.

@zmughal
Copy link
Member

zmughal commented Aug 4, 2023

Sorry, just saw this. Yes, that error message is related to trying to create the kernel spec (well, actually it's about getting the logo). I might be able to make it continue gracefully if that happens. Though I'm not sure why that happened.

Just want to check, but why are you running it as ./bin/iperl? Is it not in your PATH? I just want to make sure that the correct script is being run.


I'm going to try to replicate all those environments and get back to you (@divyansshhh's RHEL v8, @E7-87-83's Windows).

You didn't have problems on Ubuntu did you, @E7-87-83?

Which version of Perl are you using perl -v? What about perl -MFile::ShareDir=99999?


An example in a Docker started with

docker run --rm -it  perl:5.38 bash -c 'apt-get update ;
  apt-get install -y --no-install-recommends libzmq5 jupyter-console jupyter-notebook jq;
  cpanm -nq Devel::IPerl;
  bash'
root@:/#  rm -Rf ~/.local/share/jupyter/kernels/iperl; cpanm -nq Devel::IPerl ; iperl ; ls ~/.local/share/jupyter/kernels/iperl; jq < ~/.local/share/jupyter/kernels/iperl/kernel.json; jupyter --help | grep 'subcommands'
Devel::IPerl is up to date. (0.012)
Directory for Perl kernel spec does not exist...
Jupyter console 6.4.4

IPerl!
In [1]: <Ctrl-D>
Do you really want to exit ([y]/n)? y
Shutting down kernel
kernel.json  logo-32x32.png  logo-64x64.png
{
  "argv": [
    "/usr/local/bin/perl",
    "-Mutf8",
    "-Mopen qw(:std :encoding(UTF-8))",
    "-MDevel::IPerl",
    "-e Devel::IPerl::main",
    "kernel",
    "{connection_file}"
  ],
  "language": "perl",
  "display_name": "IPerl 0.012",
  "iperl_version": "0.012"
}
Available subcommands: bundlerextension console execute migrate nbextension

@divyansshhh
Copy link
Author

I missed this update, answering the questions -

  1. perl version is -
This is perl 5, version 26, subversion 3 (v5.26.3) built for x86_64-linux-thread-multi
(with 58 registered patches, see perl -V for more detail)
  1. Here's the output of perl -MFile::ShareDir=99999 -
╰─$ perl -MFile::ShareDir=99999
File::ShareDir version 99999 required--this is only version 1.104 at /usr/share/perl5/vendor_perl/Exporter/Heavy.pm line 125.
BEGIN failed--compilation aborted.
  1. I added it to my PATH but I still encounter this error -
╭─choudhdi@narada28 ~/perl5/bin
╰─$ export PATH=/u/choudhdi/perl5/bin:$PATH                               255 ↵
╭─choudhdi@narada28 ~/perl5/bin
╰─$ cd
╭─choudhdi@narada28 ~
╰─$ iperl
Directory for Perl kernel spec does not exist...
Failed to find share dir for dist 'Devel-IPerl' at /u/choudhdi/perl5/bin/iperl line 72.

Please do let me know if there is any other info required.

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

No branches or pull requests

3 participants