IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
320: Implement Ipfs::find_peer and /dht/findpeer r=koivunej a=ljedrz
Builds on https://github.com/rs-ipfs/rust-ipfs/pull/319, only the last 2 commits are new.
Introduces `Ipfs::find_peer` and `/dht/findpeer` that return addresses belonging to the given `PeerId`; if they are connected to already, the values are returned right away, otherwise the local DHT records are checked.
Blocked by https://github.com/rs-ipfs/rust-ipfs/pull/319.
Co-authored-by: ljedrz <ljedrz@gmail.com>
321: fix: make ipfs-http to use ipfs::IpfsPath r=ljedrz a=koivunej
First step towards solving the #238
- fix `ipfs::IpfsPath`
- swapped `ipfs::path::SubPath` for `String` (commit has reason)
- removed `IpfsPath::push(&mut self, segment: impl Into<SubPath>)`
- remove the implicit ending empty path segment (seemed intentional, don't know why that was there)
- migrate tests
- most notably add support for `cid/a/b/c` cases
- move "good_but_unsupported" over to "good_paths" (as ipfs::IpfsPath validates more)
- make ipfs-http use `ipfs::IpfsPath`
This specifically doesn't include:
- separation of different kinds of IpfsPaths (`CidPath`, `IpnsPath`)
- instead there is currently an expect over at http side for cid paths
- probably a good idea to refactor out the `Vec<String>` (sub)path somehow; it might be heavily reusable for unixfs for example
- moving the resolving over to ipfs from the current not so great `ipfs_http::v0::refs::walk_paths`
These should be handled on next PRs. The end result here is not too pretty but it shouldn't break much either.
Big unsolved mysteries:
- how to implement conformance test compatible refs once this has been moved over to ipfs (probably need to adjust the test)
Co-authored-by: Joonas Koivunen <joonas@equilibrium.co>
Co-authored-by: ljedrz <ljedrz@users.noreply.github.com>
322: ci: update run-vcpkg (get windows caching) r=ljedrz a=koivunej
according to commits there have been some changes related to caching,
unable to determine if they actually fix anything.
Co-authored-by: Joonas Koivunen <joonas@equilibrium.co>
we cannot really do upfront parsing of subpaths to indices or strings
since ipld maps can contain stringified numbers as keys, so we dont know
if something is a key into map or vec index by looking at the path.
319: Introduce KadResult r=koivunej a=ljedrz
I've been planning to add some of the `/dht` functionalities and since it looks like it's going to be a bit complicated, I'd like to split these upcoming changes into meaningful bits.
First up: the ability to get results from `Kademlia`'s `SubscriptionRegistry`. While working on this I noticed that some of the results can be provided multiple times (e.g. `BootstrapOk` that indicates the number of peers left to bootstrap against), which should solve the mystery of `Kademlia` not adhering to the `debug_assert` we have in `SubscriptionRegistry::finish_subscription`.
As an accidental drive-by there's also a fix to the `Kademlia` bootstrap test which was silently failing after we introduced the `Multiaddr` wrappers.
Co-authored-by: ljedrz <ljedrz@gmail.com>
318: Update libp2p and use TokioMdns r=koivunej a=ljedrz
`libp2p 0.24` enables us to only depend on a single async executor (in our case, `tokio`).
A small change in the code, a big win for `Cargo.lock`.
Co-authored-by: ljedrz <ljedrz@gmail.com>
315: Use explicit Multiaddr wrappers r=koivunej a=ljedrz
Whether a `Multiaddr` contains `Protocol::P2p` (i.e. essentially `/p2p/PeerId`) or not has a lot of bearing on conformance tests, the internal object and APIs and error-handling. Since it is easy to introduce related human errors, it would be a good idea to enforce some type safety here by introducing 2 wrapper objects: `MultiaddrWoPeerId` and `MultiaddrWithPeerId`.
The extent to which they should be applied (in lieu of `Multiaddr`) is a matter for discussion - in my initial attempt I decided to apply them quite liberally, as it results in more type safety (there are still a few plain `Multiaddr`s left though).
Co-authored-by: ljedrz <ljedrz@gmail.com>
317: Conformance test suite updates r=koivunej a=ljedrz
`package.json` updates:
```
"interface-ipfs-core": "0.137.0" > "0.139.0"
"ipfs-http-client": "^44.3.0" > "46.0.0"
"ipfs": "^0.43.0" > "0.49.0"
```
The new version of the conformance test suite requires 2 new `/version` fields (blank for now) and a patch for one of the `add` tests (as we don't expose `/files` yet). ~~It also allows us to transition the `Repo` to only keep `Multihash`es instead of `Cid`s, as `refs_local` is expected to return `Cid v1` with `Codec::Raw`, which can be produced on the fly.~~ (deferred)
Co-authored-by: ljedrz <ljedrz@gmail.com>
316: Clippy r=koivunej a=c410-f3r
Fixes a couple of Clippy issues and ensures on CI that these problems won't happen again in the future
Co-authored-by: Caio <c410.f3r@gmail.com>