Граф коммитов

156 Коммитов

Автор SHA1 Сообщение Дата
Mark Hammond f538529f15 Update a number of crate package versions.
This was largely done manually to try and bring app-services and
mozilla-central closer together. With this patch we can vendor
into mozilla-central, including when most of our mobile crates are
built into libxul in the Android monorepo, oak.

This patch also re-forks find-places-db to avoid using a now orhpaned
crate which no mozilla staff had access to update.
2024-02-06 15:43:45 +00:00
Mark Hammond 79d24ff85a Use uniffi as a workspace dependency 2023-12-15 18:32:25 +00:00
Mark Hammond 0c2109c89d Move rusqlite/libslite3-sys to workspace dependencies 2023-12-13 15:53:26 +00:00
Tarik Eshaq f034b2c654 Removes outdated application-services@mozilla.com email
Replaces the email with more granular ownership emails, the sync team
crates are owned by <sync-team@mozilla.com> and the nimbus creates are
owned by <project-nimbus@mozilla.com>
2023-12-04 18:05:57 +00:00
Ben Dean-Kawamura 54ec6e1f4b Upgarding UniFFI to `0.25.2`
Mostly mechanical, the one extra step was to add the `serde::derive`
feature to `remote_settings`.  I guess it's not pulling that feature in
from `uniffi` anymore.

oneshot is a new dependency for UniFFI.  It specifies its license in
Cargo.toml but doesn't include the file, so I linked to the official
Apache 2.0 license text.
2023-12-01 13:37:08 +00:00
Ben Dean-Kawamura 14fae5c7f0 Upgrading to UniFFI 0.24 and Glean to 53.1.0 2023-07-05 20:48:54 +00:00
Mark Hammond 560b8502e7 Add tests which verifies some places behavior.
When deleting a bookmark that has no visits, that origin will remain in
moz_origins until a complete history wipe is done. This is the same
behaviour as desktop, sadly considered a bug, and described in
bug 1650511.
2023-06-27 18:40:40 +00:00
Tarik Eshaq ffb06acd44 Updates rusqlite to 0.29.0 and libsqlite to 0.26.0 2023-06-13 01:11:26 +00:00
Ben Dean-Kawamura 6ecde0b247 Don't use workspace dependencies for UniFFI.
This was really nice, but it breaks when we get vendored in to
moz-central.  So we have to go back to the dark ages.
2023-01-30 12:26:58 -05:00
Ben Dean-Kawamura a79f23574f Updating UniFFI to version 0.23
- Switched to using workspace dependencies, this will make future
  updates much simpler
- Updated code to work with the new UniFFI crate structure
- Updated the error-support integration tests to work with the workspace
  dependencies, following this advice: https://stackoverflow.com/a/71461114.
2023-01-27 12:38:55 -05:00
Mark Hammond ba67a665dd
Update rusqlite to 0.28.0 (#5282) 2022-12-08 15:01:25 +11:00
Mark Hammond 61952065d1
Remove the not-quite-functional test-utils feature from sync15 (#5275)
When doing #5139 I tried to have a test-utils feature for sync15,
which didn't really work out for various reasons but it was left in.

Currently `cargo test -p sync15 --features=sync-client` fails, although
CI doesn't every run that (it runs with default and all features)

This PR kills that feature entirely.
2022-12-06 10:42:52 +11:00
Mark Hammond eb804faf80
Update sync15 BSO concept to use envelopes and kill sync15::Payload. (#5139)
Reworks how BSOs work in all syncable components.

This adopts some of the BridgedEngine model - specifically, there's now
an IncomingBso and OutgoingBso, each with a corresponding IncomingEnvelope
and OutgoingEnvelope. There's also a new formalized "content" mechanism
for serializing and deserializing payloads to and from some T, with a
sane and consistent procedure for handling tomebstones and malformed
records.

BridgedEngine and SyncEngine now work using these new types, getting us
closer to fully integrating these engines into a single trait.

This kills sync15::Payload entirely in favor of the new system.
2022-12-02 11:31:06 +11:00
Ben Dean-Kawamura f50d60cbb3 Replaced `log::error!` calls with `error_support::report_error!`
Went through all the main app-services components and replaced the
old-style `log::error!` calls with `error_support::report_error!`.

Removed the `reporting` feature of `error-support` and made it
always-enabled.

Renamed the `report_error` function so that it's name doesn't clash with
the `report_error` macro
2022-10-27 18:37:46 -04:00
Ben Dean-Kawamura 7155bbb4a9 Updating UniFFI to 0.21.0 2022-10-19 11:37:03 -04:00
Mark Hammond d8503475f4
Merge sync15-traits back into sync15 via features. (#5125) 2022-09-15 11:09:04 +10:00
Ben Dean-Kawamura b82517cde3 Updating Rust versions to 1.61/1.63
This matches the nightly versions for FF desktop.
2022-09-13 19:13:44 -04:00
Tarik Eshaq ad9dd96c60
Adds error-support to the iOS megazords (#5094)
* Adds error-support to the iOS megazords

* Updates UniFFI to 0.19

* Adds changelog

* fixup dependency summaries

* Fixup changelog
2022-08-29 13:01:30 -07:00
Mark Hammond e7537c93a4
Put the new error-reporting capability behind a feature (#4987) 2022-06-07 09:25:17 +10:00
Tarik Eshaq a6af58fac6
Bumps uniffi to 0.18 [ci full] (#4949)
* Bumps uniffi to 0.18

* Fixes dependency summaries

* Fixes uniffi duplicate type definitions

* Adds changelog

* Renames Timestamp to PlacesTimestamp

* Adds focus dependency changes from rebase

* Fix typo in dependency summaries comment
2022-05-16 10:26:20 -07:00
Tarik Eshaq f7c5588b1e
Update rand and parking lot (#4937)
* Update rand and parking_lot.

I need this to update other Gecko dependencies.

* Update dependency_summary to account for various windows-rs crates.

I'm not sure why it wasn't failing to find the relevant licenses before,
it was likely a pre-existing issue.

* Update dependency summaries.

* Runs dependency summaries on a mac

Co-authored-by: Emilio Cobos Álvarez <emilio@crisal.io>
2022-05-02 17:18:12 -07:00
Thom Chiovoloni 8f47b4e116
Remove `log_query_plans` feature from `sql-support`.
The query plan format is unstable, and new versions of SQLite, including
the version now used by Firefox, is different and incompatible. When I
wrote the support for it initially, I ported it by hand it from the
visualization used in the `sqlite3` command line shell.

In practice, it helped a little. I'd be unsurprised if nobody's used it
since -- it was not really very convenient to work with. The main reason
I added it was because I didn't know how to access the functionality
from the SQLite command line shell, because of how many custom functions
we use in our queries.

Since then, I've learned that if you SQLite was built with
[`-DSQLITE_ENABLE_UNKNOWN_SQL_FUNCTION`][doc] (my default one was not,
but compiling SQLite is straightforward), SQLite will substitute custom
functions inside `EXPLAIN` and `EXPLAIN QUERY PLAN` queries (and only
inside those -- this is the whole point of that flag) with a special
"`unknown()`" function allowing the query plan to still be generated.

This is a more convenient stable way to get this functionality, as it is
amenable to tweaking the query, adding indices, etc. and seeing how the
plan changes as a result -- avoiding the need to recompile a large Rust
codebase and rerun its test suite. But more importantly, it's stable,
and does not tie you to an old version of SQLite.

[doc]: https://www.sqlite.org/compile.html#enable_unknown_sql_function
2022-03-06 20:27:43 -08:00
Thom Chiovoloni 4d3f7db7fc
Bump versions of `rusqlite`/`libsqlite3-sys` in `Cargo.toml`s 2022-03-06 20:27:06 -08:00
jhugman 98e611c51d
Prepare components for using uniffi Custom types (#4829) r=bdk
* Prepare Nimbus for using uniffi Custom types

* Update places to use renamed Custom types

* Increment uniffi version number

* Update Cargo.lock

* Fixup ktlint
2022-02-08 16:52:37 +00:00
Tarik Eshaq 68c10e0673
upgrades to rust 2021 [ci full] (#4822)
* upgrades to rust 2021

* Push rust minimum version to 1.57
2022-02-07 09:38:05 -08:00
Sammy Khamis 73427f79a6
Places uniffication (#4770)
* initial conversion of errors for places uniffication

* Converted history metadata functions for places uniffication

* Converted kotlin history metadata functions

* Converted iOS history metadata functions

* [Places uniffication] Fix places error issues (#4687)

* remove uniffi-specific wrapper and updated error test

* Uniffi VisitObservation and apply_observation (#4689)

* uniffied VisitObservation, HistoryVisitInfo and methods using those structs

* Uniffi top frecent site info (#4711)

* Uniffi top frecent site info

* Uniffis FrecencyThresholdOption

* Uniffi Places Sync (#4714)

* uniffi places sync and sync15 functions

* Uniffi Search result and match url (#4720)

* Uniffi query autocomplete

* uniffi places_accept_result

* uniffi places_match_url

* cargo fmt

* cargo clippy

* remove accept_result from ffi crate

* Adds comment on the uniffi bug with varaint shadowing type

* Uniffi Places Interrupt methods (#4726)

* uniffi places interrupt functions

* Consolidate types (#4736)

* Updates the visit observation to use URL

* Uses VisitTransition for HistoryVisitInfo

* updates uniffi to 0.16

* Uniffied bookmarks

* switch to use uint in the apis for adding bookmarks (#4747)

* Remove the manual places FFI entirely.

* folders and separators now have non-nullable parents

* Always insert via Insertable items, and clarify separation between node types.

* Add json_tree module with all json-based types and implementation.

* Fix swift warnings re non-null parentGuid

* bookmarks: Remove public_node and introduce a fetch module

* Update swift code to make breaking changes fixes cleaner (#4766)

* rebased and added changelog entry

Co-authored-by: lougeniac64 <lougeniaC64@users.noreply.github.com>
Co-authored-by: Tarik Eshaq <teshaq@mozilla.com>
Co-authored-by: Mark Hammond <mhammond@skippinet.com.au>
2022-01-20 15:00:00 -05:00
Mark Hammond 59c049af40
Update to uniffi 0.15.2 (#4677) 2021-11-25 12:00:46 +11:00
Mark Hammond 2661c5d74c
Move to parking_lot::Mutex in logins, places and sync_manager (#4663) 2021-11-22 11:00:53 +11:00
Grisha Kruglov 95c3641d8f
Closes #4451: Introduce getHistoryHighlights API (#4500) 2021-09-23 16:02:21 +10:00
Sammy Khamis 6c839a3ade
Update uniffi 0.14.0 (#4389)
* Update UniFFI dependency to v0.14.0

Co-authored-by: Ryan Kelly <ryan@rfk.id.au>
2021-08-19 16:31:02 -10:00
Mark Hammond 212b6fcfa7
Replace places history_metadata's protobuf implementations with uniffi. (#4183)
This is intended to be a small but significant step on the road to uniffi-ing
places. It takes all the hard stuff from Ryan's #3900, but limits the scope to just
the new-ish history_metadata module.

Co-authored-by: Ryan Kelly <ryan@rfk.id.au>
Co-authored-by: Sammy Khamis <skhamis@mozilla.com>
2021-08-03 19:21:08 +10:00
Tarik Eshaq 46fccb5cea Updates cargo dependencies and bumps prost to 0.8 2021-07-12 15:39:18 +10:00
dependabot-preview[bot] 5220605d08 Bump rusqlite from 0.24.1 to 0.24.2
Bumps [rusqlite](https://github.com/rusqlite/rusqlite) from 0.24.1 to 0.24.2.
- [Release notes](https://github.com/rusqlite/rusqlite/releases)
- [Changelog](https://github.com/rusqlite/rusqlite/blob/master/Changelog.md)
- [Commits](https://github.com/rusqlite/rusqlite/compare/v0.24.1...v0.24.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-11 10:14:54 +11:00
Mark Hammond adb8907e00
Update rusqlite to 0.24.1 and libsqlite3-sys to 0.20.1 (#3633) 2020-10-08 14:27:52 +11:00
lougeniac64 f14634bcc9 Removed duplicate timestamp code from places component 2020-09-21 15:00:30 -04:00
Thom Chiovoloni 821c163ba3 Optimize project layout to avoid bad build performance 2020-07-20 09:56:36 -07:00
Edouard Oger 0f35356520
Enable rusqlite unlock_notify feature 2020-07-09 13:09:23 -04:00
Tarik Eshaq 4f434a1e90 uses thiserror and anyhow to replace failure
- Updates components/support/error/src/lib.rs to have
its own backtrace rather than using failure::backtrace
- Changes all occurences of #[derive(failure::Fail)] with
 #[derive(thiserror::Error)]
- Changes all occurences of failure::Error with anyhow::Error
- Replaces Result<T, failure::Error> with anyhow::Result<T>
- Bumps ece, find_places_db and hawk so that they don't use
 failure either
- Modifies rc_crypto/ece_crypto to work with ece v1.2
2020-05-28 10:55:54 -07:00
Edouard Oger 823bf9bdd7
Run cargo update [ci full] 2020-05-22 14:38:12 -04:00
dependabot-preview[bot] 52b95f6a2e
Bump once_cell from 1.3.1 to 1.4.0
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.3.1 to 1.4.0.
- [Release notes](https://github.com/matklad/once_cell/releases)
- [Changelog](https://github.com/matklad/once_cell/blob/master/CHANGELOG.md)
- [Commits](https://github.com/matklad/once_cell/compare/v1.3.1...v1.4.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-19 10:21:24 -04:00
Edouard Oger 76d108d55a
Cargo update 2020-05-05 13:12:59 -04:00
Edouard Oger 25a09e62eb Relax URL version 2020-04-30 17:56:50 +00:00
dependabot-preview[bot] a00c0b05ad
Bump criterion from 0.3.1 to 0.3.2
Bumps [criterion](https://github.com/bheisler/criterion.rs) from 0.3.1 to 0.3.2.
- [Release notes](https://github.com/bheisler/criterion.rs/releases)
- [Changelog](https://github.com/bheisler/criterion.rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/bheisler/criterion.rs/compare/0.3.1...0.3.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-04-28 08:49:36 +00:00
Thom Chiovoloni e9fb25f4b9 Actually, use rusqlite 0.23.1 2020-04-24 17:36:35 +00:00
Thom Chiovoloni 978f3d2819 Bump rusqlite to 0.23.0 [ci full] 2020-04-24 17:36:35 +00:00
Thom Chiovoloni 362bf6a38c
Respond to review feedback 2020-04-23 14:57:42 -07:00
Thom Chiovoloni e9e8010641
Modernize `interrupt` crate and rename to `saci-interrupt` 2020-04-23 14:26:03 -07:00
Edouard Oger a3310bc218
Exclude mobile bindings from cargo packaging 2020-04-20 14:17:55 -04:00
Thom Chiovoloni 555f4aead8
Bump rusqlite to 0.22.0 [ci full] 2020-04-10 07:03:23 -07:00
Edouard Oger 3f5f66d68f
Replace build-generated rust protobuf files by pre-generated ones 2020-04-08 16:19:30 -04:00