Como instalar corretamente a extensão nbgrader?

1

Eu me deparei com este erro ao tentar instalar a extensão nbgrader para o jupyterhub. O erro pode ser trivial, mas não consigo consertá-lo.

nbgrader extension install

Unrecognized JSON config file version, assuming version 1
Installing create_assignment extension
Making directory: /usr/local/share/jupyter/nbextensions/create_assignment/
Traceback (most recent call last):
  File "/home/mark/.local/bin/nbgrader", line 11, in <module>
    sys.exit(main())
  File "/home/mark/.local/lib/python3.5/site-packages/nbgrader/apps/nbgraderapp.py", line 249, in main
    NbGraderApp.launch_instance()
  File "/home/mark/.local/lib/python3.5/site-packages/jupyter_core/application.py", line 267, in launch_instance
    return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
  File "/home/mark/.local/lib/python3.5/site-packages/traitlets/config/application.py", line 596, in launch_instance
    app.start()
  File "/home/mark/.local/lib/python3.5/site-packages/nbgrader/apps/nbgraderapp.py", line 242, in start
    super(NbGraderApp, self).start()
  File "/home/mark/.local/lib/python3.5/site-packages/jupyter_core/application.py", line 256, in start
    self.subapp.start()
  File "/home/mark/.local/lib/python3.5/site-packages/nbgrader/apps/extensionapp.py", line 249, in start
    super(ExtensionApp, self).start()
  File "/home/mark/.local/lib/python3.5/site-packages/jupyter_core/application.py", line 256, in start
    self.subapp.start()
  File "/home/mark/.local/lib/python3.5/site-packages/nbgrader/apps/extensionapp.py", line 56, in start
    self.install_extensions()
  File "/home/mark/.local/lib/python3.5/site-packages/nbgrader/apps/extensionapp.py", line 46, in install_extensions
    logger=self.log)
  File "/home/mark/.local/lib/python3.5/site-packages/notebook/nbextensions.py", line 206, in install_nbextension
    os.makedirs(dest_dir)
  File "/usr/lib/python3.5/os.py", line 241, in makedirs
    mkdir(name, mode)
PermissionError: [Errno 13] Permission denied: '/usr/local/share/jupyter/nbextensions/create_assignment/'

Agradecemos suas sugestões para superar esse problema.

    
por Moeen MH 20.08.2016 / 17:22

2 respostas

0

bem para este caso em particular, eu apenas tive que adicionar --user ao meu comando assim:

nbgrader extension install --user

Eu não sei como, mas resolve o problema.

    
por 20.08.2016 / 17:58
0

Se você instalar nbgrader com conda , isso não será um problema:

 $ conda install nbgrader -c conda-forge
    
por 13.11.2018 / 01:57