greatroar
49e32f3f8a
ui/termstatus: Optimize Truncate
...
x/text/width.LookupRune has to re-encode its argument as UTF-8,
while LookupString operates on the UTF-8 directly.
The uint casts get rid of a bounds check.
Benchmark results, with b.ResetTimer introduced first:
name old time/op new time/op delta
TruncateASCII-8 69.7ns ± 1% 55.2ns ± 1% -20.90% (p=0.000 n=20+18)
TruncateUnicode-8 350ns ± 1% 171ns ± 1% -51.05% (p=0.000 n=20+19)
2023-04-14 11:13:39 +02:00
Michael Eischer
49fa8fe6dd
Merge pull request #4175 from fergus-dall/deadlock-fix
...
Fix deadlock in Lock.Stale
2023-01-26 22:45:13 +01:00
Michael Eischer
12f167ee79
Merge pull request #4167 from aneesh-n/progress-percent-eta-fix
...
ui/backup: Fix percent and eta in backup progress
2023-01-26 22:42:10 +01:00
Michael Eischer
bb018fbc3e
Merge pull request #4163 from MichaelEischer/fix-windows-self-upgrade
...
self-upgrade: Fix handling of `--output` on windows
2023-01-26 22:40:36 +01:00
Michael Eischer
3b24e0ac55
Merge pull request #4154 from MichaelEischer/cleanup-prune-tests
...
deduplicate prune tests a bit
2023-01-26 22:39:15 +01:00
Fergus Dall
04da31af2b
Fix deadlock in Lock.Stale
...
With debug logging enabled this method would take a lock and then
format the lock as a string. Since PR #4022 landed the string
formatting method has also taken the lock, so this deadlocks.
Instead just record the lock ID, as is done elsewhere.
2023-01-27 03:21:37 +11:00
Alexander Neumann
65923e9c26
Merge pull request #4152 from MichaelEischer/invalid-locks
...
Improve handling of invalid locks
2023-01-25 08:19:53 +01:00
Michael Eischer
b903081804
Merge pull request #4169 from restic/dependabot/go_modules/github.com/klauspost/compress-1.15.15
...
build(deps): bump github.com/klauspost/compress from 1.15.14 to 1.15.15
2023-01-23 22:35:52 +01:00
Michael Eischer
beb1e872cc
Merge pull request #4170 from restic/dependabot/go_modules/cloud.google.com/go/storage-1.29.0
...
build(deps): bump cloud.google.com/go/storage from 1.28.1 to 1.29.0
2023-01-23 22:25:09 +01:00
Michael Eischer
db350c0430
Merge pull request #4171 from restic/dependabot/go_modules/google.golang.org/api-0.108.0
...
build(deps): bump google.golang.org/api from 0.107.0 to 0.108.0
2023-01-23 22:23:51 +01:00
dependabot[bot]
716a5dd20d
build(deps): bump google.golang.org/api from 0.107.0 to 0.108.0
...
Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client ) from 0.107.0 to 0.108.0.
- [Release notes](https://github.com/googleapis/google-api-go-client/releases )
- [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md )
- [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.107.0...v0.108.0 )
---
updated-dependencies:
- dependency-name: google.golang.org/api
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-23 02:23:51 +00:00
dependabot[bot]
dbd07ade98
build(deps): bump cloud.google.com/go/storage from 1.28.1 to 1.29.0
...
Bumps [cloud.google.com/go/storage](https://github.com/googleapis/google-cloud-go ) from 1.28.1 to 1.29.0.
- [Release notes](https://github.com/googleapis/google-cloud-go/releases )
- [Changelog](https://github.com/googleapis/google-cloud-go/blob/main/CHANGES.md )
- [Commits](https://github.com/googleapis/google-cloud-go/compare/storage/v1.28.1...spanner/v1.29.0 )
---
updated-dependencies:
- dependency-name: cloud.google.com/go/storage
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-23 02:23:33 +00:00
dependabot[bot]
7adf1e5d37
build(deps): bump github.com/klauspost/compress from 1.15.14 to 1.15.15
...
Bumps [github.com/klauspost/compress](https://github.com/klauspost/compress ) from 1.15.14 to 1.15.15.
- [Release notes](https://github.com/klauspost/compress/releases )
- [Changelog](https://github.com/klauspost/compress/blob/master/.goreleaser.yml )
- [Commits](https://github.com/klauspost/compress/compare/v1.15.14...v1.15.15 )
---
updated-dependencies:
- dependency-name: github.com/klauspost/compress
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-23 02:23:15 +00:00
Michael Eischer
8f94eb5420
add changelog for less strict lock handling
2023-01-22 15:54:07 +01:00
Michael Eischer
8aaba83719
add changelog for self-upgrade bug on windows
2023-01-22 15:39:42 +01:00
Michael Eischer
e16a6d4c50
self-update: add basic test for extractToFile
2023-01-22 15:39:42 +01:00
Michael Eischer
34e67e3510
self-update: Fix handling of --output
on windows
...
The code always assumed that the upgrade happens in place. Thus writing
the upgrade to a separate file fails, when trying to remove the file
stored at that location.
2023-01-22 15:39:42 +01:00
Michael Eischer
c527c05590
add changelog for missing backup ETA
2023-01-22 15:32:55 +01:00
Aneesh Nireshwalia
ed23edeb62
ui/backup: Fix percent and eta in backup progress
...
Added missing call to scanFinished=true.
This was causing the percent and eta to never get
printed for backup progress even after the scan was finished.
2023-01-21 13:25:08 -07:00
Michael Eischer
0f398b82e3
Merge pull request #4145 from greatroar/index-encode
...
index: Optimize generatePackList
2023-01-21 01:01:12 +01:00
greatroar
99755c634b
index: Optimize generatePackList
...
name old time/op new time/op delta
EncodeIndex/100-8 1.56ms ± 2% 1.48ms ± 3% -5.37% (p=0.000 n=10+10)
EncodeIndex/1000-8 14.5ms ± 2% 13.1ms ± 2% -9.49% (p=0.000 n=9+10)
EncodeIndex/10000-8 120ms ± 2% 116ms ± 2% -3.58% (p=0.000 n=10+10)
name old alloc/op new alloc/op delta
EncodeIndex/100-8 306kB ± 1% 275kB ± 1% -10.28% (p=0.000 n=10+10)
EncodeIndex/1000-8 3.69MB ±11% 2.88MB ± 5% -22.07% (p=0.000 n=10+9)
EncodeIndex/10000-8 35.9MB ±11% 31.9MB ±10% -11.13% (p=0.005 n=10+10)
name old allocs/op new allocs/op delta
EncodeIndex/100-8 3.39k ± 0% 2.39k ± 0% -29.61% (p=0.000 n=10+10)
EncodeIndex/1000-8 32.6k ± 0% 22.9k ± 0% -29.63% (p=0.000 n=10+9)
EncodeIndex/10000-8 326k ± 0% 229k ± 0% -29.71% (p=0.000 n=10+10)
The bulk of the allocation rate improvement comes from just removing the
debug.Log calls: every one of those copied a restic.ID to the heap.
2023-01-14 20:41:07 +01:00
Michael Eischer
f5f13f6648
Merge pull request #4153 from MichaelEischer/fix-quiet-prune
...
prune: Don't show "packs processed" for quiet runs
2023-01-14 20:11:34 +01:00
Michael Eischer
00216d54a1
deduplicate prune tests a bit
2023-01-14 19:05:45 +01:00
Michael Eischer
1f3f68b2c0
prune: Don't show "packs processed" for quiet runs
2023-01-14 18:48:32 +01:00
Michael Eischer
57acc769b4
lock: Ignore empty lock files
...
These may be left behind by backends which do not guarantee atomic
uploads.
2023-01-14 18:15:46 +01:00
Michael Eischer
20ad14e362
lock: add help message how to recover from invalid locks
2023-01-14 18:04:22 +01:00
Michael Eischer
c995b5be52
lock: cleanup error message
...
The error message is now `Fatal: unable to create lock in backend:
[...]` instead of `unable to create lock in backend: Fatal: [...]`.
2023-01-14 17:57:02 +01:00
Michael Eischer
1adf28a2b5
repository: properly return invalid data error in LoadUnpacked
...
The retry backend does not return the original error, if its execution
is interrupted by canceling the context. Thus, we have to manually
ensure that the invalid data error gets returned.
Additionally, use the retry backend for some of the repository tests, as
this is the configuration which will be used by restic.
2023-01-14 17:57:02 +01:00
Michael Eischer
6d9675c323
repository: cleanup error message on invalid data
...
The retry printed the filename twice:
```
Load(<lock/04804cba82>, 0, 0) returned error, retrying after 720.254544ms: load(<lock/04804cba82>): invalid data returned
```
now the warning has changed to
```
Load(<lock/04804cba82>, 0, 0) returned error, retrying after 720.254544ms: invalid data returned
```
2023-01-14 17:57:02 +01:00
Michael Eischer
551b31ce3c
Merge pull request #4146 from MichaelEischer/update-blazer
...
Update blazer to fix `b2_download_file_by_name: 404`
2023-01-14 15:23:32 +01:00
Michael Eischer
ec99507e4c
update blazer
...
This removes a stray warning, that was printed when checking the status
of non-existent files.
2023-01-14 14:56:25 +01:00
Michael Eischer
5f97f534b1
Merge pull request #4150 from restic/dependabot/go_modules/google.golang.org/api-0.107.0
...
build(deps): bump google.golang.org/api from 0.106.0 to 0.107.0
2023-01-14 14:55:15 +01:00
Michael Eischer
ed11bbd0e2
Merge pull request #4151 from restic/dependabot/go_modules/github.com/minio/minio-go/v7-7.0.47
...
build(deps): bump github.com/minio/minio-go/v7 from 7.0.46 to 7.0.47
2023-01-14 14:50:01 +01:00
dependabot[bot]
5bb9cb056d
build(deps): bump github.com/minio/minio-go/v7 from 7.0.46 to 7.0.47
...
Bumps [github.com/minio/minio-go/v7](https://github.com/minio/minio-go ) from 7.0.46 to 7.0.47.
- [Release notes](https://github.com/minio/minio-go/releases )
- [Commits](https://github.com/minio/minio-go/compare/v7.0.46...v7.0.47 )
---
updated-dependencies:
- dependency-name: github.com/minio/minio-go/v7
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-14 13:38:58 +00:00
dependabot[bot]
cd9bd22563
build(deps): bump google.golang.org/api from 0.106.0 to 0.107.0
...
Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client ) from 0.106.0 to 0.107.0.
- [Release notes](https://github.com/googleapis/google-api-go-client/releases )
- [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md )
- [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.106.0...v0.107.0 )
---
updated-dependencies:
- dependency-name: google.golang.org/api
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2023-01-14 13:38:42 +00:00
Michael Eischer
ecc826ef7d
Merge pull request #4149 from MichaelEischer/more-frequent-dependabot
...
CI: let dependabot check for updates weekly
2023-01-14 14:37:30 +01:00
Michael Eischer
fb43cbab49
Merge pull request #4129 from greatroar/cleanup
...
cache: Replace readCloser+LimitedReader by backend.LimitedReadCloser
2023-01-14 12:17:25 +01:00
Michael Eischer
41d31b1e27
Merge pull request #4116 from MichaelEischer/extract-progress-updater
...
ui/progress: Extract progress updater
2023-01-14 12:07:26 +01:00
Michael Eischer
f6ea5c5865
CI: let dependabot check for updates weekly
2023-01-14 12:02:42 +01:00
Michael Eischer
4a7a6b06af
ui/backup: Use progress.Updater for progress updates
2023-01-14 01:20:43 +01:00
Michael Eischer
e499bbe3ae
progress: extract progress updating into Updater struct
...
This allows reusing the code to create periodic progress updates.
2023-01-14 01:13:08 +01:00
Michael Eischer
52682b1c7b
Merge pull request #4111 from MichaelEischer/extract-stdio-wrapper
...
backup: extract StdioWrapper from ProgressPrinters
2023-01-14 01:12:23 +01:00
Michael Eischer
c15b4bceae
backup: extract StdioWrapper from ProgressPrinters
...
The StdioWrapper is not used at all by the ProgressPrinters. It is
called a bit earlier than previously. However, as the password prompt
directly accessed stdin/stdout this doesn't cause problems.
2023-01-14 00:58:13 +01:00
Alexander Neumann
74348be3fa
Set development version for 0.15.0
2023-01-12 20:51:23 +01:00
Alexander Neumann
37d0e1fe58
Add version for 0.15.0
2023-01-12 20:51:19 +01:00
Alexander Neumann
da196aa43e
Update manpages and auto-completion
2023-01-12 20:51:19 +01:00
Alexander Neumann
099774c2aa
Generate CHANGELOG.md for 0.15.0
2023-01-12 20:50:45 +01:00
Alexander Neumann
cd2f53e3f9
Prepare changelog for 0.15.0
2023-01-12 20:50:44 +01:00
Alexander Neumann
0c5a55d1bd
Merge pull request #4142 from restic/update-deps
...
Upgrade dependencies
2023-01-12 20:23:25 +01:00
Michael Eischer
9ddca65f6d
update dependencies
2023-01-11 23:22:10 +01:00