• Extensions
  • FriendsOfFlarum Byōbu, well integrated, advanced private discussions

  • [deleted]

@luceos there seems to be a bug, as I can't enable the extension. In the logs

Next Illuminate\Database\QueryException: SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'recipients' already exists (SQL: create tablerecipients(idbigint unsigned not null auto_increment primary key,discussion_idint unsigned not null,user_idint unsigned not null,created_attimestamp null,updated_attimestamp null,removed_attimestamp null) default character set utf8mb4 collate 'utf8mb4_unicode_ci' engine = InnoDB) in /home/inoculrn/discuss.guruwall.com/vendor/illuminate/database/Connection.php:664

0.3.0-beta.3 tagged which should alleviate that.

    • [deleted]

    • Edited

    luceos Is this in composer ? I recall having this issue before - Byōbu0.2.2 is displayed in the extensions panel. Is there a command to force a particular extension ? We had to do this with Bazaar if you recall.

      • [deleted]

      • Edited

      luceos See comment above

      UPDATE: I see the new version now...

      • [deleted]

      I can't seem to remove the older version of Byōbu0.2.2 - there's no associated directory for it, yet it's showing in the extensions panel - and the newer version has disappeared. What's odd is that neither extension appears in composer.json ?

      • [deleted]

      Doesn't look right

      [inoculrn@s011 discuss.guruwall.com]$ composer require fof/byobu
      Using version ^0.2.2 for fof/byobu
      ./composer.json has been updated
      Loading composer repositories with package information
      Updating dependencies (including require-dev)
      Package operations: 1 install, 0 updates, 0 removals
        - Installing fof/byobu (0.2.2): Loading from cache
      Writing lock file
      Generating autoload files
      [inoculrn@s011 discuss.guruwall.com]$ composer remove flagrow/byobu
      flagrow/byobu is not required in your composer.json and has not been removed
      Package "flagrow/byobu" listed for update is not installed. Ignoring.
      Loading composer repositories with package information
      Updating dependencies (including require-dev)
      Nothing to install or update
      Generating autoload files
      [inoculrn@s011 discuss.guruwall.com]$

      I land up with the old version (2.2) which won't activate

      Most certainly looks like fof/byobu has newer version: https://packagist.org/packages/fof/byobu, maybe composer fails to use the newer version because you're on a stable and are interested in a beta. Try:

      composer require "fof/byobu:^0.3.0"

      Once again, thanks for diving into this 👍

        • [deleted]

        luceos Works, but...

        Next Illuminate\Database\QueryException: SQLSTATE[42S21]: Column already exists: 1060 Duplicate column name 'blocks_byobu_pd' (SQL: alter tableusersaddblocks_byobu_pdtinyint(1) not null default '0') in /home/inoculrn/discuss.guruwall.com/vendor/illuminate/database/Connection.php:664

          • [deleted]

          luceos Once again, thanks for diving into this

          No problems. Loving the bleeding edge 😀

          [deleted] this happens because it seems you already migrated the column, try dropping that column blocks_byobu_pd from the users table. Love how hard it is when there's an initial error.

            • [deleted]

            luceos Love how hard it is when there's an initial error

            😁 all set !!

            Tagged 0.3.0 which fixes the user profile tab. My tests show it should now be stable again.

            PHP 7.3
            MySQL 8.0

            Next Illuminate\Database\QueryException: SQLSTATE[HY000]: General error: 1525 Incorrect TIMESTAMP value: 'null' (SQL: select `users`.*, `recipients`.`discussion_id` as `pivot_discussion_id`, `recipients`.`user_id` as `pivot_user_id`, `recipients`.`created_at` as `pivot_created_at`, `recipients`.`updated_at` as `pivot_updated_at` from `users` inner join `recipients` on `users`.`id` = `recipients`.`user_id` where `recipients`.`removed_at` != null and `recipients`.`discussion_id` in (1, 2)) in /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Connection.php:664
            Stack trace:
            #0 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Connection.php(624): Illuminate\Database\Connection->runQueryCallback('select `users`....', Array, Object(Closure))
            #1 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Connection.php(333): Illuminate\Database\Connection->run('select `users`....', Array, Object(Closure))
            #2 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Query/Builder.php(2095): Illuminate\Database\Connection->select('select `users`....', Array, true)
            #3 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Query/Builder.php(2083): Illuminate\Database\Query\Builder->runSelect()
            #4 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Query/Builder.php(2569): Illuminate\Database\Query\Builder->Illuminate\Database\Query\{closure}()
            #5 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Query/Builder.php(2084): Illuminate\Database\Query\Builder->onceWithColumns(Array, Object(Closure))
            #6 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Builder.php(519): Illuminate\Database\Query\Builder->get(Array)
            #7 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Relations/BelongsToMany.php(584): Illuminate\Database\Eloquent\Builder->getModels()
            #8 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Relations/Relation.php(144): Illuminate\Database\Eloquent\Relations\BelongsToMany->get()
            #9 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Builder.php(567): Illuminate\Database\Eloquent\Relations\Relation->getEager()
            #10 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Builder.php(536): Illuminate\Database\Eloquent\Builder->eagerLoadRelation(Array, 'oldRecipientUse...', Object(Closure))
            #11 /home/storage_01/data_04/web_0004/domain/public_html/vendor/illuminate/database/Eloquent/Collection.php(60): Illuminate\Database\Eloquent\Builder->eagerLoadRelations(Array)
            #12 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Api/Controller/ListDiscussionsController.php(99): Illuminate\Database\Eloquent\Collection->load(Array)
            #13 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Api/Controller/AbstractSerializeController.php(98): Flarum\Api\Controller\ListDiscussionsController->data(Object(Zend\Diactoros\ServerRequest), Object(Tobscure\JsonApi\Document))
            #14 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Api/Client.php(71): Flarum\Api\Controller\AbstractSerializeController->handle(Object(Zend\Diactoros\ServerRequest))
            #15 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Forum/Content/Index.php(91): Flarum\Api\Client->send(Object(Flarum\Api\Controller\ListDiscussionsController), Object(Flarum\User\User), Array)
            #16 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Forum/Content/Index.php(59): Flarum\Forum\Content\Index->getApiDocument(Object(Flarum\User\User), Array)
            #17 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Frontend/Frontend.php(65): Flarum\Forum\Content\Index->__invoke(Object(Flarum\Frontend\Document), Object(Zend\Diactoros\ServerRequest))
            #18 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Frontend/Frontend.php(57): Flarum\Frontend\Frontend->populate(Object(Flarum\Frontend\Document), Object(Zend\Diactoros\ServerRequest))
            #19 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Frontend/Controller.php(34): Flarum\Frontend\Frontend->document(Object(Zend\Diactoros\ServerRequest))
            #20 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/RouteHandlerFactory.php(40): Flarum\Frontend\Controller->handle(Object(Zend\Diactoros\ServerRequest))
            #21 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/DispatchRoute.php(67): Flarum\Http\RouteHandlerFactory->Flarum\Http\{closure}(Object(Zend\Diactoros\ServerRequest), Array)
            #22 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\DispatchRoute->process(Object(Zend\Diactoros\ServerRequest), Object(Closure))
            #23 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/ShareErrorsFromSession.php(58): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #24 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\ShareErrorsFromSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #25 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/SetLocale.php(51): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #26 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\SetLocale->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #27 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/CheckCsrfToken.php(25): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #28 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\CheckCsrfToken->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #29 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/AuthenticateWithSession.php(34): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #30 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\AuthenticateWithSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #31 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/RememberFromCookie.php(52): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #32 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\RememberFromCookie->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #33 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/StartSession.php(62): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #34 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\StartSession->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #35 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/CollectGarbage.php(48): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #36 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\CollectGarbage->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #37 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/ParseJsonBody.php(29): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #38 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\ParseJsonBody->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #39 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Middleware/HandleErrorsWithView.php(67): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #40 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Flarum\Http\Middleware\HandleErrorsWithView->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #41 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(83): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #42 /home/storage_01/data_04/web_0004/domain/public_html/vendor/middlewares/request-handler/src/RequestHandler.php(84): Zend\Stratigility\MiddlewarePipe->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #43 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\RequestHandler->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #44 /home/storage_01/data_04/web_0004/domain/public_html/vendor/middlewares/base-path-router/src/BasePathRouter.php(97): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #45 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\BasePathRouter->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #46 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Middleware/OriginalMessages.php(41): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #47 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Zend\Stratigility\Middleware\OriginalMessages->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #48 /home/storage_01/data_04/web_0004/domain/public_html/vendor/middlewares/base-path/src/BasePath.php(53): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #49 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/Next.php(60): Middlewares\BasePath->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\Next))
            #50 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(83): Zend\Stratigility\Next->handle(Object(Zend\Diactoros\ServerRequest))
            #51 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-stratigility/src/MiddlewarePipe.php(72): Zend\Stratigility\MiddlewarePipe->process(Object(Zend\Diactoros\ServerRequest), Object(Zend\Stratigility\EmptyPipelineHandler))
            #52 /home/storage_01/data_04/web_0004/domain/public_html/vendor/zendframework/zend-httphandlerrunner/src/RequestHandlerRunner.php(95): Zend\Stratigility\MiddlewarePipe->handle(Object(Zend\Diactoros\ServerRequest))
            #53 /home/storage_01/data_04/web_0004/domain/public_html/vendor/flarum/core/src/Http/Server.php(46): Zend\HttpHandlerRunner\RequestHandlerRunner->run()
            #54 /home/storage_01/data_04/web_0004/domain/public_html/public/index.php(22): Flarum\Http\Server->listen()
            #55 {main}  
            14 days later

            Is it possible to make a Byobu private conversation public? I cant seem to remove all the recipient tags...

              When I try to create a private post, or set a public post to private, I get Oops! Something went wrong. Please reload the page and try again. and then the post disapears. :

                Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (deebrasil_forum.tbz_recipients, CONSTRAINTtbz_recipients_user_id_foreignFOREIGN KEY (user_id) REFERENCEStbz_users(id) ON DELETE CASCADE) in /home/deebrasil/flarum/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php:117

                Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (deebrasil_forum.tbz_recipients, CONSTRAINTtbz_recipients_user_id_foreignFOREIGN KEY (user_id) REFERENCEStbz_users(id) ON DELETE CASCADE) in /home/deebrasil/flarum/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php:119

                @luceos Looks like the tbz_recipients user_id could not be null, so we always need a user ID, when I try to set it only to Admins group the error was show, the discussions.is_private was changed to true and when no entries could be created in recipients table, the post could not be seen by nobody.

                Directly in database:

                1. I changed is_private back to false
                2. Changed the recipients.user_id to nullable
                3. It all works now