we’ve been successfully starting to use girder as a data management platform using the web and python client library. it works fantastically smooth and gets out of the way. Now I’d like to go into extending the platform and starting plugin development. I’m familiar with the documentation on readthedocs.io and have read through it.
Right now I’m stuck with some very basics and would like to ask for help to get unstuck:
I’ve created a plugin directory with a corresponding plugin.json which shows up in the list of available plugins.
I’ve created a server directory with an init.py, here are the contents:
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from girder import logger
def load(info):
logger.info('my plugin loading!')
I would expect this to output a log message upon loading, nothing else.
To test, I activate the plugin on the admin console and click “rebuild and restart”. This results in an error. Looking into ~/.girder/logs/error.log I get the following output
[2018-07-25 10:58:15,718] ERROR: 500 Error
Traceback (most recent call last):
File "/girder/girder/api/rest.py", line 603, in endpointDecorator
val = fun(self, path, params)
File "/girder/girder/api/rest.py", line 1190, in POST
return self.handleRoute(method, path, params)
File "/girder/girder/api/rest.py", line 933, in handleRoute
val = handler(**kwargs)
File "/girder/girder/api/access.py", line 42, in wrapped
return fun(*args, **kwargs)
File "/girder/girder/api/describe.py", line 709, in wrapped
return fun(*args, **kwargs)
File "/girder/girder/api/v1/system.py", line 491, in buildWebCode
install.runWebBuild(dev=dev, progress=progress)
File "/girder/girder/utility/install.py", line 189, in runWebBuild
(' '.join(cmd), proc.returncode))
Exception: Web client install failed: `npm run build -- --no-progress=true --env=prod --plugins=myplugin --configure-plugins=` returned 6.
Can you please explain what I’m doing wrong?
I’ve tried following the plugin development tutorial on http://girder.readthedocs.io/en/latest/plugin-development.html but the examples provided there yield the same error.
Additional info:
Request URL: POST http://localhost:8080/api/v1/system/web_build
Query string:
Remote IP: 172.17.0.1
Environment:
Girder 2.5.0, deployed using docker image girder/girder
Any help is much appreciated!