Skip to content

XmlException on var w = new Wiki(...) #16

@MarcBra

Description

@MarcBra

Hello,

I get an exception when calling the constructor of the Wiki class on wikipedia. The code worked fine a couple of months ago and hasn't been changed since. Can you give me a hint on what's going on? Thank you very much for your great work!!

Marc

var wiki = new Wiki("...", "en.wikipedia.org");

Throws a XmlException:

"'en' is an unexpected token. The expected token is '"' or '''. Line 2, position 12."

at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.ParseAttributes()
at System.Xml.XmlTextReaderImpl.ParseElement()
at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
at System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r)
at System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r, LoadOptions o)
at System.Xml.Linq.XDocument.Load(XmlReader reader, LoadOptions options)
at System.Xml.Linq.XDocument.Parse(String text, LoadOptions options)
at LinqToWiki.Download.Downloader.Download(IEnumerable1 parameters) in c:\code\LinqToWiki\LinqToWiki.Core\Download\Downloader.cs:line 74 at LinqToWiki.Internals.QueryProcessor.Download(WikiInfo wiki, IEnumerable1 processedParameters, IEnumerable1 queryContinues) in c:\code\LinqToWiki\LinqToWiki.Core\Internals\QueryProcessor.cs:line 156 at LinqToWiki.Internals.QueryProcessor1.ExecuteSingle[TResult](QueryParameters2 parameters) in c:\code\LinqToWiki\LinqToWiki.Core\Internals\QueryProcessor.cs:line 76 at LinqToWiki.Internals.NamespaceInfo.GetNamespaces(WikiInfo wiki) in c:\code\LinqToWiki\LinqToWiki.Core\Internals\NamespaceInfo.cs:line 38 at LinqToWiki.Internals.WikiInfo..ctor(String userAgent, String baseUrl, String apiPath, IEnumerable1 namespaces) in c:\code\LinqToWiki\LinqToWiki.Core\Internals\WikiInfo.cs:line 70
at LinqToWiki.Generated.Wiki..ctor(String userAgent, String baseUri, String apiPath) in c:\Users\Svick\AppData\Local\Temp\LinqToWiki\Wiki.cs:line 32

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions