Commit Graph

1724 Commits

Author SHA1 Message Date
sua yoo
7047cbeda9
feat: Copy workflow config as JSON (#2777)
Partially addresses
https://github.com/webrecorder/browsertrix/issues/2751

## Changes

- Enables copying workflow `config` to clipboard as JSON for superadmin.
- Fixes "Edit Workflow Settings" icon inconsistency.
2025-07-31 22:59:31 -07:00
Tessa Walsh
3a05002491
Add saveStorage option to workflow (#2757)
Fixes #2753 

- Adds `saveStorage` to `RawCrawlConfig` model in backend
- Adds option to Browser Settings pane of workflow editor
- Adds option to config details component
- Adds setting to docs
2025-07-31 22:58:15 -07:00
Ilya Kreymer
5a4add84a8
Nightly test fix for crawler 1.7.0 (#2789)
- Use latest crawler image for tests
- Due to webrecorder/browsertrix-crawler#861 change, a crawl with no
successful pages should be treated as failed. Update fixture to allow
both failed or complete state for backwards compatibility for now.
2025-07-31 21:58:53 -07:00
Emma Segal-Grossman
b739de419c
Fix a couple issues with btrix-badge component (#2779)
Closes #2774

## Changes

- Allows badges to expand in height when necessary
- Fixes `variant` type not including `"blue"` variant
- Fixes missing background for `"neutral"` variant
2025-07-29 18:06:28 -04:00
sua yoo
74324cdab4
build: Discard console debug in frontend production build (#2775)
Discards `console.debug` and allows `console.info` and documents in UI
development guide.
2025-07-28 23:03:24 -07:00
sua yoo
1c814cad6b
feat: Handle "scope" context in error logs (#2772)
Resolves https://github.com/webrecorder/browsertrix/issues/2771

## Changes

Handles new `scope` crawl error log context.
2025-07-28 23:02:23 -07:00
sua yoo
ed580c41e4
feat: Update storage stats with seed file and collection thumbnails (#2767)
Resolves https://github.com/webrecorder/browsertrix/issues/2733

## Changes

- Always displays storage size breakdown in dashboard panel
- Includes "Miscellaneous" storage size
- Fixes storage meter bar background color (tested with
https://www.color-blindness.com/coblis-color-blindness-simulator/)
2025-07-28 23:01:17 -07:00
Tessa Walsh
0c8c397fca
Add option to fail crawl if not logged in (#2754)
This PR adds a new checkbox to both page and seed crawl workflow types,
which will fail the crawl if behaviors detect the browser is not logged
in for supported sites.

Changes include:

- Backend support for the new crawler flag
- A new `failed_not_logged_in` crawl state
- Checkbox workflow editor and config details in the frontend (currently
in the Scope section - I think it makes sense to have this option up
front, but worth considering)
- User Guide documentation of new option
- A new nightly test for the new workflow option and
`failed_not_logged_in` state


---------
Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
Co-authored-by: sua yoo <sua@webrecorder.org>
2025-07-28 22:58:43 -07:00
samczsun
feafeae1eb
feat: allow specifying custom annotations on ingress (#2725)
This allows users who don't use the nginx ingress controller to still
configure the built in ingress
2025-07-25 16:06:57 -07:00
sua yoo
04f5ec856f
fix: Fix workflow replay after updating starting URL (#2773)
Resolves https://github.com/webrecorder/browsertrix/issues/2764

## Changes

Uses crawl first seed as starting URL instead of workflow first seed to
fix replay after saving workflow without running.

## Manual testing

1. Log in as crawler
2. Create a new workflow and crawl a single page, for example,
https://example.com/
3. Edit the workflow to change starting URL to https://example.org/
4. Save without running
5. Go to latest crawl tab, verify replay loads https://example.com/
2025-07-25 15:52:28 -07:00
DaleLore
1824fa0757
Deleted QA Run Analysis while its WIP (#2770) 2025-07-24 13:39:28 -04:00
DaleLore
4c5185d973
[Docs:] Add docs for quality assurance (#2769) 2025-07-24 13:10:49 -04:00
Tessa Walsh
993f82a49b
Add last crawl's stats object to CrawlConfigOut (#2714)
Fixes #2709 

Will allow us to display information about page counts (found, done) in
the workflow list.
2025-07-23 20:10:46 -07:00
Ilya Kreymer
89027ef16e
quickfix: delete seedfile after the workflow has been deleted (#2763)
Since seedfile deletion checks that the seedfile is not used in any
workflow, it should be deleted after the workflow is removed.
noticed in checking #2744
2025-07-23 20:10:29 -07:00
sua yoo
309977f7e5
docs: Link to MLA style title case (#2766)
## Changes

Update docs on writing documentation to include MLA style.
2025-07-23 21:09:57 -04:00
sua yoo
f8eeb0a7d3
docs: Update UI localization docs + fix broken links (#2756)
- Adds more guidelines around translatable strings
- Removes broken links to design files migrated to Storybook
2025-07-23 15:56:00 -07:00
Ilya Kreymer
dc639ac6fe version: bump to 1.18.0 2025-07-22 21:21:24 -07:00
sua yoo
7df3cb718d
feat: Duplicate workflows with seed file (#2744)
Resolves https://github.com/webrecorder/browsertrix/issues/2732

## Changes

Allows users to duplicate workflows with a seed file.
2025-07-22 21:20:12 -07:00
Ilya Kreymer
795a1a6f58
feat: Frontend upload seed url list (#2761)
Resolves #2646
Depends on #2710

## Changes

(Copied from #2689)

- Allows users to specify URL list as file.
- Allow uploading a text file of URLs
- Allow specifying >100 URLs into URL list, where they will turn into an uploaded list automatically.


---------
Co-authored-by: sua yoo <sua@suayoo.com>
2025-07-22 20:17:27 -07:00
Tessa Walsh
f7ba712646 Add seed file support to Browsertrix backend (#2710)
Fixes #2673 

Changes in this PR:

- Adds a new `file_uploads.py` module and corresponding `/files` API
prefix with methods/endpoints for uploading, GETing, and deleting seed
files (can be extended to other types of files moving forward)
- Seed files are supported via `CrawlConfig.config.seedFileId` on POST
and PATCH endpoints. This seedFileId is replaced by a presigned url when
passed to the crawler by the operator
- Seed files are read when first uploaded to calculate `firstSeed` and
`seedCount` and store them in the database, and this is copied into the
workflow and crawl documents when they are created.
- Logic is added to store `firstSeed` and `seedCount` for other
workflows as well, and a migration added to backfill data, to maintain
consistency and fix some of the pymongo aggregations that previously
assumed all workflows would have at least one `Seed` object in
`CrawlConfig.seeds`
- Seed file and thumbnail storage stats are added to org stats
- Seed file and thumbnail uploads first check that the org's storage
quota has not been exceeded and return a 400 if so
- A cron background job (run weekly each Sunday at midnight by default,
but configurable) is added to look for seed files at least x minutes old
(1440 minutes, or 1 day, by default, but configurable) that are not in
use in any workflows, and to delete them when they are found. The
backend pods will ensure this k8s batch job exists when starting up and
create it if it does not already exist. A database entry for each run of
the job is created in the operator on job completion so that it'll
appear in the `/jobs` API endpoints, but retrying of this type of
regularly scheduled background job is not supported as we don't want to
accidentally create multiple competing scheduled jobs.
- Adds a `min_seed_file_crawler_image` value to the Helm chart that is
checked before creating a crawl from a workflow if set. If a workflow
cannot be run, return the detail of the exception in
`CrawlConfigAddedResponse.errorDetail` so that we can display the reason
in the frontend
- Add SeedFile model from base UserFile (former ImageFIle), ensure all APIs
returning uploaded files return an absolute pre-signed URL (either with external origin or internal service origin)

---------
Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2025-07-22 19:11:02 -07:00
Ilya Kreymer
8107b054f6
Profiles: Make browser commit API call idempotent (#2728)
- Fix race condition related to browser commit time
- The profile commit request waits for browser to actual finish, and
profile saved. This can cause request to time out, resulting in a retry,
in which the browser has already been closed.
- With these changes, the commit is now 'idempotent' and returns a
waiting_for_browser until the profile is actually committed.
- On frontend, keep pinging commit endpoint with a timeout while 'waiting_for_browser' is returned, actual committed when endpoint returns profile id.

---------

Co-authored-by: sua yoo <sua@suayoo.com>
2025-07-22 17:59:49 -07:00
sua yoo
3043b67e49
feat: Review crawl without analysis run (#2719)
Resolves #2718

## Changes

- Enables manual QA review for successfully finished crawls.
- Individual pages and full crawl can be reviewed without assistive QA running
- Show replay, screenshot and text without comparison if no assistive QA yet.
2025-07-22 16:39:27 -07:00
Emma Segal-Grossman
fc39e1baa7
fix incorrect height of compact current page indicator (#2758) 2025-07-22 18:12:34 -04:00
sua yoo
361612251b
l18n: Manually fix translation files (#2759)
- Fixes French XLIFF file issues preventing `yarn localize:build` from
succeeded
- Fixes extraction errors preventing `yarn localize:extract` from
succeeded
2025-07-22 14:19:28 -07:00
Ilya Kreymer
d41f60d740
Translations update from Hosted Weblate (#2679) (#2750)
Translations update from [Hosted Weblate](https://hosted.weblate.org)
for

[Browsertrix/Browsertrix](https://hosted.weblate.org/projects/browsertrix/browsertrix/).



Current translation status:

![Weblate translation

status](https://hosted.weblate.org/widget/browsertrix/browsertrix/horizontal-auto.svg)

---------

Co-authored-by: Weblate (bot) <hosted@weblate.org>
Co-authored-by: Bricaud Frédéric <frederic.bricaud@banq.qc.ca>
2025-07-18 18:29:34 -07:00
Ilya Kreymer
2f9a61f6be
custom prefix additional fixes (#2746)
- follow-up to: #2736: remove '^' custom prefix URLs to avoid accumulating '^' via utility function
- Show URL prefix list in settings for custom prefix scope.
- Update user guide with correct custom prefix field.

---------

Co-authored-by: sua yoo <sua@webrecorder.org>
2025-07-18 18:21:32 -07:00
Emma Segal-Grossman
74aec5dfa3
Fix pagination buttons having no horizontal padding (#2743) 2025-07-16 21:23:07 -04:00
Ilya Kreymer
3af94ca03d
Ensure replay.json returns correct origin for pagesQueryUrl (#2741)
- Use the Host + X-Forwarded-Proto header from API request
- Fixes #2740, better fix for #2720 avoiding need for separate alias
2025-07-16 10:48:24 -07:00
Ilya Kreymer
0402f14b5e version: bump to 1.17.4 2025-07-16 10:22:10 -07:00
Emma Segal-Grossman
945c458011
Use curly quote for default archive name instead of straight quote (#2700)
Tiny little thing that's been bugging me for a little while now.
2025-07-16 11:41:19 -04:00
Tessa Walsh
d91a3bc088
Run webhook tests nightly (#2738)
Fixes #2737 

- Moves webhook-related tests to run nightly, to speed up CI runs and
avoid the periodic failures we've been getting lately.
- Also ensures all try/except blocks that have time.sleep in the 'try' also have a time.sleep in 'except'
to avoid fast-looping retries

---------

Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2025-07-15 18:05:57 -07:00
Ilya Kreymer
4e0e9c87c2
qa: run siteSpecific behaviors on QA (#2739)
- allow the page loading waiting time to be applied for sites with
site-specific behaviors (eg. social media)
2025-07-15 16:17:55 -07:00
Ilya Kreymer
5d2b34f3b6
Custom Page Prefix Usability Fixes (#2736)
- Automatically compute prefix from starting URL, if no other prefix is
set in custom prefix mode.
- Ensure each prefix is actually a prefix: add '^' to each custom prefix
URL, as include URL path is a regex
- rename 'Extra URL Prefixes' to just 'URL Prefixes' and adjust help
text to indicate that the prefix list is the list that is in scope
- fixes #2735, follow up to #2722

---------

Co-authored-by: Tessa Walsh <tessa@bitarchivist.net>
Co-authored-by: sua yoo <sua@webrecorder.org>
2025-07-15 13:19:20 -07:00
Emma Segal-Grossman
b0f2d87ce2
hotfix: workflow list - rewrite arrays in url search params to remove items (#2734)
## Changes

- Deletes and rewrites arrays in URL search params in workflow list when
editing array filters (i.e. tags & profiles)
- Removes a missed `console.log`
- bump to 1.17.3

cc @SuaYoo

---------

Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2025-07-14 14:30:18 -07:00
Emma Segal-Grossman
b3c8cc5994
Add browser profile filter to workflow list & add link to filtered list to profile detail pages (#2727) 2025-07-14 12:39:22 -04:00
Emma Segal-Grossman
f91bfda42e
Allow searching by multiple tags & profiles with "and"/"or" options for tags (#2717)
Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2025-07-11 22:35:52 -04:00
Ilya Kreymer
6f1ced0b01
chart: default to latest replayweb.page release by default (#2724)
Avoid having Browsertrix be stuck on old RWP releases, probably better
to just use latest as RWP releases now have additional testing.
2025-07-10 13:35:20 -07:00
Ilya Kreymer
23700cba2d
concurrent crawls: revert change in #2701, previous logic was already correct (#2726)
- change was unneeded (and made it worse), just add more comments
2025-07-10 13:34:56 -07:00
Emma Segal-Grossman
f36fc91963
Format page numbers in pagination component (#2723)
Closes #2704
2025-07-09 18:32:35 -07:00
Tessa Walsh
a4b30c056d
Fix custom page prefix scope (#2722)
Fixes #2721 

This PR removes frontend logic that set the seed-level scopeType for
custom page prefix workflows to `prefix`, which was causing the scope to
balloon larger than what users intended for some workflows.
2025-07-09 17:42:09 -07:00
Ilya Kreymer
841c45fe59
volumes: use emptyDir for tmp dir volume (#2713)
- don't use a persistent volume for /tmp, instead use a temporary
emptyDir
- use volume to avoid permission issues with default /tmp dir
- follow-up to #2623
2025-07-08 13:10:02 -07:00
Emma Segal-Grossman
74c72ce551
Include tag counts in tag filter & tag input autocomplete (#2711) 2025-07-08 15:20:41 -04:00
Pierre
80a225c677
docs(deployment): add note about potential firewall issues on RHEL (#2707)
Add a warning box to the troubleshooting
advice (https://docs.browsertrix.com/deploy/local/#debugging-pod-issues)
in the local deployment guide about firewall rules and disabling firewalld on RHEL.

See https://forum.webrecorder.net/t/browsertrix-deployment-stalls-when-initializing-container-migrations/916/5 for context.
2025-07-07 17:16:12 -07:00
sua yoo
7a6b1d7e73
feat: Filter workflows by tag + update existing filter UI (#2702)
Resolves https://github.com/webrecorder/browsertrix/issues/2660

## Changes

- Enables filtering workflow list by tag
- Displays tags near workflow name in detail view
- Adds `<btrix-filter-chip>` component
  - Migrates "schedule state", "only running", and "only mine" filters
  - Adds basic documentation to Storybook

---------
Co-authored-by: Emma Segal-Grossman <hi@emma.cafe>
2025-07-07 17:11:10 -07:00
sua yoo
9cfed7c6fc
fix: Superadmin active crawl count inaccuracies (#2706)
- Fixes superadmin active crawl count not showing on first log in
- Fixes `/all/crawls` endpoint running when auth is not available or not
superadmin
2025-07-07 10:13:57 -07:00
Ilya Kreymer
8152223750
concurrent crawls: filter concurrent crawls check (#2701)
ensure concurrent crawls check only counts running or waiting crawls only, not all existing crawljobs
2025-07-03 09:57:07 -07:00
Tessa Walsh
5b4fee73e6
Remove workflows from GET profile endpoint + add inUse flag instead (#2703)
Connected to #2661 

- Removes crawl workflows from being returned as part of the profile
response.
- Frontend: removes display of workflows in profile details.
- Adds 'inUse' flag to all profile responses to indicate profile is in
use by at least one workflow
- Adds 'profileid' as possible filter for workflows search in
preparation for filtering by profile id (#2708)
- Make 'profile_in_use' a proper error (returning 400) on profile
delete.

---------

Co-authored-by: Ilya Kreymer <ikreymer@gmail.com>
2025-07-02 16:44:12 -07:00
Ilya Kreymer
b915e734d1 version: bump to 1.17.2 2025-06-30 14:20:43 -07:00
sua yoo
969ea71dd3
devex: Update status indicator Storybook docs (#2668)
Updates docs for status indicator intended implementation:
- Renames "Neutral" -> "Incomplete"
- Adds "Info"
- Adds "Fatal"
2025-06-30 12:29:45 -07:00
Emma Segal-Grossman
1cfdb97d57
Allow filtering workflows to only running, & add dashboard links (#2607)
Co-authored-by: sua yoo <sua@suayoo.com>
Co-authored-by: sua yoo <sua@webrecorder.org>
2025-06-30 15:19:05 -04:00