matrix-migrate
matrix-migrate copied to clipboard
Fixed cargo install line in README
I think the cargo install command was wrong, it was referencing matrix.org, not github, and when I ran it I got 404s.
When I try running this with a recent version of cargo, and I have actually used a rust:slim docker container for the build, the build fails with the following six errors:
error[E0599]: no method named `get_joined_room` found for struct `matrix_sdk::Client` in the current scope
--> src/main.rs:202:39
|
202 | let Some(joined) = from_c.get_joined_room(&room_id) else {
| ^^^^^^^^^^^^^^^
|
help: there is a method `get_room` with a similar name
|
202 - let Some(joined) = from_c.get_joined_room(&room_id) else {
202 + let Some(joined) = from_c.get_room(&room_id) else {
|
error[E0599]: no method named `get_invited_room` found for reference `&matrix_sdk::Client` in the current scope
--> src/main.rs:245:34
|
245 | let Some(invited) = to_c.get_invited_room(&room_id) else {
| ^^^^^^^^^^^^^^^^
|
help: there is a method `get_room` with a similar name
|
245 - let Some(invited) = to_c.get_invited_room(&room_id) else {
245 + let Some(invited) = to_c.get_room(&room_id) else {
|
error[E0599]: no method named `get_joined_room` found for reference `&matrix_sdk::Client` in the current scope
--> src/main.rs:246:21
|
246 | if to_c.get_joined_room(room_id).is_some() { // already existing, skipping
| ^^^^^^^^^^^^^^^
|
help: there is a method `get_room` with a similar name
|
246 - if to_c.get_joined_room(room_id).is_some() { // already existing, skipping
246 + if to_c.get_room(room_id).is_some() { // already existing, skipping
|
error[E0599]: no method named `get_joined_room` found for struct `matrix_sdk::Client` in the current scope
--> src/main.rs:273:39
|
273 | let Some(joined) = from_c.get_joined_room(&room_id) else {
| ^^^^^^^^^^^^^^^
|
help: there is a method `get_room` with a similar name
|
273 - let Some(joined) = from_c.get_joined_room(&room_id) else {
273 + let Some(joined) = from_c.get_room(&room_id) else {
|
error[E0599]: no method named `login_username` found for struct `matrix_sdk::Client` in the current scope
--> src/main.rs:66:10
|
65 | / from_c
66 | | .login_username(args.from_user, &args.from_user_password)
| | -^^^^^^^^^^^^^^ method not found in `matrix_sdk::Client`
| |_________|
|
error[E0599]: no method named `login_username` found for struct `matrix_sdk::Client` in the current scope
--> src/main.rs:82:10
|
82 | to_c.login_username(args.to_user, &args.to_user_password)
| ^^^^^^^^^^^^^^ method not found in `matrix_sdk::Client`
Even with this fixed command, the build no longer works.
It appears that the methods get_joined_room and get_invited_room have been removed or replaced in later versions of the matrix-sdk.