PkgGraph.jl icon indicating copy to clipboard operation
PkgGraph.jl copied to clipboard

graph label

Open tfiers opened this issue 3 years ago • 5 comments

.. with version of root pkg :)

(if a setting: either a function (given package name, or some info struct); or a mustache/jinja/handlebars like {{template}} string) (same as for emptymsg)

For

  • #64:

can display versioninfo() like stuff :) (cause it's important for scale of measurements)

tfiers avatar Jan 09 '23 05:01 tfiers

How-to is just, it seems:

digraph {
  label = ".."
}

tfiers avatar Jan 14 '23 13:01 tfiers

So, gathering above backlinks, what should go in graph 'label':

  • [ ] Version of root package
  • [ ] Whether from active project (manifest), or General registry
  • [ ] maybe: date generated :)
    • [ ] Also! PkgGraph.jl & its version :)
      • [ ] Ooh, in SVG, could link to repo :)
  • [ ] Whether and how many stdlib & jll packages hidden
    • No need to say "to unhide, pass ..": can say that in REPL :)
    • Btw, to give these numbers -- and to make the heuristic decision! -- we do need to crawl for them! (I.e. can't early stop in tree search in depgraph)
  • [ ] If timing: @time of total import. (And colour for how bearable that is)
    • [ ] Also: versioninfo()-like info, to give context to the timing numbers
      • maaaybe could use https://github.com/giampaolo/psutil (via Conda.jl or sth) to get current system load. but that's a bit silly (https://discourse.julialang.org/t/get-cpu-usage/24468/2)
      • Oh, actually, it is short indeed, and Sys.cpu_info() (note lowercase) works. https://discourse.julialang.org/t/get-cpu-usage/24468/7 Ok, so is feasible :)

tfiers avatar Jan 16 '23 00:01 tfiers

so yeah, this should be a html-like block, can't just be a string w/ newlines. Can a graph's label be that? Or do we need to create a floating node. Stichtend voorbeeld: https://graphviz.org/Gallery/directed/pprof.html (is geen html, gewoon text; maar kan daar perfect i'm sure) a subgraph.. Necessary? or is node in main graph ('cluster') good too

tfiers avatar Jan 16 '23 01:01 tfiers

Dependency graph for Plots v0.7.2

145 packages, of which 42 standard library and 66 JLL packages were filtered out.

Or, if not even crawling them:

Dependency graph for Plots v0.7.2

32 packages, not including standard library and JLL dependencies

(smol: )

Generated with PkgGraph.jl v0.9 on 2023-01-15

tfiers avatar Jan 16 '23 07:01 tfiers

Ofc with a flag to disable it. Sth like infobox=false

tfiers avatar Sep 05 '23 22:09 tfiers