Plume-org / Plume

Federated blogging application, thanks to ActivityPub (now on https://git.joinplu.me/ — this is just a mirror)

Home Page:https://joinplu.me

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to run migration after upgrade

maxolasersquad opened this issue · comments

I tried upgrading to Plume 0.5.0. I checked out branch 0.5.0. I started following the instructions at https://docs.joinplu.me/update/source-code but when I got to plm migration run it gave me the following error.

plume@hamurabi:~/Plume$ plm migration run
Configuration read from /home/plume/Plume/.env
thread 'main' panicked at 'Failed to run migrations: NotFound', plume-cli/src/migration.rs:48:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
plume@hamurabi:~/Plume$ RUST_BACKTRACE=full plm migration run
Configuration read from /home/plume/Plume/.env
thread 'main' panicked at 'Failed to run migrations: NotFound', plume-cli/src/migration.rs:48:5
stack backtrace:
   0:   0x87eea1 - backtrace::backtrace::libunwind::trace::h85c30131a0dec24e
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/libunwind.rs:88
   1:   0x87eea1 - backtrace::backtrace::trace_unsynchronized::h921997e0546f34ae
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/mod.rs:66
   2:   0x87eea1 - std::sys_common::backtrace::_print_fmt::h21982e53f592a106
                       at src/libstd/sys_common/backtrace.rs:77
   3:   0x87eea1 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h69c6e5980f3aaa11
                       at src/libstd/sys_common/backtrace.rs:59
   4:   0x8a0a9c - core::fmt::write::h0762c8ebcff34b38
                       at src/libcore/fmt/mod.rs:1057
   5:   0x87ad4c - std::io::Write::write_fmt::h1371e7e0e42f565d
                       at src/libstd/io/mod.rs:1426
   6:   0x8818ee - std::sys_common::backtrace::_print::h30f48ac6a25f64b4
                       at src/libstd/sys_common/backtrace.rs:62
   7:   0x8818ee - std::sys_common::backtrace::print::h102780d90ef5dd2b
                       at src/libstd/sys_common/backtrace.rs:49
   8:   0x8818ee - std::panicking::default_hook::{{closure}}::hfd1443ea3d275929
                       at src/libstd/panicking.rs:204
   9:   0x8815b3 - std::panicking::default_hook::h04f4c47c9d53b75b
                       at src/libstd/panicking.rs:224
  10:   0x881fac - std::panicking::rust_panic_with_hook::h82d86946573af827
                       at src/libstd/panicking.rs:472
  11:   0x881b58 - rust_begin_unwind
                       at src/libstd/panicking.rs:380
  12:   0x89f220 - core::panicking::panic_fmt::h8126505ca53cf226
                       at src/libcore/panicking.rs:85
  13:   0x89f022 - core::option::expect_none_failed::h92f24811b2f30de5
                       at src/libcore/option.rs:1198
  14:   0x4a3a31 - plm::migration::run::hc34b1ef2c9ce5c89
  15:   0x4aebe5 - plm::main::he002989405e96731
  16:   0x49f376 - std::rt::lang_start::{{closure}}::hc5e16bc8cfd03194
  17:   0x87f726 - std::rt::lang_start_internal::{{closure}}::{{closure}}::h1b3708f4176810dc
                       at src/libstd/rt.rs:52
  18:   0x87f726 - std::sys_common::backtrace::__rust_begin_short_backtrace::habb4ed333d8d62d9
                       at src/libstd/sys_common/backtrace.rs:129
  19:   0x881a0f - std::rt::lang_start_internal::{{closure}}::hb2e445c8e07a7e30
                       at src/libstd/rt.rs:52
  20:   0x881a0f - std::panicking::try::do_call::h8ec12ab02f09b41d
                       at src/libstd/panicking.rs:305
  21:   0x886158 - __rust_maybe_catch_panic
                       at src/libpanic_unwind/lib.rs:86
  22:   0x8823ec - std::panicking::try::h7bfc7bf8c289bbfa
                       at src/libstd/panicking.rs:281
  23:   0x8823ec - std::panic::catch_unwind::hf1ff911fc948eea5
                       at src/libstd/panic.rs:394
  24:   0x8823ec - std::rt::lang_start_internal::h43b6597864427830
                       at src/libstd/rt.rs:51
  25:   0x4af441 - main
  26: 0xb79b9e91 - __libc_start_main
  27:   0x4995db - <unknown>
  • Plume version:
    0.5.0

  • Operating system:
    Ubuntu GNU/Linux 18.04

I may be digging myself into a deeper hole by running things I don't fully understand, but I ran diesel migration run and that applied the migrations. And now when I run plm migration run it returns without error. However, when I try to start the plume service I get the following.

plume@hammurabi:~/Plume$ RUST_BACKTRACE=full /home/plume/.cargo/bin/plume
Configuration read from /home/plume/Plume/.env
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: IndexCreationError', src/main.rs:126:18
stack backtrace:
   0:  0x106e3d1 - backtrace::backtrace::libunwind::trace::h85c30131a0dec24e
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/libunwind.rs:88
   1:  0x106e3d1 - backtrace::backtrace::trace_unsynchronized::h921997e0546f34ae
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/mod.rs:66
   2:  0x106e3d1 - std::sys_common::backtrace::_print_fmt::h21982e53f592a106
                       at src/libstd/sys_common/backtrace.rs:77
   3:  0x106e3d1 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h69c6e5980f3aaa11
                       at src/libstd/sys_common/backtrace.rs:59
   4:  0x109243c - core::fmt::write::h0762c8ebcff34b38
                       at src/libcore/fmt/mod.rs:1057
   5:  0x106790c - std::io::Write::write_fmt::h1371e7e0e42f565d
                       at src/libstd/io/mod.rs:1426
   6:  0x1070e6e - std::sys_common::backtrace::_print::h30f48ac6a25f64b4
                       at src/libstd/sys_common/backtrace.rs:62
   7:  0x1070e6e - std::sys_common::backtrace::print::h102780d90ef5dd2b
                       at src/libstd/sys_common/backtrace.rs:49
   8:  0x1070e6e - std::panicking::default_hook::{{closure}}::hfd1443ea3d275929
                       at src/libstd/panicking.rs:204
   9:  0x1070b33 - std::panicking::default_hook::h04f4c47c9d53b75b
                       at src/libstd/panicking.rs:224
  10:  0x107152c - std::panicking::rust_panic_with_hook::h82d86946573af827
                       at src/libstd/panicking.rs:472
  11:  0x10710d8 - rust_begin_unwind
                       at src/libstd/panicking.rs:380
  12:  0x10907b0 - core::panicking::panic_fmt::h8126505ca53cf226
                       at src/libcore/panicking.rs:85
  13:  0x10905b2 - core::option::expect_none_failed::h92f24811b2f30de5
                       at src/libcore/option.rs:1198
  14:   0x70473b - plume::main::hac8d852911614193
  15:   0x70e606 - std::rt::lang_start::{{closure}}::hfabbeff00a3d96ac
  16:  0x106ec56 - std::rt::lang_start_internal::{{closure}}::{{closure}}::h1b3708f4176810dc
                       at src/libstd/rt.rs:52
  17:  0x106ec56 - std::sys_common::backtrace::__rust_begin_short_backtrace::habb4ed333d8d62d9
                       at src/libstd/sys_common/backtrace.rs:129
  18:  0x1070f8f - std::rt::lang_start_internal::{{closure}}::hb2e445c8e07a7e30
                       at src/libstd/rt.rs:52
  19:  0x1070f8f - std::panicking::try::do_call::h8ec12ab02f09b41d
                       at src/libstd/panicking.rs:305
  20:  0x1077118 - __rust_maybe_catch_panic
                       at src/libpanic_unwind/lib.rs:86
  21:  0x1071a3c - std::panicking::try::h7bfc7bf8c289bbfa
                       at src/libstd/panicking.rs:281
  22:  0x1071a3c - std::panic::catch_unwind::hf1ff911fc948eea5
                       at src/libstd/panic.rs:394
  23:  0x1071a3c - std::rt::lang_start_internal::h43b6597864427830
                       at src/libstd/rt.rs:51
  24:   0x70d2a1 - main
  25: 0xb794ee91 - __libc_start_main
  26:   0x4bcf7b - <unknown>

I have tried updating the index.

plume@hammurabi:~/Plume$ RUST_BACKTRACE=full plm search refill
Configuration read from /home/plume/Plume/.env
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Search(IndexCreationError)', plume-cli/src/search.rs:102:36
stack backtrace:
   0:   0x8a0ff1 - backtrace::backtrace::libunwind::trace::h85c30131a0dec24e
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/libunwind.rs:88
   1:   0x8a0ff1 - backtrace::backtrace::trace_unsynchronized::h921997e0546f34ae
                       at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.40/src/backtrace/mod.rs:66
   2:   0x8a0ff1 - std::sys_common::backtrace::_print_fmt::h21982e53f592a106
                       at src/libstd/sys_common/backtrace.rs:77
   3:   0x8a0ff1 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h69c6e5980f3aaa11
                       at src/libstd/sys_common/backtrace.rs:59
   4:   0x8c2bec - core::fmt::write::h0762c8ebcff34b38
                       at src/libcore/fmt/mod.rs:1057
   5:   0x89ce9c - std::io::Write::write_fmt::h1371e7e0e42f565d
                       at src/libstd/io/mod.rs:1426
   6:   0x8a3a3e - std::sys_common::backtrace::_print::h30f48ac6a25f64b4
                       at src/libstd/sys_common/backtrace.rs:62
   7:   0x8a3a3e - std::sys_common::backtrace::print::h102780d90ef5dd2b
                       at src/libstd/sys_common/backtrace.rs:49
   8:   0x8a3a3e - std::panicking::default_hook::{{closure}}::hfd1443ea3d275929
                       at src/libstd/panicking.rs:204
   9:   0x8a3703 - std::panicking::default_hook::h04f4c47c9d53b75b
                       at src/libstd/panicking.rs:224
  10:   0x8a40fc - std::panicking::rust_panic_with_hook::h82d86946573af827
                       at src/libstd/panicking.rs:472
  11:   0x8a3ca8 - rust_begin_unwind
                       at src/libstd/panicking.rs:380
  12:   0x8c1370 - core::panicking::panic_fmt::h8126505ca53cf226
                       at src/libcore/panicking.rs:85
  13:   0x8c1172 - core::option::expect_none_failed::h92f24811b2f30de5
                       at src/libcore/option.rs:1198
  14:   0x4c12c4 - plm::search::refill::h5074a10de8615e18
  15:   0x4c0653 - plm::search::run::hfc0a7b47d12def1a
  16:   0x4d0a9b - plm::main::h50f3a2ef172ff1ef
  17:   0x4c1376 - std::rt::lang_start::{{closure}}::h90d51f75b2e324f9
  18:   0x8a1876 - std::rt::lang_start_internal::{{closure}}::{{closure}}::h1b3708f4176810dc
                       at src/libstd/rt.rs:52
  19:   0x8a1876 - std::sys_common::backtrace::__rust_begin_short_backtrace::habb4ed333d8d62d9
                       at src/libstd/sys_common/backtrace.rs:129
  20:   0x8a3b5f - std::rt::lang_start_internal::{{closure}}::hb2e445c8e07a7e30
                       at src/libstd/rt.rs:52
  21:   0x8a3b5f - std::panicking::try::do_call::h8ec12ab02f09b41d
                       at src/libstd/panicking.rs:305
  22:   0x8a82a8 - __rust_maybe_catch_panic
                       at src/libpanic_unwind/lib.rs:86
  23:   0x8a453c - std::panicking::try::h7bfc7bf8c289bbfa
                       at src/libstd/panicking.rs:281
  24:   0x8a453c - std::panic::catch_unwind::hf1ff911fc948eea5
                       at src/libstd/panic.rs:394
  25:   0x8a453c - std::rt::lang_start_internal::h43b6597864427830
                       at src/libstd/rt.rs:51
  26:   0x4d13c1 - main
  27: 0xb79e9e91 - __libc_start_main
  28:   0x4bb5db - <unknown>

I feel like there is some deeper underlying issue that is the reason that these commands keep failing.

So, I got the exact same error. Which I believe, has to do with the search_index. After removing my search_index folder and running plm search init, running plume works again.

That did the trick. I wonder if we should leave this bug report open for the devs to look into the search index being broken.

Perhaps... but, I'd say that since this repo is the "mirror" of the actual, to open an account on their site and report your/our findings there.

Ah. Will do. Thans @iamdoubz .

I already did on our behalf: https://git.joinplu.me/Plume/Plume/issues/822

And, you are welcome! I really like Plume and want to see it succeed.