Commit Graph
2228 Commits
Author SHA1 Message Date
github-actions[bot] 7eb8246d47 publish new versions (#3673)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
shell-js-v2.4.1 updater-v2.13.2 updater-js-v2.13.2 http-js-v2.8.1 http-v2.8.1 shell-v2.4.1
2026-10-07 20:28:15 +02:00
Lucas Fernandes Nogueira 65ce65bdbb fix(ci): Android e2e flakes, shell Terminated sent before output (#3672)
* fix(ci): Android e2e flakes, shell `Terminated` sent before output

- close "isn't responding" system dialogs before each spec and hide error dialogs on the CI emulator:
  a launcher ANR dialog takes input focus from the app, and Android then denies clipboard reads
- retry switching to the webview context until it succeeds instead of running the spec in the
  native context when the first switch fails with "No such context found"
- save the focused window, a screenshot and logcat when an Android test fails
- shell: wait for the pipe readers to finish before emitting `Terminated`; the readers took their
  read lock on their own thread, so a child exiting quickly could have `close` emitted before
  its output

* Apply suggestion from @lucasfernog
2026-10-07 13:51:35 -03:00
Lucas Nogueira cbd691b651 chore(examples): update Android project for API example 2026-10-07 13:45:54 -03:00
github-actions[bot] 974bbdc3ff publish new versions (#3667)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-10-07 13:58:40 +02:00
Fabian-Lars 3113a54cc2 chore(deps): update urlpattern to 0.6 (#3670) 2026-10-07 10:05:08 +02:00
Den Ilin b443d6be52 fix(http): release the request's resources once fetch_send settles (#3669) 2026-10-07 07:37:16 +03:00
AliandLucas Nogueira 2a9c29e004 fix(updater): restore the current app when a macOS install fails (fix #3505, #3506) (#3578)
* fix(updater): restore the current app when a macOS install fails

On macOS `install_inner` moved the installed app into a `TempDir` backup and
then renamed the new bundle into place. Neither of the two steps after that
move restored the app on failure, and the `TempDir` deleted the backup on
every exit path, so a failed final rename left the user with no app at the
install path and no way back. The privileged fallback had the same shape:
`rm -rf` the app, then `mv` the new one in.

Both moves are now `replace_bundle`, which renames the current app to the
backup, renames the staged bundle into place, and renames the backup back if
that second step fails. The privileged script moves the current app aside,
moves the new one in, and restores on failure; it deletes the previous bundle
only after the new one is in place. The temp and install locations are
compared with `st_dev` before anything moves, returning the existing
`TempDirNotOnSameMountPoint` rather than failing after the app has already
been moved, and the staged bundle root is set to 0755 because `tempfile`
creates it 0700 and that mode followed it into `/Applications`.

Two unit tests cover `replace_bundle`: the staged bundle ends up in place with
the previous one in the backup, and a failed second rename leaves the current
bundle where it was and returns that error.

Closes #3505, closes #3506.

* fix(updater): exchange the current and new bundles atomically on APFS

Even with the restore in place there was a moment between the two renames
where the install path held nothing, and a process killed in that moment
left the previous app in the temp dir rather than where it belonged.

`swap_bundle` calls `renamex_np` with `RENAME_SWAP`, which exchanges the two
directories in one step so the install path always holds one of the two. The
previous app ends up in the extraction temp dir and is removed with it. Where
the file system does not support the swap (`ENOTSUP`, or `EINVAL` on older
systems) the two-rename path with the restore is used as before, and a
`PermissionDenied` from either still goes to the privileged fallback.

`libc` is added for the macOS target only; it was already in the lockfile
through tauri. One macOS test checks the exchange and skips on a file system
that reports `ENOTSUP`.

* fix(updater): keep the previous app when it cannot be restored

If the restore rename also failed, the previous app was left only in the backup TempDir and deleted with it. Keep the backup in that case and return Error::PreviousAppNotRestored with its path.

* fix(updater): quote the paths in the privileged macOS install script

The paths went into single-quoted sh words inside an AppleScript string unescaped, so a quote in the app path broke the command (run as root) or panicked on the compile expect. Quote them for sh and AppleScript, and report script failures instead of panicking.

* fix(updater): fall back to moving the bundles on any swap error

Only ENOTSUP and EINVAL got the two-rename fallback, so volumes reporting EOPNOTSUPP or ENOSYS for RENAME_SWAP failed every update. Fall back on anything but a permission error, and have the swap test skip only off APFS.

* fix(updater): stage the macOS update on the app's volume

When the system temp dir was on another volume than the app, every update was refused. Create the temp dirs next to the app in that case, and compare the install path itself rather than what a symlink there points to.

* test(updater): update a macOS app on another volume than the temp dir

Runs the app from APFS and HFS+ disk images, covering the atomic swap and the two-rename fallback with the update staged next to the app.

* fix(updater): swap the bundles atomically in the privileged macOS install

The admin path ran two mv calls, leaving the install path empty between them. Run renamex_np with RENAME_SWAP as root through osascript's JavaScript bridge, and only fall back to the moves where the swap fails.

* add test

* cleanup

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2026-10-05 09:28:11 -03:00
github-actions[bot] d4835d0e94 publish new versions (#3660)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
dialog-js-v2.8.1 barcode-scanner-js-v2.5.1 barcode-scanner-v2.5.1 notification-v2.5.1 notification-js-v2.5.1 biometric-js-v2.4.1 nfc-v2.4.1 nfc-js-v2.4.1 autostart-v2.7.0 single-instance-v2.5.2 deep-link-js-v2.6.1 biometric-v2.4.1 clipboard-manager-v2.4.1 haptics-v2.4.1 autostart-js-v2.7.0 haptics-js-v2.4.1 deep-link-v2.6.1 geolocation-v2.4.1 geolocation-js-v2.4.1 dialog-v2.8.1 clipboard-manager-js-v2.4.1
2026-09-30 19:19:08 -03:00
Lucas Nogueira 569ee82cf6 fix: mobile docs.rs builds 2026-09-30 17:56:45 -03:00
renovate[bot]andTony 25f3874656 chore(deps): update dependency eslint-plugin-security to v4.1.0 (#3661)
* chore(deps): update dependency eslint-plugin-security to v4.1.0

* fix audit

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2026-09-30 20:36:05 +08:00
Tony 2fd4bedc8b chore(autostart): update auto-launch to 0.6 (#3546)
* chore(autostart): update auto-launch to 0.6

* migrate to `set_macos_launch_mode`

* back to zzzgydi main branch

* use crates.io version of auto-launch

* Add change file

* revert unrelated bumps
2026-09-30 15:41:34 +08:00
github-actions[bot] e511284380 publish new versions (#3647)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
opener-js-v2.7.0 http-js-v2.8.0 deep-link-v2.6.0 deep-link-js-v2.6.0 opener-v2.7.0 single-instance-v2.5.1 updater-v2.13.1 updater-js-v2.13.1
2026-09-29 20:54:59 +02:00
Fabian-Lars ce59e9685e docs(log): remove unrelated single-instance comment from log readme 2026-09-29 20:49:52 +02:00
Tony 29130c2ed2 ci: run clippy on all platforms (#3650) 2026-09-29 17:08:34 +02:00
Fabian-Lars 43538190b6 chore: add changefile to re-release plugin-http npm package as 2.8.0 (#3656) 2026-09-29 10:45:04 +02:00
renovate[bot] ec14142fc6 chore(deps): update dependency @types/node to v24 (#3649)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-28 16:12:37 +08:00
renovate[bot]andTony 90b9869e61 chore(deps): update rust crate dirs to v7 (#3573)
* chore(deps): update rust crate dirs to v7

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2026-09-28 13:41:58 +08:00
renovate[bot]andTony 22e286f312 chore(deps): update rust crate infer to 0.22 (#3501)
* chore(deps): update rust crate infer to 0.22

* Add change file

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2026-09-28 11:41:45 +08:00
renovate[bot]andTony ecd3273e8e chore(deps): update windows-rs and webview2 crates (#3480)
* chore(deps): update windows-rs and webview2 crates

* Downgrade to windows-registry 0.6 and windows-result 0.4

* Add change file

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2026-09-28 11:12:19 +08:00
TonyandTobias Bieniek aa2cc64135 fix(android): Migrate Gradle scripts to compilerOptions DSL (#3478)
* fix(android): Migrate Gradle scripts to `compilerOptions` DSL

Co-authored-by: Tobias Bieniek <tobias@bieniek.cloud>

* re-run `tauri android init`

* remove change file

---------

Co-authored-by: Tobias Bieniek <tobias@bieniek.cloud>
2026-09-28 10:02:13 +08:00
Lucas Nogueira a2364a5f21 fix: integration test localhost-v2.4.0 cli-v2.5.0 process-v2.4.0 haptics-v2.4.0 notification-v2.5.0 barcode-scanner-v2.5.0 log-js-v2.10.0 window-state-v2.5.0 shell-js-v2.4.0 nfc-js-v2.4.0 single-instance-v2.5.0 store-js-v2.5.0 fs-js-v2.6.0 dialog-js-v2.8.0 positioner-js-v2.4.0 updater-js-v2.13.0 stronghold-v2.4.0 sql-js-v2.5.0 window-state-js-v2.5.0 opener-js-v2.6.0 http-js-v2.7.0 updater-v2.13.0 geolocation-v2.4.0 os-v2.4.0 http-v2.8.0 autostart-v2.6.0 cli-js-v2.5.0 websocket-v2.5.0 log-v2.10.0 deep-link-js-v2.5.0 barcode-scanner-js-v2.5.0 clipboard-manager-v2.4.0 nfc-v2.4.0 os-js-v2.4.0 notification-js-v2.5.0 stronghold-js-v2.4.0 haptics-js-v2.4.0 dialog-v2.8.0 store-v2.5.0 websocket-js-v2.5.0 sql-v2.5.0 process-js-v2.4.0 shell-v2.4.0 geolocation-js-v2.4.0 biometric-js-v2.4.0 global-shortcut-js-v2.4.0 clipboard-manager-js-v2.4.0 opener-v2.6.0 upload-js-v2.5.0 deep-link-v2.5.0 upload-v2.5.0 biometric-v2.4.0 autostart-js-v2.6.0 persisted-scope-v2.4.0 fs-v2.6.0 positioner-v2.4.0 global-shortcut-v2.4.0 2026-09-26 18:40:24 -03:00
Lucas Nogueira 67ebc1396b fix(ci): check-publish job should check .changes/pre.json 2026-09-26 17:29:03 -03:00
github-actions[bot]andLucas Nogueira cbfd428bcc Publish New Versions (v2) (#3618)
* publish new versions

* clippy

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2026-09-26 17:21:49 -03:00
Lucas Nogueira f460570b44 chore: fmt 2026-09-26 15:57:33 -03:00
Lucas Nogueira a433ec09d1 fix: mobile clippy warnings 2026-09-26 15:57:33 -03:00
Lucas Nogueira 3d8a3c877b chore: edition 2024 2026-09-26 15:36:22 -03:00
Lucas Nogueira b517cc7e85 fix: actually set rust-version to 1.90 2026-09-26 15:33:39 -03:00
Lucas Nogueira b6a38a5e32 fix(ci): e2e test error reporting 2026-09-26 15:29:52 -03:00
Lucas Nogueira 9b29b601f3 feat: update to tauri 2.12
- (MSRV bump
- Android compiler options update
- notification plugin windows7 feature deprecation
2026-09-26 14:46:48 -03:00
Lucas Fernandes Nogueira 3a01943572 tests(e2e): fix e2e failures on Linux and Windows (#3642) 2026-09-25 13:43:07 -03:00
Lucas Nogueira b870626a5e feat(ci): enforce e2e tests pass before publishing 2026-09-25 13:27:31 -03:00
Tony 1e166e93c8 ci: remove stronghold plugin from e2e tests (#3638)
* ci: remove stronghold plugin from e2e tests

* revert unrelated change
2026-09-24 21:55:25 +08:00
Lucas Fernandes Nogueira 1cae06a55b fix(fs): report read errors of readTextFileLines (#3625)
* fix(fs): report read errors of readTextFileLines

In plugins/fs/src/commands.rs read_text_file_lines_next, a read error was
mapped to "not done, empty line", so a persistent error such as EISDIR
(File::open of a directory succeeds on Unix) made the iterator yield ""
forever and the error was swallowed.

The command now closes the resource and returns the error; the JS iterator
resets its rid so a new iteration starts over. api-iife.js regenerated. E2E
spec iterates a directory and expects a rejection.

* fix(fs): close the file when a readTextFileLines loop exits early

In plugins/fs/guest-js/index.ts readTextFileLines, the async iterator did
not implement return(), so breaking out of a for await loop left the
StdLinesResource (an open file) in the webview resource table.

return() now closes the resource and resets the iterator. api-iife.js
regenerated. E2E spec breaks out of a loop, checks the resource id is no
longer valid and that iterating again starts over.
2026-09-23 13:05:04 -03:00
Lucas Fernandes Nogueira 9106093f77 fix(fs): map open options to valid Android modes (#3624)
In plugins/fs/src/lib.rs OpenOptions::android_mode, the mode was built by
concatenating r/w/t/a, so open(url, {append: true}) (read defaults to
true) produced "ra" and write+truncate+append "wta", which
ParcelFileDescriptor.parseMode / ContentResolver reject.

The options now map to r, w, wt, wa, rw or rwt. append wins over the
default read (no read+append mode exists). create/createNew still have no
Android equivalent (documented on the function). Unit tests for the
mapping, compiled on the host with cfg(test).
2026-09-23 12:58:28 -03:00
Lucas Fernandes Nogueira 97e865bc13 feat(fs): accept baseDir in size (#3623)
In plugins/fs/guest-js/index.ts, the size function only sent `path`
although the Rust command accepts `options.baseDir` and the JSDoc example
passed `{ baseDir: BaseDirectory.AppData }` (a TS error, silently dropped
at runtime, so the relative path was rejected).

Adds an optional `options?: SizeOptions` parameter (new exported type).
api-iife.js regenerated. The e2e spec now measures a file and a directory
relative to AppData instead of working around the missing option.
2026-09-23 12:58:03 -03:00
Lucas Fernandes Nogueira b46a88ff55 fix(fs): reject malformed write_file options instead of ignoring them (#3622)
In plugins/fs/src/commands.rs write_file_inner, a malformed or non-ASCII
`options` header was dropped with .ok(), so baseDir/append/createNew were
silently ignored and the call became a truncating write to the raw path;
the JSON array body fallback truncated values above 255 and dropped
non-numbers.

The header is parsed with parse_write_file_options: empty, `undefined`
(what fetch sends for JSON.stringify(undefined)) and `null` mean no
options, anything else must parse. Array bodies must only contain bytes.
Unit test for the header parser; e2e spec for writes without options,
which is the case the `undefined` handling keeps working.
2026-09-23 12:57:49 -03:00
Lucas Fernandes Nogueira 0c84c917e3 fix(fs): log file watcher errors (#3621)
In plugins/fs/src/watcher.rs, notify errors were discarded (TODO), so a
watch that died left no trace. They are now logged with log::error!.
Reporting them to the JS callback would change the event payload and is
deferred to v3.
2026-09-23 12:57:33 -03:00
Timofey Maykov 101e1b068a fix(updater): stop overriding SSL_CERT_FILE and SSL_CERT_DIR on Linux (#3615)
check() set both variables to Debian paths when they were unset. On distros
with a different layout, such as ALT Linux, the paths do not exist, and
rustls-native-certs then loads roots only from them, so every TLS client
created afterwards in the app got an empty root store.

reqwest with rustls already finds the system store through
rustls-platform-verifier and openssl-probe, so the override is not needed.

Closes #3598
2026-09-23 09:29:37 -03:00
Lucas Nogueira 55f9645aa2 chore: update websocket test 2026-09-23 06:08:43 -03:00
Lucas Nogueira 4a94356386 fix(deep-link): unregister must refresh the database 2026-09-22 22:03:02 -03:00
Lucas Nogueira 710d097b6b chore: fmt 2026-09-22 21:56:25 -03:00
Lucas Nogueira 5c78814220 fix(autostart): handle disabling when the autostart is already disabled 2026-09-22 21:56:01 -03:00
Lucas Nogueira c8c373b48b tests(e2e): improve coverage 2026-09-22 21:54:21 -03:00
Lucas Fernandes Nogueira 684feb2510 feat(tests): add api e2e tests (#3617)
* feat(tests): add api e2e tests

* lockfile

* mobile

* try linux fix [skip ci]

* ios fix

* fix test on windows

* improve cache

* fix pnpm audit [skip ci]
2026-09-22 18:58:14 -03:00
Lucas Nogueira 7f87091288 test(updater): fix e2e tests on Windows (missing bundle_type patch) 2026-09-22 18:52:27 -03:00
Lucas Fernandes Nogueira 06485c5884 test(updater): also check .deb and .rpm on e2e test (#3619)
* test(updater): also check .deb and .rpm on e2e test

* fix test on mac

* install rpm on ci

* improve update server, fix rpm crash
2026-09-22 18:51:05 -03:00
Lucas Nogueira 8882934230 fix: change file 2026-09-22 13:39:05 -03:00
Lucas Fernandes Nogueira 28d644572c test(docs): run doctest on CI, make sure doctests pass (#3620)
* test(docs): run doctest on CI, make sure doctests pass

* no_run on dialog doctests [skip ci]
2026-09-22 13:18:21 -03:00
Lucas Nogueira 413b177f81 feat(ci): improve cache usage 2026-09-22 12:42:20 -03:00
Lucas Nogueira a87a3c7d44 chore: update documentation 2026-09-22 11:30:47 -03:00