trungleduc / jupyter_app_launcher

A JupyterLab extension to create custom launcher entries.
https://jupyter-app-launcher.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
53 stars 11 forks source link

url works, notebook doesn't, need absolute path example #18

Closed hcchengithub closed 1 year ago

hcchengithub commented 1 year ago

Three icons shown on Jupyterlab launcher but click them make no response. No clue and I can't find what's wrong in my config.ymal or the notebook file location?

My config.ymal is at : c:\Users\myname\AppData\Roaming\Python\share\jupyter\jupyter_app_launcher\config.yaml and it reads:

 - title: test.ipynb 1
    description: test.ipynb 1
    source: ./test.ipynb
    type: notebook
    cwd: ../../samples
    catalog: Jupyter app launcher

  - title: test.ipynb 2
    description: test.ipynb 2
    source: ../test.ipynb
    type: notebook
    cwd: ../../samples
    catalog: Jupyter app launcher

  - title: test.ipynb 3
    description: test.ipynb 3
    source: test.ipynb
    type: notebook
    cwd: ../../samples
    catalog: Jupyter app launcher

I have many test.ipynb respectively at :
c:\Users\myname\AppData\Roaming\Python\share\jupyter\jupyter_app_launcher\test.ipynb c:\Users\myname\AppData\Roaming\Python\share\jupyter\test.ipynb c:\Users\myname\AppData\Roaming\Python\share\test.ipynb

trungleduc commented 1 year ago

Thanks for reporting the issue. I will take a look at it.

trungleduc commented 1 year ago

Sorry but I can not reproduce your issue, the first block of your config file works well on my PC.

path-issue

Could you verify your YAML file is well formatted? I got an indent issue when I copy the content of your file.

hcchengithub commented 1 year ago

The gif provides enough missing info for me to go on trying, thank you very much !!

從 Windows 的郵件https://go.microsoft.com/fwlink/?LinkId=550986傳送

寄件者: Duc Trung @.> 傳送時間: Wednesday, October 19, 2022 03:42 收件者: @.> 副本: H.C. @.>; @.> 主旨: Re: [trungleduc/jupyter_app_launcher] url works, notebook doesn't, need absolute path example (Issue #18)

Sorry but I can not reproduce your issue, the first block of your config file works well on my PC.

[path-issue]https://user-images.githubusercontent.com/4451292/196527682-4fd2f68c-1c87-4b08-9495-45a97464d1ac.gif

Could you verify your YAML file is well formatted? I got an indent issue when I copy the content of your file.

— Reply to this email directly, view it on GitHubhttps://github.com/trungleduc/jupyter_app_launcher/issues/18#issuecomment-1282915908, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAJ4U56GEQVQEDL56O3DF2TWD34SFANCNFSM6AAAAAARHT6IBA. You are receiving this because you authored the thread.Message ID: @.***>

hcchengithub commented 1 year ago

"type: notebook" still not work here while "type: url" works fine. The notebook icon appears on launcher but click it makes nothing happen. What else can I check? other than that I have listed below FYR:

Microsoft Windows [版本 10.0.19044.2130]
(c) Microsoft Corporation. 著作權所有,並保留一切權利。

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>jupyter --path
config:
    C:\Users\user\.jupyter
    C:\Users\user\AppData\Roaming\Python\etc\jupyter
    c:\Users\user\miniconda3\envs\jupyter_app_launcher\etc\jupyter
    C:\ProgramData\jupyter
data:
    C:\Users\user\AppData\Roaming\jupyter
    C:\Users\user\AppData\Roaming\Python\share\jupyter
    c:\Users\user\miniconda3\envs\jupyter_app_launcher\share\jupyter
    C:\ProgramData\jupyter
runtime:
    C:\Users\user\AppData\Roaming\jupyter\runtime

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>jupyter serverextension list
config dir: c:\Users\user\miniconda3\envs\jupyter_app_launcher\etc\jupyter
    jupyter_server_proxy enabled
    - Validating...
      jupyter_server_proxy  ok
    jupyter_app_launcher enabled
    - Validating...
      jupyter_app_launcher 0.1.5 ok
    jupyterlab enabled
    - Validating...
      jupyterlab 3.4.4 ok

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>jupyter labextension list
JupyterLab v3.4.4
c:\Users\user\miniconda3\envs\jupyter_app_launcher\share\jupyter\labextensions
        jupyter_app_launcher v0.1.5 enabled ok (python, jupyter_app_launcher)
        @jupyterlab/server-proxy v3.2.2 enabled ok

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>dir
 磁碟區 C 中的磁碟沒有標籤。
 磁碟區序號:  EA50-09EE

 C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher 的目錄

10/21/2022  10:02 PM    <DIR>          .
10/21/2022  10:02 PM    <DIR>          ..
10/21/2022  09:58 PM               174 config.yaml
11/10/2020  05:39 AM               961 sample.ipynb
               3 個檔案          38,736 位元組
               2 個目錄  27,131,531,264 位元組可用

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>type config.yaml
- title: Notebook example
  description: Example of opening a notebook
  source: ./sample.ipynb
  type: notebook
  cwd: ../../samples
  catalog: Another catalog

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>type sample.ipynb
{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [],
   "source": [
    "# 11/10/2020 摰嗉ㄐ? desktop ??python 撠梁隞乩??身摰??n",
    "#\t1. 敺?Visual Studio 2019 > PythonApplication1 ( or 'Python Environment') > Power Shell\n",
    "#\t2. (playground) C:\\Users\\User\\source\\repos\\PythonApplication1\\playground>\n",
    "#\t3. CD ??c:\\Users\\User\\OneDrive  ?瑁? jupyter notebook\n",
    "\n",
    "import sklearn\n",
    "import peforth"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}

(jupyter_app_launcher) C:\Users\user\AppData\Roaming\jupyter\jupyter_app_launcher>
trungleduc commented 1 year ago

Can you check the log of the server in the console where you start jupyterlab, and the log of the Jupyterlab frontend (right-click on the browser -> Inspect -> Console)?