Unexpected error when when updating

Im trying to update from 5.5.103 to 5.5.113 and its showing me an error saying "FormatException: SyntaxError: Unexpected token ‘<’, "<!DOCTYPE “… is not valid JSON”. I checked /storage/logs/laravel.logs and its empty. Could anyone please guide me how do I update.


There may be more details in the web server error logs.

It should help to increase the PHP memory limit and try again, otherwise you can copy over the latest release files.

I have allowed 2GB memory. isnt that enough?

I would think so, are you able to confirm it in the health check in the app?

Here is the screenshot

Looks good, are they any errors in the web server error logs?

You may want to manually copy over the release.

There is nothing in the webserver error logs. I just checked laravel.log again and its asking me increase memory limit. I wonder 2GB isnt enough or what?
Also if I want to manually upload the latest release should I upload all files excluding .env file?

@david any thoughts on the memory error?

The release zip doesn’t have a .env file so it should’t be an issue. If you’re concerned you can backup the database and .env file.

Can you inspect the browser console, the actual error response message will be in the network tab.

After uploading the latest release its showing me error 500 when accessing invoice ninja.

Are there any details about the 500 in storage/logs or the web server error logs?

I reuploaded the latest release and everything seems to be fixed now. Latest version is installed but laravel.log still showing low memory error. I dont know why 2GB is not enough.


I’ve been working on this. It looks like our package size when uncompressed is now ~ 500mb. PHP and its zip function does not stream the files when unpacking, it pushes them all into memory by the looks of it which causes this out of memory issue.

I think I have a solution to change the package file from .zip to .tar as this appears to use much less memory. When this is ready, i’ll tag a new release.

1 Like

Getting Server error again when updating 5.5.114. Should I reupload again? Please fix the auto-update.


The fix is in .114, so the upgrade to .115 should not have the same issue.