Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7525629
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T03:36:11+00:00 2026-05-30T03:36:11+00:00

Full stack trace (ns test.xml.emit (:use clojure.core) (:require [clojure.xml :as xml])) (defn testemit []

  • 0

Full stack trace

(ns test.xml.emit
  (:use clojure.core)
  (:require [clojure.xml :as xml]))

(defn testemit []
  (xml/emit {:tag :web-app
             :attrs {:xmlns:xsi "http://www.w3.org/2001/XMLSchema-instance"
                     :xmlns "http://java.sun.com/xml/ns/javaee"
                     :xmlns:web "http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
                     :xsi:schemaLocation "http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
                     :id "Foo"
                     :version "1.0"},
             :content [{:tag :display-name "FooBar+"}
                       {:tag :listener
                        :attrs {:listener-class "com.example.server.Main"}}
                       {:tag :filter
                        :attrs {:filter-name "guiceFilter"
                                :filter-class "com.google.inject.servlet.GuiceFilter"}}
                       {:tag :filter-mappings
                        :attrs {:filter-name "guiceFilter"
                                {:url-pattern "/*"}}}]}))

In our last episode, Justin Kramer was kind enough to explain to me how clojure.xml/emit expects input to be formatted so it can produce usable xml. I’m still getting the same exception, but after I’ve looked the function over. I wonder if the xmlns:xsi, xmlns:web, and xsi:schemaLocation attributes under the web-app tag might be causing the exception because of the extra colon, but I don’t know enough to say for sure. Could someone please show me where I’m going wrong? Thank you for your time and consideration, and have a great day.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T03:36:13+00:00Added an answer on May 30, 2026 at 3:36 am

    Your error has to do with your syntax – you have several maps in your code that have an odd number of forms, maps must have an even number (each key must have a value). For example, one of your maps:

    {:tag :display-name "FooBar+"}
    

    Has 3 entries, which causes the error you’re seeing. Also note: What happened to closure.xml/emit?

    HTH,

    Kyle

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to read the full stack trace of an exception that I capture.
How can I get the full stack trace from the Exception object itself? Consider
I'm trying to write a function in clojure that prints out xml using clojure.xml/emit.
How can I get the full stack trace from the Exception object itself? Consider
Sampling with Activity Monitor/Instruments/Shark will show stack traces full of C functions for the
How can I get a full call stack for a c++ application developed with
Full disclosure, I'm new to Visual Studio Web Tests and coding for them. I've
How full-screen mode, like in web browsers, for application running under Windows OS is
I'm stumped on what's causing this. I get this error and stack trace in
main.php: require /root/test.php; print_r(apc_cache_info()); apc_bin_dump(array(/root/test.php)); test.php: $x = a; echo $x; test.php is successfully

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.