summaryrefslogtreecommitdiff
path: root/crates/tor-persist
Commit message (Collapse)AuthorAgeFilesLines
* Bump versions for tor- and arti- crates to 0.21.0Nick Mathewson2024-08-011-4/+4
| | | | | | | | | | This is the result of: ``` for crate in $( ./maint/list_crates |grep '^\(tor\|arti-\)' ); do cargo set-version -p $crate 0.21.0 done ```
* Run "fixup-features".Nick Mathewson2024-08-011-1/+1
|
* implement TorClient::wait_for_stoptrinity-1686a2024-07-112-0/+23
|
* tor-persist: Deprecate ErrorSource::Permissions, use InaccessibleIan Jackson2024-07-101-1/+9
|
* tor-persist: Correct message and description for mistrust errorIan Jackson2024-07-101-2/+4
|
* Merge branch 'deftly' into 'main'Ian Jackson2024-07-081-2/+2
|\ | | | | | | | | Update to derive-deftly 0.14 See merge request tpo/core/arti!2241
| * Update to derive-deftly 0.14Ian Jackson2024-07-081-2/+2
| | | | | | | | | | This removes the deprecated syntaxes. Updating now will prevent us re-introducing the old syntaxes, which we updated in arti!2209.
* | Fix clippy::doc_lazy_continuationIan Jackson2024-07-081-9/+9
|/
* Update versions of 0.x tor-* and arti-* cratesIan Jackson2024-06-271-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | nailing-cargo -uE set-version -p arti-client 0.20.0 nailing-cargo -uE set-version -p arti-relay 0.20.0 nailing-cargo -uE set-version -p arti-rpcserver 0.20.0 nailing-cargo -uE set-version -p tor-async-utils 0.20.0 nailing-cargo -uE set-version -p tor-basic-utils 0.20.0 nailing-cargo -uE set-version -p tor-bytes 0.20.0 nailing-cargo -uE set-version -p tor-cell 0.20.0 nailing-cargo -uE set-version -p tor-cert 0.20.0 nailing-cargo -uE set-version -p tor-chanmgr 0.20.0 nailing-cargo -uE set-version -p tor-checkable 0.20.0 nailing-cargo -uE set-version -p tor-circmgr 0.20.0 nailing-cargo -uE set-version -p tor-config 0.20.0 nailing-cargo -uE set-version -p tor-consdiff 0.20.0 nailing-cargo -uE set-version -p tor-dirclient 0.20.0 nailing-cargo -uE set-version -p tor-dirmgr 0.20.0 nailing-cargo -uE set-version -p tor-error 0.20.0 nailing-cargo -uE set-version -p tor-geoip 0.20.0 nailing-cargo -uE set-version -p tor-guardmgr 0.20.0 nailing-cargo -uE set-version -p tor-hsclient 0.20.0 nailing-cargo -uE set-version -p tor-hscrypto 0.20.0 nailing-cargo -uE set-version -p tor-hsrproxy 0.20.0 nailing-cargo -uE set-version -p tor-hsservice 0.20.0 nailing-cargo -uE set-version -p tor-keymgr 0.20.0 nailing-cargo -uE set-version -p tor-linkspec 0.20.0 nailing-cargo -uE set-version -p tor-llcrypto 0.20.0 nailing-cargo -uE set-version -p tor-log-ratelim 0.20.0 nailing-cargo -uE set-version -p tor-memquota 0.20.0 nailing-cargo -uE set-version -p tor-netdir 0.20.0 nailing-cargo -uE set-version -p tor-netdoc 0.20.0 nailing-cargo -uE set-version -p tor-persist 0.20.0 nailing-cargo -uE set-version -p tor-proto 0.20.0 nailing-cargo -uE set-version -p tor-protover 0.20.0 nailing-cargo -uE set-version -p tor-ptmgr 0.20.0 nailing-cargo -uE set-version -p tor-relay-selection 0.20.0 nailing-cargo -uE set-version -p tor-rpcbase 0.20.0 nailing-cargo -uE set-version -p tor-rtcompat 0.20.0 nailing-cargo -uE set-version -p tor-rtmock 0.20.0 nailing-cargo -uE set-version -p tor-socksproto 0.20.0 nailing-cargo -uE set-version -p tor-units 0.20.0 Each of which runs a rune like cargo set-version --offline -p tor-units 0.20.0
* Update to itertools 0.13.0Ian Jackson2024-06-251-2/+2
| | | | | | | No code changes needed. Precisely nailing-cargo -Eu upgrade --incompatible -p itertools
* Update to derive-deftly 0.13.0Ian Jackson2024-06-251-2/+2
| | | | | | | No code changes needed. Precisely nailing-cargo -Eu upgrade --incompatible -p derive-deftly
* Change deftly syntax to post 0.12.1 versionIan Jackson2024-06-171-1/+1
| | | | | | | | | | | * Change `pub` to `export` * Change the `=` in define to `:` * Change `pub_template_semver_check` to `template_export_semver_check` Right now, 0.12.1 supports both syntaxes. I have verified this branch also compiles with https://gitlab.torproject.org/Diziet/rust-derive-deftly/-/merge_requests/402 ee171ffaf56d7dcb7d75584054921153fe19b222
* Update to derive-deftly 0.12.1Ian Jackson2024-06-172-3/+4
| | | | | | * Bump in Cargo.toml * Deal with `${Xmeta as ...}` incompatible change, by always specifying an `as`, and changing `as tokens`.
* Bump all the unstable tor- and arti- crates to 0.19.Gabriela Moldovan2024-06-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The unstable crates are: - tor-error - tor-config - tor-units - tor-geoip - tor-rtcompat - tor-rtmock - tor-log-ratelim - tor-rpcbase - tor-memquota - tor-llcrypto - tor-protover - tor-bytes - tor-hscrypto - tor-socksproto - tor-checkable - tor-cert - tor-linkspec - tor-cell - tor-proto - tor-netdoc - tor-consdiff - tor-netdir - tor-relay-selection - tor-persist - tor-chanmgr - tor-ptmgr - tor-guardmgr - tor-circmgr - tor-dirclient - tor-dirmgr - tor-keymgr - tor-hsclient - tor-hsservice - tor-hsrproxy - arti-client - arti-rpcserver - arti-hyper - tor-basic-utils - tor-async-utils Done using ``` for p in "${unstable[@]}"; do cargo set-version -p $p 0.19; done ``` where `unstable` contains the list above
* Suppress a false positive for a new lint on Rust BetaIan Jackson2024-05-131-0/+1
|
* Re-run maint/add_warning.Nick Mathewson2024-05-061-2/+2
| | | | This commit is automatically generated.
* Bump versions of 0.x tor-* and arti-* cratesIan Jackson2024-04-301-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for p in `cat ../u`; do cargo set-version --locked --offline -p $p; done where u contains tor-basic-utils tor-async-utils tor-error tor-config tor-units tor-geoip tor-rtcompat tor-rtmock tor-log-ratelim tor-rpcbase tor-memquota tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-hyper
* Upgrade derive-deftly requirement to 0.10.3Nick Mathewson2024-04-111-2/+2
| | | | We're taking this for the fix to derive-deftly#52.
* Switch to derive-deftlyIan Jackson2024-04-032-19/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the combination of a number of separate commits, many of which were generated by seddery, and then rebased and squashed. Cargo.toml perl -i~ -pe 's{^derive-adhoc}{derive-deftly = "0.10"}' crates/*/Cargo.toml (not regenerated during rebase) update Cargo.lock `cargo fetch` without --locked (regenerated during rebase) seddery git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{^use derive_adhoc}{use derive_deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bdefine_derive_adhoc\b}{define_derive_deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bAdhoc\b}{Deftly}g if m{derive}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\#\[derive_adhoc\b}{#[derive_deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{use derive_adhoc}{use derive_deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc\b}{derive_deftly_adhoc} if m{use.*deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc!}{derive_deftly_adhoc!}' (not regenerated during rebase) Manually add `#[derive_deftly_adhoc]` where needed. seddery git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\#\[adhoc\b}{#[deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc_template}{derive_deftly_template}' (not regenerated during rebase) Manually fix up an import Manually update some builder attrs Manually fix up tor_rtmock::time_core This was missed in my seddery, due to me rebasing the branch and not redoing the seddery.
* Update unstable `tor/arti-*` crates to 0.17.0.Nick Mathewson2024-04-021-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Done with: ``` CRATES=" tor-basic-utils tor-async-utils tor-error tor-config tor-events tor-units tor-geoip tor-rtcompat tor-rtmock tor-log-ratelim tor-rpcbase tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-hspow tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-congestion tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-bench arti-testing " for crate in $CRATES; do cargo set-version -p "$crate" 0.17.0 done ```
* Bump patchlevel versions on non-{tor/arti} crates.Nick Mathewson2024-04-021-3/+3
| | | | | | | | | | | | | | | | These have all had backward-compatible changes. Generated with: ``` cargo set-version --bump patch -p fs-mistrust cargo set-version --bump patch -p test-temp-dir cargo set-version --bump patch -p fslock-guard cargo set-version --bump patch -p hashx cargo set-version --bump patch -p equix cargo set-version --bump patch -p caret cargo set-version --bump patch -p safelog cargo set-version --bump patch -p retry-error ```
* Run "fixup-features" in preparation for next release.Nick Mathewson2024-03-281-1/+1
|
* Run maint/add_warning.Nick Mathewson2024-03-136-0/+6
|
* Use tor_basic_utils::PathExt::display_lossyIan Jackson2024-03-054-6/+10
| | | | | Change Path::display to this new function, in call sites where it's being used for a diagnostic.
* Merge branch 'deny-unchecked-duration-substraction' into 'main'Ian Jackson2024-03-051-0/+1
|\ | | | | | | | | | | | | deny clippy::unchecked_duration_subtraction Closes #1304 See merge request tpo/core/arti!2008
| * deny clippy::unchecked_duration_subtractiontrinity-1686a2024-02-291-0/+1
| |
* | Bump patchlevel of crates with functional changes.Gabriela Moldovan2024-03-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Functional changes were made, but no APIs were added or broken: ``` tor-events (async_broadcast 0.6.0 -> 0.7.0) tor-netdoc (signature 1 -> 2) tor-guardmgr arti-testing (config 0.13.4 -> 0.14.0) tor-persist (breaking changes gated behind experimental feature) fslock-guard (fix lockfile_has_path compilation on Windows) ``` Done with: ``` cargo set-version --bump patch -p tor-events cargo set-version --bump patch -p tor-netdoc cargo set-version --bump patch -p tor-guardmgr cargo set-version --bump patch -p arti-testing cargo set-version --bump patch -p tor-persist cargo set-version --bump patch -p fslock-guard ```
* | tor-persist: Improve test portabilityTobias Stoeckmann2024-03-011-3/+5
|/ | | | | | | | | The test fails on Windows systems for two reasons: - File separator \ is printed in error message instead of expected / - Temporary files are located within home directory, which is anonymized Test failure can be provoked on Linux as well by setting TMPDIR to point to a directory within HOME.
* tor-persist: state_dir: Use DOT_LOCK in the final locationIan Jackson2024-02-081-1/+1
| | | | | Actually, we want to test handling of the string with whatever the extension would be, if it changed.
* tor-persist: state_dir: Introduce DOT_LOCKIan Jackson2024-02-081-2/+7
| | | | | | | And replace ".lock" with it. Now the only place that the "lock" extension this is still present as a literal is in a test.
* tor-persist: state_dir: Introduce LOCK_EXTNIan Jackson2024-02-081-4/+6
| | | | | | And replace "lock" with it. This is the first half of not open-coding this; the sites where the literal string is ".lock" are in the next commit, to help avoid the slip of using the wrong constant.
* tor-persist: state_dir: Add a note about the instance modification timeIan Jackson2024-02-081-0/+3
|
* tor-persist: state_dir: Test that junk is ignoredIan Jackson2024-02-081-0/+27
|
* tor-persist: state_dir: Fix typoNick Mathewson2024-02-081-1/+1
|
* tor-persist: state_dir: Improve an error messageNick Mathewson2024-02-081-1/+1
|
* tor-persist: state_dir: Add a clippy allowIan Jackson2024-02-081-0/+1
|
* tor-persist: state_dir: Drop unused void dependencyIan Jackson2024-02-081-2/+1
|
* tor-persist: state_dir: (Re)move unused imports and allow (fmt)Ian Jackson2024-02-081-1/+1
|
* tor-persist: state_dir: (Re)move unused imports and allowIan Jackson2024-02-081-15/+10
|
* tor-persist: state_dir terminology: Use "INSTANCE_ID" in docsIan Jackson2024-02-081-5/+5
| | | | | | Now ee consistently use "instance id" or "instance identity" (or, where unambiguous, "id"), to mean the identity of an instance within a kind, and "instance" to refer to the whole thing including the kind.
* tor-persist: state_dir tests: Test mtime resetIan Jackson2024-02-081-1/+184
|
* tor-persist: state_dir tests: Test iteration and purgeIan Jackson2024-02-082-0/+257
|
* tor-persist: state_dir tests: Break out mk_state_dirIan Jackson2024-02-081-5/+9
| | | | We're going to get more call sites.
* tor-persist: state_dir terminology: Use "key", not "slug" (fmt)Ian Jackson2024-02-081-9/+4
|
* tor-persist: state_dir terminology: Use "key", not "slug"Ian Jackson2024-02-081-29/+30
| | | | | | | | Slug is the general type. Instance kinds are slugs too. We need a word for the slug-within-an-instance which identifies a storage location for StorageHandle, or a raw subdirectory. Let's use "key". Change the terminology (and variable names) everywhere.
* tor-persist: state_dir: expiry: Implement purge_instancesIan Jackson2024-02-081-2/+133
|
* tor-persist: state_dir: expiry: Ensure that instance dir mtime is updatedIan Jackson2024-02-082-3/+19
| | | | | | Add comments where it's done automatically. (There will be tests of the claims I'm making, in a later commit.)
* tor-persist: state_dir: purge API: Clarify callback edge casesIan Jackson2024-02-081-1/+26
|
* tor-persist: state_dir: purge API: Add notes about instance mtimeIan Jackson2024-02-081-0/+9
|
* tor-persist: state_dir: purge API: Discuss deletion non-atomicityIan Jackson2024-02-081-0/+31
|