Database Schema - Not Up-To-Date! --> Options on a Host

20 views
Skip to first unread message

John Kerr

unread,
Sep 27, 2022, 4:58:57 PM9/27/22
to PartKeepr Users
Having the common issue with the initial pop-up message of "Your database schema is not up-to-date!".

Running v1.4.0 on my Internet Host (A2 Hosting) under a spare domain. Install went well, set PHP to v7.1. The issue is that the MariaDB is v 10.3.36 - while v10.1 seems to be the sweet-spot for running PartKeepr. I am unable to have multiple MySQL versions on the same server - so stuck with the v10.3.36

Is the pop-up message about the schema a warning or a real operating concern?

Thoughts??
John 

Acceptable Name

unread,
Sep 28, 2022, 5:57:48 PM9/28/22
to PartKeepr Users
Hi,

I tried to rebuild PartKeepr from git on Ubuntu 22.04 and I could not get this part to work.

composer require symfony/webpack-encore-bundle

GitHub changed its API key stuff and the last version of composer 1.X (which is 1.10.7) is not compatible with the new format.  I hit the "rate limit ... use GitHub token" stuff but the token format issue prevented me from getting any further.

I can rebuild PartKeepr from git on older versions of Debian but the "Your database schema is not up-to-date! Please re-run setup immediately!" stuff doesn't happen there.

On Ubuntu 22.04 I'm using mariadb-server 1:10.6.7-2ubuntu1.1 which is a patched 10.6.7.
For me the "Your database schema is not up-to-date! Please re-run setup immediately!" appears harmless "it just works".

Penultimately, the getSchemaQueries() method returns one too many queries to the getSchemaStatus() method causing getSchemaStatus() to return "incomplete".
Either the stuff that tests of this is bad or there might be uncommitted stuff, maybe from setup or something.

src/PartKeepr/CoreBundle/Services/SystemService.php

class SystemService extends ContainerAware
{
[...skip head...]
    /**
     * Checks if the schema is up-to-date. If yes, it returns "complete", if not, it returns "incomplete".
     *
     * @param none
     *
     * @return string Either "complete" or "incomplete"
     */
    protected function getSchemaStatus()
    {
        $queries = $this->getSchemaQueries();

        if (count($queries) > 0) {
            return 'incomplete';
        } else {
            return 'complete';
        }
    }
[...snip...]
Reply all
Reply to author
Forward
0 new messages