Fusio upgrade from 3.3.2 to 4.0.4 problem

31 views
Skip to first unread message

senasana

unread,
Feb 16, 2024, 4:38:33 AM2/16/24
to Fusio
Dear all
I try to migrate my fusio to version 4. Here the steps:
1. I clone existing fusio database 
2. setup fusio 4 with existing .env file, I edit the database connection to clonned version
3. run migrate command which is succesful
4. next, when copy all routes to be operations data by this command 
    php bin/fusio system:upgrade I got error message \fusiov4>php bin\fusio system:upgrade
Starting upgrade ...
Operation already exists get. (GET-/)
Added operation 187 (GET-/biologer/taxonomy)

In ExceptionConverter.php line 114:

  An exception occurred while executing a query: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'action
  ' cannot be null


In Exception.php line 28:

  SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'action' cannot be null


In Statement.php line 130:

  SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'action' cannot be null


system:upgrade
it seem system:upgrade command can't work if in my existing fusio only have
1 method (i.e GET method), while fusio 3 always create the other methods
although we dont used it. or maybe somebody has a similar experience when upgrading fusio from v3 to 4? regards
fusio error.JPG
fusio method table.JPG

Christoph Kappestein

unread,
Feb 16, 2024, 4:46:22 AM2/16/24
to Fusio
Hi Senasana,

ok, could you try to run a simple "DELETE FROM fusio_routes_method WHERE action IS NULL" before running the upgrade command and see whether this solves the problem?
I have not yet seen this error, in general we could also add this to the upgrade command but it would be interesting to see whether this solves the problem.

best regards
Christoph

senasana

unread,
Feb 17, 2024, 9:10:09 AM2/17/24
to Fusio
Hi Christoph
I try your suggestion, and Yes, its work, all my routes now migrated to "fusio_operation" table.  

Thanks for your help, hope this solution can help somebody else who will migrate its fusio to v4.

Christoph Kappestein

unread,
Feb 17, 2024, 9:17:04 AM2/17/24
to Fusio
Hi  Senasana,

ok great, I have also just added a fix which gets released with the 4.0.5 version so that this should be solved for future upgrades s.

best regards
Christoph
Reply all
Reply to author
Forward
0 new messages