This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-10-12
Channels
- # beginners (58)
- # boot (4)
- # calva (1)
- # cider (13)
- # cljdoc (1)
- # cljs-dev (7)
- # cljsrn (14)
- # clojure (93)
- # clojure-canada (1)
- # clojure-conj (1)
- # clojure-germany (1)
- # clojure-italy (6)
- # clojure-losangeles (3)
- # clojure-nl (8)
- # clojure-spec (6)
- # clojure-uk (77)
- # clojurescript (3)
- # cursive (5)
- # data-science (6)
- # datomic (52)
- # emacs (1)
- # figwheel-main (2)
- # fulcro (6)
- # graphql (7)
- # jobs (9)
- # leiningen (1)
- # luminus (15)
- # mount (14)
- # off-topic (94)
- # pedestal (1)
- # re-frame (7)
- # reagent (10)
- # shadow-cljs (75)
- # spacemacs (4)
- # test-check (15)
- # tools-deps (23)
- # unrepl (1)
I had leiningen working to spin up a few small beginner projects but now it has stopped working. I tried lein new pedestal-service myapp
as well as lein new reagent testapp
and I keep getting the failure.
Failed to resolve version for pedestal-service:lein-template:jar:RELEASE: Could not find metadata pedestal-service:lein-template/maven-metadata.xml in local (/Users/dan/.m2/repository)
Failed to resolve version for pedestal-service:lein-template:jar:RELEASE: Could not find metadata pedestal-service:lein-template/maven-metadata.xml in local (/Users/dan/.m2/repository)
This could be due to a typo in :dependencies, file system permissions, or network issues.
If you are behind a proxy, try setting the 'http_proxy' environment variable.
Could not find template pedestal-service on the classpath.
No idea why.@dfcarpenter That almost sounds like either lein
can't reach Clojars/Maven or your local .m2
repo cache is corrupted?
Should I just delete the cache?
Worth a try.
I ran lein new pedestal-service myapp
and it worked fine, finding version 0.5.4.
You might also want to check your ~/.lein/profiles.clj
file -- the most common problems for beginners with Leiningen all seem to stem from having odd stuff in that file.
As a beginner, I can attest to that.
Though I use tools.deps now
hi people, I’d like to know what are the best training courses for clojure and datomic out there. I’m doing a research for a company about resources and devs available to work on a project running totally on datomic, clojure and clojurescript
For Datomic, only Cognitect does training for that as far as I know
thanks @U064X3EF3 I’m from Brazil and I’ll try to make it to the clojure/conj this year. I’m moving forward with a company here and datomic just match all the requirements we have for the finance problem we are trying to solve.
I haven't paid for any Clojure training before, but am aware that Cognitect and Eric Normand offer several for-pay options that you may want to examine. I don't know if anyone but Cognitect offers Datomic training.
If you are looking to limit yourself to free sources, or relatively inexpensive books (as compared to paying someone for training), there are lots of options for Clojure and some for ClojureScript. Other than the on-line public Datomic docs, I don't know of free sources there.
https://lambdaisland.com/episodes/datomic-quickstart-part-2, if not just Datomic.. I advice check these courses too: https://tbaldridge.pivotshare.com, http://learnreagent.com (cljs-shadow), and few video course e.g. on SafariBooks
I call macros from cljs. If I want to access to local variables, like at clj, is that possible? eg:
If I call from cljs part.. I got this {:protocol-inline :protocol-inline, :fn-scope :fn-scope, :locals :locals, :js-globals :js-globals, :ns :ns, :protocol-impl :protocol-impl, :column :column, :line :line, :context :context}
what I would like to get, eg from Mastering Clojure Macros (let [foo "bar" baz "quux"] (inspect-caller-locals)) {baz "quux", foo "bar"}
Hey guys, I am getting into web development in clojure and was able to run a simple server using http-kit.
The problem I'm having is when I try to use the components library I get the following error:
Exception in thread "main" java.io.FileNotFoundException: Could not locate component__init.class or component.clj on classpath., compiling:(first_web/core.clj:1:1)
I am importing the library following the instructions on github.
@sb an alternate definition
(ins)user=> (defmacro locals [] (into {} (map (juxt (partial list 'quote) identity)) (keys &env)))
#'user/locals
(cmd)user=> (let [a 0] (locals))
{a 0}
I typically use (comp keyword name)
instead of (partial list 'quote)
because having keywords as keys is useful
@arthurg.luz did you try to restart your repl after you imported the library ?
Yep, I even tried calling lein run in terminal with the main function calling the start-server
@gon Even tried creating a whole new project, only importing the components library and running the sample main through lein run. Still getting the same error
I would not expect the ns to just be component. Probably stuartsierra.component
?
(based on reading the error message)
What does the ns form look like in the file that errors?
Correction, require com.stuartsierra.component
you can do multiline code blocks by using triple backquotes
and this
preserves newlines
(use control enter to get a newline and not "submit")
It's component, not components
Yep, I just changed that, but still got the same error.
(ns weeb.core
(:require [com.stuarsierra.component :as components]))
Still gives me the classpath errorIt's still misspelled
stuarT
Ok, that was embarrassing, spent 1 hour trying to figure out two misspelling mistakes.. Thank you
I’m trying to run lein test
through http://travis.ci and it seems that it’s not finding my config edn
files. I am using the yogthos/config
library and it just seems fine at my computer. my .travis.yml
is just language:clojure \n script: lein test
how does the code get to travis? is it a git repo? a jar that gets downloaded?
the only thing I could think is if the edn files aren't in git, or some configuration that makes lein find them is only in your local config
this is the repo https://github.com/wandersoncferreira/jotun
the travis log: https://pastebin.com/PD1xrH0w
if you check the error it says actual: java.net.MalformedURLException: no protocol: getBalance
because I basically do (str (:url env) "getBalance")
, therefore the env variable must be nil
@hiredman actually, I’m building the dev
branch which had no config.edn
file at all!! because of my good’old deprecated .gitignore
having a bit of an odd issue with an uberjar. when i try to java -jar target/my-uberjar.jar
the following error gets thrown:
Exception in thread "main" java.lang.NoClassDefFoundError: ring/util/response$get_resources
i don’t use ring
directly as a dependency (trying out aleph for this), but it looks like compojure (which i am using) depends on it
when i look at the source for the compojure version i’m depending on, i don’t see any use of get-resources
anyway though
@clarkenciel how do you created the uberjar?