{"issue":{"pull_request":{"diff_url":null,"html_url":null,"patch_url":null},"state":"closed","user":{"avatar_url":"https://secure.gravatar.com/avatar/ca475ffbf67382be9a10915d3a3d4292?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"ca475ffbf67382be9a10915d3a3d4292","url":"https://api.github.com/users/deanhiller","login":"deanhiller","id":967189},"milestone":null,"labels":[{"name":"invalid","color":"DDDDDD","url":"https://api.github.com/repos/eed3si9n/scalaxb/labels/invalid"}],"updated_at":"2011-11-06T01:09:18Z","assignee":null,"comments":3,"closed_at":"2011-11-05T20:15:34Z","url":"https://api.github.com/repos/eed3si9n/scalaxb/issues/109","body":"This test seems to demonstrate both of the other bugs(once you fix one bug, I think it will still fail on the next bug)\r\n\r\nQUESTION: Do elements under the ghx:EventSeqRequest inherit the ghx namespace or do they automatically use the default namespace.....I always got confused by this.  Either way, the below xml should be valid correct as default namespace and ghx namespace are the same.....getting rid of the default namespace in the below test will show you the 2nd bug ;)\r\n\r\n```scala\r\n  @Test def testDefaultNamespace() {\r\n    val context = ContextParmsListType(Some(new URI(\"asdf\")), Some(new URI(\"eere\")))\r\n    val epcs :List[EPC] = Nil\r\n    val pedCheck = PedigreeCheckRequestType(context, epcs)\r\n\r\n    val xml = toXML[PedigreeCheckRequestType](pedCheck, Some(\"http://ghx.com/v1/tnt/pedigreeCheckRequest\"), Some(\"EventSequenceRequest\"), NewTntAPIFactory.defaultScope)\r\n    val stringXml = xml.toString\r\n\r\n    //val requestXml2 = XML.loadString(stringXml)\r\n    val requestXml =\r\n      <ghx:EventSequenceRequest xmlns:ghx=\"http://ghx.com/v1/tnt/pedigreeCheckRequest\"\r\n                      xmlns=\"http://ghx.com/v1/tnt/pedigreeCheckRequest\"\r\n                      xmlns:epcis=\"urn:epcglobal:epcis:xsd:1\">\r\n        <ContextParms>\r\n          <epcis:ContextBizStep>MyBizStep</epcis:ContextBizStep>\r\n          <epcis:ContextLocation>MyBizLoc</epcis:ContextLocation>\r\n        </ContextParms>\r\n      </ghx:EventSequenceRequest>\r\n\r\n\r\n    val xmlObj = fromXML[PedigreeCheckRequestType](requestXml)\r\n\r\n    val bizStepOption = xmlObj.ContextParms.ContextBizStep\r\n    Assert.assertTrue(bizStepOption.isDefined)\r\n    Assert.assertEquals(\"MyBizStep\", bizStepOption.get+\"\")\r\n\r\n    info(\"our obj=\"+xmlObj)\r\n  }\r\n```\r\n\r\nSchema...(I think you had the other schemas? or should I attach them?)\r\n\r\n```\r\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<xsd:schema xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"\r\n    targetNamespace=\"http://ghx.com/v1/tnt/pedigreeCheckRequest\"\r\n          xmlns:pcreq=\"http://ghx.com/v1/tnt/pedigreeCheckRequest\"\r\n    xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\r\n    xmlns:epcis=\"urn:epcglobal:epcis:xsd:1\"\r\n    xmlns:epcglobal=\"urn:epcglobal:xsd:1\" elementFormDefault=\"unqualified\"\r\n    attributeFormDefault=\"unqualified\" version=\"0.1\">\r\n    <xsd:import namespace=\"urn:epcglobal:epcis:xsd:1\" schemaLocation=\"./Epcglobal_1_0.xsd\"/>\r\n\r\n    <xsd:element name=\"EventSequenceRequest\" type=\"pcreq:PedigreeCheckRequestType\"/>\r\n\r\n    <xsd:complexType name=\"PedigreeCheckRequestType\">\r\n        <xsd:sequence>\r\n            <xsd:element name=\"ContextParms\" type=\"pcreq:ContextParmsListType\" minOccurs=\"1\"/>\r\n            <!-- For some reason, they don't need the epc in here as they\r\n                put it in the url, so we need to make min=0 -->\r\n            <xsd:element name=\"Id\" type=\"epcglobal:EPC\" minOccurs=\"0\" maxOccurs=\"unbounded\"/>\r\n        </xsd:sequence>\r\n    </xsd:complexType>\r\n\r\n    <xsd:element name=\"PedigreeCheckPostResponse\">\r\n        <xsd:complexType>\r\n            <xsd:sequence>\r\n                <xsd:element name=\"Response\" type=\"pcreq:PedigreePostResponseType\" minOccurs=\"1\" maxOccurs=\"unbounded\"/>\r\n            </xsd:sequence>\r\n        </xsd:complexType>\r\n    </xsd:element>\r\n    <xsd:complexType name=\"PedigreePostResponseType\">\r\n        <xsd:sequence>\r\n            <xsd:element name=\"id\" type=\"epcglobal:EPC\"/>\r\n            <xsd:element name=\"requestId\" type=\"xsd:string\"/>\r\n        </xsd:sequence>\r\n    </xsd:complexType>\r\n\r\n    <xsd:complexType name=\"ContextParmsListType\">\r\n        <xsd:annotation>\r\n            <xsd:documentation xml:lang=\"en\"> Context Parameters List </xsd:documentation>\r\n        </xsd:annotation>\r\n        <xsd:sequence>\r\n            <xsd:element name=\"ContextBizStep\" type=\"epcis:BusinessStepIDType\" minOccurs=\"0\" maxOccurs=\"1\"/>\r\n            <xsd:element name=\"ContextLocation\" type=\"epcis:BusinessLocationIDType\" minOccurs=\"0\" maxOccurs=\"1\"/>\r\n        </xsd:sequence>\r\n    </xsd:complexType>\r\n</xsd:schema>\r\n```\r\n","html_url":"https://github.com/eed3si9n/scalaxb/issues/109","title":"Qualified elements are not recognized as local elements of an \"unqualified\" schema","number":109,"id":2148521,"created_at":"2011-11-04T21:15:55Z"},"action":"created","comment":{"user":{"avatar_url":"https://secure.gravatar.com/avatar/ca475ffbf67382be9a10915d3a3d4292?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"ca475ffbf67382be9a10915d3a3d4292","url":"https://api.github.com/users/deanhiller","login":"deanhiller","id":967189},"updated_at":"2011-11-06T01:09:18Z","url":"https://api.github.com/repos/eed3si9n/scalaxb/issues/comments/2643354","body":"uhm, doesn't that xml mean ContextBizStep is part of the ghx namespace?  In our xsd, ContextBizLocation is part of the epcis namespace(urn:epcglobal:epcis:xsd:1).  From looking at the xml you posted ContextBizStep is either part of ghx OR is part of the default namespace which is not set in your xml so any tool would not know it is part of the epcis namespace, right????  or am I missing something.....THANKS FOR ALL THE FIXES so fast by the way.","id":2643354,"created_at":"2011-11-06T01:09:18Z"}}