Bug 135156 - JavaScript loading of external XML always uses cache
Summary: JavaScript loading of external XML always uses cache
Status: CONFIRMED
Alias: None
Product: konqueror
Classification: Applications
Component: khtml ecma (show other bugs)
Version: unspecified
Platform: Debian testing Linux
: NOR normal
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-05 17:19 UTC by Olivier Trichet
Modified: 2021-03-21 00:24 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Olivier Trichet 2006-10-05 17:19:38 UTC
Version:            (using KDE KDE 3.5.4)
Installed from:    Debian testing/unstable Packages

When using e.g. "doc = document.implementation.createDocument" to
create a DOM document, then "doc.load('some-file.xml')" to load an XML
document (either locally or from the net), the result is cached
(good).  But no matter how much you reload the page, turn off caching,
clear the disk cache, etc., it refuses to load the XML document again
until the next browser session.

Evidently, it's not using the same cache as Konqueror itself, because
even if I load the XML file by typing the URL in directly (and get the
current version), it has no impact on the rendered HTML result.

I've attached a demo HTML and XML.  (Because I've used no delays to
allow the document time to load, you may need to refresh to see the
text the first time.)  Subsequent edits to the XML file have no effect
on the final rendered result, again no matter how much I try to force a
non-cached refresh.

[imported from http://bugs.debian.org/354901
demo files can be found at 
http://bugs.debian.org/cgi-bin/bugreport.cgi/test.html?bug=354901;msg=5;att=1
and http://bugs.debian.org/cgi-bin/bugreport.cgi/test.xml?bug=354901;msg=5;att=2
]
Comment 1 Maksim Orlovich 2006-10-05 18:33:10 UTC
Thanks for the forward, but for future reference: kjs is the wrong component for this, as it's for /interpreter/ bugs. Generally khtml ecma is the better choice.
Comment 2 Maksim Orlovich 2006-10-06 05:20:02 UTC
I need some information from the reporter --- in particular to elaborate on the scenario of loading from the net, since this is sensitive to the headers the server sends.
Comment 3 Adrian Irving-Beer 2007-06-09 00:09:38 UTC
Sorry for the months-long delay on this.  I apparently signed up for an account on this bug tracker but never actually followed up.  Found this when going back through my old e-mail.

The bug appears to remain in my current version of Konqueror (3.5.6).  Furthermore, it doesn't even require that I access a remote server -- I can reproduce it simply by saving the test.html and test.xml to disk and loading the test.html (refreshing to make the text appear), then editing the test.xml and seeing the (lack of any) effect.

At the time I reported this issue, I was working on a site that I could not have released at the time, hence the submitting of simple test files.  That site has since been released, and the offending page is available at http://www.nfa-arb.org/by-topic , with indexes by topic and by claim number.  XML indices are in http://www.nfa-arb.org/xml/topics and http://www.nfa-arb.org/xml/claims .

I verified the issue against the live site:

1. Access topic index with Konqueror; tree is rendered correctly.

2. Make a minor cosmetic alteration to a single node within the tree (in the XML file).

3. Refresh the topic index.  Change is not reflected.

4. Load XML index up directly in Konqueror (using the embedded kxmleditor interface) and refresh it.  XML shows current version; hence it is not a normal caching issue.

5. Repeat step 3.  Same result.

"Iceweasel" (Debian's Firefox) does not have the same problem, but it always takes a little time to load the index, so it may not be caching at all.

Note that the XML does eventually seem to expire from the cache, but on a schedule independent of Konqueror's main cache, i.e. using "refresh" or clearing the Konqueror cache does not help.

At this point, I'm not really affected by this issue any more, but I reported it due to the inconsistency it created (and the confusion it caused during development).

Let me know if you need anything else.
Comment 4 Philip Rodrigues 2008-04-20 22:04:28 UTC
Weird. I see the following:

In konq 3.5.8, the bug is as described (additionally, no text from the XML document is displayed until I manually reload the page).

In konq trunk r796129, no text from the XML is ever displayed. I verified that the loadXml function is being called, but for some reason it's not getting the text out of it

In firefox 2.0.0.12, I get exactly the same as for konq trunk
Comment 5 Justin Zobel 2021-03-21 00:24:52 UTC
Thank you for the bug report.

As this report hasn't seen any changes in 10 years or more, we ask if you can please confirm that the issue still persists.

If this bug is no longer persisting or relevant please change the status to resolved.