actsasgeek / lein-gossip Goto Github PK
View Code? Open in Web Editor NEWA tool to examine Clojure source code and generate call-graphs.
A tool to examine Clojure source code and generate call-graphs.
Attempted to run using Lein 1.7.1:
lein gossip src/clojure
Resulted in:
Caused by: java.lang.RuntimeException: java.lang.RuntimeException: java.lang.RuntimeException: java.lang.IllegalArgumentException: Don't know how to create ISeq from: clojure.lang.Symbol
at clojure.lang.LazySeq.sval(LazySeq.java:47)
at clojure.lang.LazySeq.seq(LazySeq.java:56)
at clojure.lang.RT.seq(RT.java:450)
at clojure.core$seq.invoke(core.clj:122)
at clojure.core$r.invoke(core.clj:793)
at clojure.core$into.invoke(core.clj:2614)
at leiningen.gossip.callgraphing$create_used_namespace_lookup.invoke(callgraphing.clj:79)
at leiningen.gossip.callgraphing$select_defs_and_calls.invoke(callgraphing.clj:113)
at leiningen.gossip.callgraphing$clj_to_dot.invoke(callgraphing.clj:186)
at leiningen.gossip.callgraphing$generate_dot_files_from_clj_files.invoke(callgraphing.clj:212)
Namespace-qualified ::keywords require being in the runtime
environment in which such namespaces exist.
For example, you can do this experiment:
failure case
$ lein repl
(read-string "::bootstrap/routes")
;; => RuntimeException Invalid token: ::bootstrap/routes clojure.lang.Util.runtimeException (Util.java:219)
success case
$ git clone https://github.com/cldwalker/mindmup-pedestal.git # random clojure project
$ cd mindmup-pedestal
$ lein repl
(read-string "::bootstrap/routes")
:io.pedestal.service.http/routes ; success
But lein-gossip fails:
$ lein gossip
/home/vagrant/src/mindmup-pedestal/dev/user.clj
/home/vagrant/src/mindmup-pedestal/dev/dev.clj
[reader error] Invalid token: ::bootstrap/join?
[reader error] Invalid token: ::bootstrap/routes
[reader error] Invalid token: ::bootstrap/allowed-origins
...
So the way to solve these reader errors is that the namespace in question has
to exist in the environment before reading the form. That may or may
not be something you want to do, but the pull request I have open
(Issue #2) at least makes it less of a problem because it just prints
out which forms failed to read and proceeds to read the other forms.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.