Just released 0.2.0 of portal, a data browser similar to REBL https://github.com/djblue/portal/releases/tag/0.2.0. http://djblue.github.io/portal/ for a live demo.
This looks really cool, thanks! As an additional data point, I have Chrome installed, but I donβt like to use it unless I absolutely have to. I use https://www.fluidapp.com/ to get rid of unnecessary UI in frequently used webapps.
Very cool! I'm wondering if there are any plans to be able to edit fields and run callbacks on submit? I need something like this, but where I can edit the data as well. If this is to be purely for inspecting then I might fork this for my own usecase
@henrik, I think I'll update open to take some options. Currently I'm planning to add support for selecting a theme, but it could also take a disable chrome app flag or if people prefer to opt in instead, that could also work.
@kevin.van.rooijen editing is something I want as well, not sure how the ux would work. I was thinking of making atoms explicitly editable, I haven't thought too much about extensibility though.
If you guys want to chat more, I would suggest joining the #portal channel
This is awesome! It perfect fits my use case. Thanks for showcasing it! π
@djblue I just went to try this and discovered it doesn't work on Windows with Powershell (and then I looked at the source and it was obvious why). Maybe make that clear in the README to save other Windows folks some time?
This was the error, by the way:
Execution error (IllegalArgumentException) at clojure.java.shell/parse-args (shell.clj:47).
No value supplied for key: --app=<http://localhost:55899>
user=>
I can add windows support, should be pretty easy. Sorry about that.
FWIW, I get the exact same error on WSL on Windows. I thought that maybe starting it from Ubuntu would work since it tries to shell out to Chrome...?
(it looks very cool tho' -- so nice to see several open source REBL alternatives appearing -- it validates the approach is worth adopting more widely)
I think for now I will print the url if I can't find chrome
Happy to help debug it on Windows if you want...
https://github.com/djblue/portal/commit/8e3b17d534eb064386a67d2ba93d6ec779d8dc1a should fix it and can be pulled via git deps
Why try to use Chrome at all? Why not just use (clojure.java.browse/browse-url "<http://localhost:56232>")
That should open the default browser on every platform.
I didn't know about that. I wanted to use the --app
mode for chrome.
Not every has Chrome installed π
Could you fall back to browse-url
if it can't find chrome?
https://github.com/djblue/portal/commit/7919617f799a5be8c9ce72741c98b8b6ceaaa74e
I think that would probably be best
Why use Chrome's app mode? What benefits does that have over just opening to the URL in the default browser?
Cool. That works on Powershell. Thanks.
It enables me to eliminates the extra ui provided by chrome which isn't needed. It's mostly an aesthetic thing.
Ah, OK.
So I use Component and I tapped (alter-var-root #'system component/start)
and it seems to have crashed portal.
That would tap>
a record instance
After that, portal no longer responds to tap>
with any values.
Background: I have Atom/Chlorine set up to tap>
every REPL evaluation -- it's how I use Reveal and I figured it would work with Portal as well... which it does for some simple values...
It's probably related to my usage of transit
Any errors?
No. Just seems to lock up.
(in that it never displays any more values)
If you clear, does it get back to a usable state?
No. I ran (port/clear) (tap> :test)
and :test
did not appear.
If I do (port/close) (port/open)
the most recent tapped value shows up.
Did you tap>
any infinite seqs?
That would definitely break portal currently π
It definitely seems to be when I tap>
a Var that contains a Component (a large one but no loops in it).
You should be able to repro it easily in this example app https://github.com/seancorfield/usermanager-example
I'll take a look, thanks for the example app!
There's a comment
in the main.clj
that defines the system component and then starts it.
Once you have system
started, try to (tap> system)
and see what happens...
Error: No protocol method IWithMeta.-with-meta defined for type object: [TaggedValue: portal.transit/object, {:id #uuid "fa4bad2c-51fe-445b-97dd-31fce7326317", :type "clojure.core$promise$reify__8501", :string "#object[clojure.core$promise$reify__8501 0x2ce8cf77 {:status :pending, :val nil}]"}]
It was related to transit
It's because tagged values, which is what i turn everything that isn't normal clojure data into, doesn't support metadata.
I'll see if I can fix it π
https://github.com/djblue/portal/releases/tag/0.2.1 should fix it
Thanks again for trying out portal and finding these issues!
Trying the latest version...
I did git pull
and tried it again, and it still doesn't work -- exactly the same as before.
Are you still using it via git deps or the release version?
Ah, 0.2.1 isn't on the windows branch. My bad.
Sorry about that
Yup. 0.2.1 works perfectly.
Nice!
I'm going to delete the windows branch now then. Let me know if run into any other issues. Also, the ux is still WIP and I am very open to ideas.
Are there keyboard shortcuts for navigating back and forth?
Not yet, on my todo list though
let me know if you have any preferences
I'll update my atom-chlorine-setup
repo tomorrow with details about Portal so folks can choose Portal, or Reveal, or REBL.
Ardoq is happy to release verson 0.1.0 of azure-api which allows for simple usage of the Azure REST APIs in Clojure. https://github.com/ardoq/azure-api
CIDER 0.26 (Nesebar) and nREPL 0.8 are out! More details - https://github.com/clojure-emacs/cider/releases/tag/v0.26.0 and https://metaredux.com/posts/2020/06/15/nrepl-0-8-evolving-the-protocol.html Special thanks to Clojurists Together for their support and to all the contributors for their help! Cheers! :cider: