Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
touilleMan committed May 9, 2023
1 parent f2c5d82 commit 52e0455
Show file tree
Hide file tree
Showing 15 changed files with 23 additions and 16 deletions.
7 changes: 7 additions & 0 deletions .cspell/custom-words.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ drawio
duckpy
dvipdfmx
EINVAL
endup
enmascarado
excrepr
executemany
Expand Down Expand Up @@ -198,6 +199,7 @@ linuxsys
Ljava
llabel
localdb
localns
LowLevel
lproj
lsregister
Expand All @@ -214,6 +216,7 @@ metaraw
miniserde
mnone
moff
monomorphization
mountpoint
MountPoints
msgid
Expand All @@ -223,12 +226,15 @@ multibytes
mycapacitorapp
myclass
Nanos
ntns
ntics
napi
newsfragment
newsfragments
Niño
nmspc
nocapture
noserver
NONCEBYTES
noopener
noreferrer
Expand All @@ -247,6 +253,7 @@ oneofschema
Onone
OpsLimit
ORGANIZATIONID
orgid
oscrypt
oscrypto
OSXFUSE
Expand Down
2 changes: 1 addition & 1 deletion oxidation/libparsec/crates/client/src/certificates_ops.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ impl CertificatesOps {
// supposed to be added in a strictly causal order, hence
// we are supposed to have already added all the certificates
// needed to validate this one. And if that's not the case
// it's suspicious and error sould be raised !
// it's suspicious and error should be raised !
return Err(InvalidCertificateError::UnknownAuthor {
hint: $unsecure.hint(),
author: $author.clone(),
Expand Down
2 changes: 1 addition & 1 deletion oxidation/libparsec/crates/client/src/event_bus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ macro_rules! impl_broadcastable {
// th comparison is done on the fat pointer (i.e. both the pointer
// on the data and the pointer on the vtable).
// see: https://github.com/rust-lang/rust/issues/106447
// So the solution is to manualy transform the fat pointer into
// So the solution is to manually transform the fat pointer into
// a thin one (i.e. the pointer on the data)
let e_fatptr: *const _ = e.as_ref();
let e_thinptr = e_fatptr as *const () as usize;
Expand Down
4 changes: 2 additions & 2 deletions oxidation/libparsec/crates/client_connection/src/testbed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ impl ResponseMock {
}

// We want the testbed to return an async function pointer to mock client requests.
// In Rust this is increadibly cumbersome to do:
// In Rust this is incredibly cumbersome to do:
// - `*SendHookFn` can have multiple implementation, so it must be boxed
// - async function is considered as a regular function that return a future...
// - ...future which must be wrapped in a pinned box given it can have multiple
// implementations
// - `*SendHookFn` is going to be stored in structure that use `Debug`, so
// it must implement those traits itself.
// Due to Rust's orphan rule, the only way to do that is to indroduce our own trait
// Due to Rust's orphan rule, the only way to do that is to introduce our own trait
// `*SendHookFnT` on which we implement `Debug`.
// From that, `SendHookFnT` must be auto-implemented on each closure that respect
// the send hook signature.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ impl CertificatesStorage {
.await
}

/// We never remove nor replace certificates, as a certifacet is immutable (a new
/// We never remove nor replace certificates, as a certificate is immutable (a new
/// certificate should be issued to represent a modification, e.g. for realm role)
/// So if the server start sending certificates that doesn't match with the one we
/// currently have stored, it means somebody is acting fishy !
Expand All @@ -395,7 +395,7 @@ impl CertificatesStorage {
let _update_guard = self.lock_update.lock().await;

// It's unlikely the certificate is already present, so we don't check for it
// existance in cache and rely instead on the unique violation error from SQlite
// existence in cache and rely instead on the unique violation error from SQlite
self.db
.exec(move |conn| {
conn.immediate_transaction(|conn| {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ table! {
// The format for `hint` is "<field_name>:<field_value> <field_name>:<field_value>..."
// For instance:
// - User & revoked user certificates: "user_id:2199bb7d21ec4988825db6bcf9d7a43e"
// - Realm role certficate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e realm_id:dcf41c521cae4682a4cf29302e2af1b6"
// - Realm role certificate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e realm_id:dcf41c521cae4682a4cf29302e2af1b6"
// - Device certificate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e device_name:78c339d140664e909961c05b4d9add4c"
// - sequester service certificate: "service_id:1fc552746e1e4a27aa9fd2aa9c8c95cc"
// - Sequester authority: "" (nothing to index)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ CREATE TABLE IF NOT EXISTS certificates (
-- The format for `hint` is "<field_name>:<field_value> <field_name>:<field_value>..."
-- For instance:
-- - User & revoked user certificates: "user_id:2199bb7d21ec4988825db6bcf9d7a43e"
-- - Realm role certficate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e realm_id:dcf41c521cae4682a4cf29302e2af1b6"
-- - Realm role certificate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e realm_id:dcf41c521cae4682a4cf29302e2af1b6"
-- - Device certificate: "user_id:2199bb7d21ec4988825db6bcf9d7a43e device_name:78c339d140664e909961c05b4d9add4c"
-- - sequester service certificate: "service_id:1fc552746e1e4a27aa9fd2aa9c8c95cc"
-- - Sequester authority: "" (nothing to index)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"unit": "APIEvent"
},
{
// Returned if the command is used through the regualr rpc route
// Returned if the command is used through the regular rpc route
// instead of the SSE one
"status": "not_available"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// We don't want to have this crate depend on `libparsec_types` for it test
// given `libparsec_types` itself uses this crate... hence in case of bug in
// this crate we wouldn't be able to use the tests !
// So here we simulate `liparsec_types` by implementing the bare minimum that
// So here we simulate `libparsec_types` by implementing the bare minimum that
// our macros need.

pub type Integer = i64;
Expand Down
2 changes: 1 addition & 1 deletion oxidation/libparsec/crates/testbed/tests/unit/testbed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ pub fn generate_stability() {
}

#[test]
pub fn get_template_statibility() {
pub fn get_template_stability() {
let a1 = get_template("minimal");
let a2 = get_template("minimal");
assert!(Arc::ptr_eq(&a1, &a2));
Expand Down
2 changes: 1 addition & 1 deletion oxidation/libparsec/crates/types/src/certif.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ fn check_author_allow_root(
}

pub enum UnsecureSkipValidationReason {
// Certificate must have been valided prior to being added to the local storage,
// Certificate must have been validated prior to being added to the local storage,
// on top of that the certificate are store encrypted so they cannot be tempered.
// Hence it's safe not to validate the certificate when reading thom from the
// local storage.
Expand Down
2 changes: 1 addition & 1 deletion parsec/api/protocol/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
unpackb,
)

# TODO: Tests should use the json shema instead of this
# TODO: Tests should use the json schema instead of this
from parsec.api.protocol.cmds import (
ANONYMOUS_CMDS,
AUTHENTICATED_CMDS,
Expand Down
2 changes: 1 addition & 1 deletion parsec/backend/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ def _on_event(
_on_event, # type: ignore
)

# We must do that here to be righ after even bus connection, but before any
# We must do that here to be right after even bus connection, but before any
# async operation, otherwise a concurrent event may be handled by the registered
# callbacks and also appear in the cache (and in the end we will send to the
# client this event twice !)
Expand Down
2 changes: 1 addition & 1 deletion parsec/backend/memory/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ async def update_user(
if user.revoked_on or user.profile == new_profile:
raise UserAlreadyExistsError()

# TODO: check all user/device/realm roles certifiactes creation date against `updated_on`
# TODO: check all user/device/realm roles certificates creation date against `updated_on`
# and raise `UserRequireGreaterTimestampError`

# TODO: check the last vlob the updated user has uploaded is not posterior to
Expand Down
2 changes: 1 addition & 1 deletion tests/core/backend_connection/test_authenticated_cmds.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ async def test_handshake_revoked_device(running_backend, alice, bob):

@pytest.mark.trio
async def test_organization_expired(running_backend, alice, expiredorg):
# Organization expiration is checked before user existance, so we can
# Organization expiration is checked before user existence, so we can
# use a dummy user for this test
expiredorg_alice = LocalDevice.generate_new_device(
organization_addr=expiredorg.addr,
Expand Down

0 comments on commit 52e0455

Please sign in to comment.