java.lang.Exception: Unsupported option(s) supplied: :exclude
Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
I think it is :exclusions not :exclude... example: [uk.ac.gate/gate-core 7.1 :exclusions [[org.springframework/spring-beans]]] Jim On 28/05/13 10:42, ru wrote: Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
Thank you Jim. But, I mean this piece of API doc: usefunction Usage: (use args) Like 'require, but also refers to each lib's namespace using clojure.core/refer. Use :use in the ns macro in preference to calling this directly. 'use accepts additional options in libspecs: :exclude, :only, :rename. The arguments and semantics for :exclude, :only, and :rename are the same as those documented for clojure.core/refer. Added in Clojure version 1.0 Sourcehttps://github.com/clojure/clojure/blob/c6756a8bab137128c8119add29a25b0a88509900/src/clj/clojure/core.clj#L5498 вторник, 28 мая 2013 г., 13:42:25 UTC+4 пользователь ru написал: Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
Jim, that is in project.clj right? OP can use :refer and :exclude but can't pass two namespaces to :refer, just one some examples from clojure code: (ns foo.bar (:refer-clojure :exclude [ancestors printf]) (:require (clojure.contrib sql combinatorics)) (:use (my.lib this that)) (:import (java.util Date Timer Random) (java.sql Connection Statement))) or maybe you wanted this: (ns clojure.test-clojure.data-structures (:use clojure.test [clojure.test.generative *:exclude* (is)]) (:require [clojure.test-clojure.generators :as cgen])) On Tue, May 28, 2013 at 1:02 PM, Jim jimpil1...@gmail.com wrote: I think it is :exclusions not :exclude... example: [uk.ac.gate/gate-core 7.1 :exclusions [[org.springframework/spring-beans]]] Jim On 28/05/13 10:42, ru wrote: Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out. -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
2013/5/28 ru soro...@oogis.ru Thank you Jim. But, I mean this piece of API doc: It should be (ns ru.rules (:use protege.core [rete.core :exclude [rutime]]) Unless you use Clojure 1.3, there is absolutely no reason to use :use. Use :require with :refer: (ns ru.rules (:require [protege.core :refer :all] [rete.core :refer [fn1 fn2 fn3]]) :refer :all is equivalent to :use and should be used sparingly. http://clojure-doc.org/articles/language/namespaces.html -- MK http://github.com/michaelklishin http://twitter.com/michaelklishin -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
On 28/05/13 11:10, atkaaz wrote: Jim, that is in project.clj right? aaa yes :exclusions is for project.clj! I've still not fully waken up... Jim -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
Michael, Does (:require [protege.core :refer :all]) is equivalent to (:require protege.core)? вторник, 28 мая 2013 г., 13:42:25 UTC+4 пользователь ru написал: Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
2013/5/28 ru soro...@oogis.ru Does (:require [protege.core :refer :all]) is equivalent to (:require protege.core)? No. (:require [protege.core :refer :all]) does roughly the following * Loads and compiles proteger.core * Stores it in the namespace map as proteger.core, so fn1 in it can be referred to with the ns prefix, proteger.core/fn1 * For every function in proteger.core, creates an alias in the current namespace (so they can be referred to without the ns prefix, e.g. fn1) This is exactly what :use was used for before Clojure 1.4. This approach is known as naked :use has a few issues * It makes it dead easy to override other functions in the current namespace, such as those of clojure.core, and not notice or ignore the warning * It is not obvious where does the function come from (:require protege.core) only loads the namespace but does not perform the 3rd step. If you want to spare some typing or make some code that uses a DSL look nicer, you can load a namespace with an alias (:require [protege.core :as p]) and then refer to it using the shorter prefix, e.g. p/fn1. See the clojure-doc.org guide I've linked to. -- MK http://github.com/michaelklishin http://twitter.com/michaelklishin -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
Re: java.lang.Exception: Unsupported option(s) supplied: :exclude
Thank you, Michael, for the detailed and comprehensive answer. вторник, 28 мая 2013 г., 13:42:25 UTC+4 пользователь ru написал: Dear clojure-users, Loading a file with such content: (ns ru.rules (:use protege.core rete.core :exclude [rutime]) ... I get this error message: java.lang.Exception: Unsupported option(s) supplied: :exclude at clojure.core$load_libs.doInvoke(core.clj:5408) at clojure.lang.RestFn.applyTo(RestFn.java:137) at clojure.core$apply.invoke(core.clj:621) at clojure.core$use.doInvoke(core.clj:5507) at clojure.lang.RestFn.invoke(RestFn.java:457) at ru.rules$eval8$loading__4910__auto9.invoke(rules.clj:1) at ru.rules$eval8.invoke(rules.clj:1) at clojure.lang.Compiler.eval(Compiler.java:6619) This contradict to official API documentation on Clojure v1.5. Am I right? Any help would be greatly appreciated. Sincerely, Ru -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.