Skip to content

Update Selenium Manager doc about prunning cache#2673

Open
bonigarcia wants to merge 1 commit into
trunkfrom
sm_doc_prune_cache
Open

Update Selenium Manager doc about prunning cache#2673
bonigarcia wants to merge 1 commit into
trunkfrom
sm_doc_prune_cache

Conversation

@bonigarcia

Copy link
Copy Markdown
Member

Description

This PR updated the SM to explain that now cache is pruned automatically.

Motivation and Context

Doc update due to a recent change in Selenium Manager:

SeleniumHQ/selenium#17585

Types of changes

  • Change to the site (I have double-checked the Netlify deployment, and my changes look good)
  • Code example added (and I also added the example to all translated languages)
  • Improved translation
  • Added new translation (and I also added a notice to each document missing translation)

Checklist

  • I have read the contributing document.
  • I have used hugo to render the site/docs locally and I am sure it works.

@qodo-code-review

Copy link
Copy Markdown
Contributor

PR Summary by Qodo

Document Selenium Manager automatic cache pruning behavior

📝 Documentation 🕐 10-20 Minutes

Grey Divider

AI Description

• Document Selenium Manager’s automatic cache pruning to avoid manual cache management.
• Explain last_used tracking in se-metadata.json and the 30-day eviction policy.
• Apply the update across EN, JA, PT-BR, and ZH-CN Selenium Manager docs.
Diagram

graph TD
  U["Doc reader"] --> D["Selenium Manager docs"] --> SM["Selenium Manager"] --> R["Resolve driver/browser"] --> M["Update last_used in se-metadata.json"] --> P["Prune cache entries (>30d)"] --> C["Cache version dirs"]
Loading
High-Level Assessment

The approach is appropriate: directly document the new Selenium Manager behavior (automatic cache pruning) where caching is explained, and mirror it across localized docs to keep user guidance consistent.

Files changed (4) +9 / -1

Documentation (4) +9 / -1
selenium_manager.en.mdAdd documentation for automatic cache pruning and 'last_used' tracking +2/-0

Add documentation for automatic cache pruning and 'last_used' tracking

• Adds a new paragraph explaining that Selenium Manager automatically prunes old cache entries. Documents updating 'cached_assets.last_used' in 'se-metadata.json' on cache usage and removing cache directories unused for over 30 days.

website_and_docs/content/documentation/selenium_manager.en.md

selenium_manager.ja.mdMirror cache-pruning documentation in JA Selenium Manager page +2/-0

Mirror cache-pruning documentation in JA Selenium Manager page

• Adds the same cache-pruning explanation as the English page: 'last_used' updates in 'se-metadata.json' and eviction of entries unused for 30+ days.

website_and_docs/content/documentation/selenium_manager.ja.md

selenium_manager.pt-br.mdMirror cache-pruning documentation in PT-BR Selenium Manager page +2/-0

Mirror cache-pruning documentation in PT-BR Selenium Manager page

• Adds the same cache-pruning explanation as the English page: 'last_used' updates in 'se-metadata.json' and eviction of entries unused for 30+ days.

website_and_docs/content/documentation/selenium_manager.pt-br.md

selenium_manager.zh-cn.mdAdd Chinese description of automatic cache pruning behavior +3/-1

Add Chinese description of automatic cache pruning behavior

• Adds a Chinese paragraph describing Selenium Manager’s automatic cache pruning. Also adjusts minor punctuation/formatting around the TTL example before introducing the new content.

website_and_docs/content/documentation/selenium_manager.zh-cn.md

@netlify

netlify Bot commented Jun 30, 2026

Copy link
Copy Markdown

Deploy Preview for selenium-dev ready!

Name Link
🔨 Latest commit 83d6224
🔍 Latest deploy log https://app.netlify.com/projects/selenium-dev/deploys/6a438ebdbb8a0d00076a9c4e
😎 Deploy Preview https://deploy-preview-2673--selenium-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@qodo-code-review

Copy link
Copy Markdown
Contributor

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (0) 📜 Skill insights (0)

Grey Divider


Informational

1. Metadata description inconsistent 🐞 Bug ⚙ Maintainability
Description
The new cache-pruning paragraph says se-metadata.json has a cached_assets section with
last_used timestamps, but earlier in the same section the metadata file is described only as
containing discovered versions and TTL. This inconsistency makes it unclear to readers what
se-metadata.json now contains and why it changes.
Code

website_and_docs/content/documentation/selenium_manager.en.md[169]

+To bound the cache size without requiring manual intervention, Selenium Manager automatically prunes old cache entries. Every time a driver or browser is resolved from the cache, a `last_used` Unix timestamp is updated in a dedicated `cached_assets` section within the metadata file (`se-metadata.json`). On each execution, Selenium Manager automatically removes driver or browser version directories from the cache that have not been used in over 30 days.
Evidence
In each file, the bullet defining se-metadata.json mentions only discovered versions and TTL,
while the newly added paragraph states the same file also contains a cached_assets section with
last_used timestamps for pruning—creating an internal inconsistency within the caching section.

website_and_docs/content/documentation/selenium_manager.en.md[158-170]
website_and_docs/content/documentation/selenium_manager.ja.md[158-170]
website_and_docs/content/documentation/selenium_manager.pt-br.md[158-170]
website_and_docs/content/documentation/selenium_manager.zh-cn.md[235-263]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The caching section introduces new metadata content (`cached_assets` + `last_used`) used for pruning, but the earlier bullet that defines `se-metadata.json` doesn’t mention this new structure. Update the metadata-file bullet so it accurately reflects both TTL/version discovery data and the cache-pruning bookkeeping.

## Issue Context
This PR adds pruning documentation in multiple language copies, so the earlier `se-metadata.json` description should be updated in each touched file to avoid internal doc inconsistency.

## Fix Focus Areas
- website_and_docs/content/documentation/selenium_manager.en.md[158-170]
- website_and_docs/content/documentation/selenium_manager.ja.md[158-170]
- website_and_docs/content/documentation/selenium_manager.pt-br.md[158-170]
- website_and_docs/content/documentation/selenium_manager.zh-cn.md[235-263]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

Qodo Logo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant