# \[Tutor\] A webui - for real this time

**URL:** https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537
**Category:** Development
**Tags:** tutor
**Created:** [December 8, 2024, 12:33pm UTC](https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537 "2024-12-08T12:33:42Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![arunmozhi](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/arunmozhi/32/3600_2.png) [@arunmozhi](https://discuss.openedx.org/u/arunmozhi)
#### Post date: [December 8, 2024, 12:33pm UTC](https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537/1 "2024-12-08T12:33:42Z")

</div>

On a lazy day not knowing if it is `tutor plugin ls` or `tutor plugins list`, I discovered [tutor-webui](https://github.com/overhangio/tutor-webui) in the hopes that I probably won’t have to remember it ever again. There will be buttons and all I need to do it click. But I was thoroughly disappointed to learn it was actually a web-cli.

Anyway, I set out to see if I could whip one up quickly and behold the [tutor-contrib-webui-for-real](https://github.com/tecoholic/tutor-contrib-webui-for-real).

 ![Screenshot 2024-12-08 at 23-07-18 cli](https://us1.discourse-cdn.com/flex020/uploads/openedx/original/2X/8/85a7fc9c4d4c1b3d160255af40e7e016b407d742.png)

- It can run all the commands, including the ones added by other plugins
- It can stream real-time logs to the browser. I have even tried running a full `tutor dev launch`.

It primarily functions as a quick documentation for me personally, and I learnt a few commands and flags in the CLI, I previously didn’t know about.

P.S: Almost all the work is done by the [click-web](https://github.com/fredrik-corneliusson/click-web) library. I merely fixed a bug and wrapped it up as a Tutor plugin.

---

<div class="post-metadata">

### Author: ![regis](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/regis/32/2640_2.png) [@regis](https://discuss.openedx.org/u/regis)
#### Post date: [December 10, 2024, 9:53am UTC](https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537/2 "2024-12-10T09:53:09Z")

</div>

Neat! I’m actually working on something similar 🙂 Do you think it would be difficult to integrate stdout streaming with click-web, such that we could see the output of `tutor local launch -I` in real time? I managed to do this by hand with Flask and server-sent events (and some ugly hacks to capture stdout/stderr), but if it’s possible out of the box with click-web, then that’s even better.

I’m also wondering how easy it is to integrate and customise click-web in a bigger web app…

---

<div class="post-metadata">

### Author: ![arunmozhi](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/arunmozhi/32/3600_2.png) [@arunmozhi](https://discuss.openedx.org/u/arunmozhi)
#### Post date: [December 10, 2024, 9:45pm UTC](https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537/3 "2024-12-10T21:45:14Z")

</div>

Click-web streams both stdout and stderr to the webpage in realtime (maybe very close to realtime, I didn’t dig deep enough).

Here is it running `dev launch -I`

---

<div class="post-metadata">

### Author: ![arunmozhi](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.openedx.org/arunmozhi/32/3600_2.png) [@arunmozhi](https://discuss.openedx.org/u/arunmozhi)
#### Post date: [December 11, 2024, 3:58am UTC](https://discuss.openedx.org/t/tutor-a-webui-for-real-this-time/14537/4 "2024-12-11T03:58:44Z")

</div>

> [@regis](#):
>
> I’m also wondering how easy it is to integrate and customise click-web in a bigger web app…

Ah! I missed this one. click-web is basically a Flask app. The readme has some [notes on customization](https://github.com/fredrik-corneliusson/click-web?tab=readme-ov-file#custom-styling) and even authentication. I suspect it won’t be easy to plugin into something like a larger Django App.
