Skip to content

Commit c40412e

Browse files
committed
Add a dummy query parameter to the RSS feed URL to bypass the cache
1 parent 6eaf385 commit c40412e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/components/Packages/index.jsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,10 @@ const Packages = () => {
8080
};
8181
const fetchLatestData = async () => {
8282
try {
83+
// Fetch the RSS feed from conda-forge. We add a cache-busting query parameter
84+
// to ensure we always get the latest data. Otherwise, the data gets stuck in time.
8385
const response = await fetch(
84-
"https://conda.anaconda.org/conda-forge/rss.xml"
86+
`https://conda.anaconda.org/conda-forge/rss.xml?bustcache=${Date.now()}`
8587
);
8688
// parse the RSS feed into an XML document
8789
const xml = await response.text();

0 commit comments

Comments
 (0)