Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect integer value: '' for column photo.accessible #14113

Open
SPiRiT369 opened this issue Apr 24, 2024 · 3 comments
Open

Incorrect integer value: '' for column photo.accessible #14113

SPiRiT369 opened this issue Apr 24, 2024 · 3 comments
Labels

Comments

@SPiRiT369
Copy link

Bug Description

I am a new friendica user and have just installed a new friendica server:

  • Friendica version: 2024.03
  • Mysql version: 10.11.6-MariaDB-0+deb12u1 (Debian 12).
  • PHP version: 8.2 (Running as a podman container with alpine linux)

I can publish posts, but when I attach images to the post I have the following error in the log file.
The image files are uploaded and displayed under Photos with permissions just for me, but the post itself fails and the New Post window doesn't disappear.

mysqli_sql_exception: Incorrect integer value: '' for column `friendica`.`photo`.`accessible` at row 1 in /friendica/src/Database/Database.php:646
Stack trace:
#0 /friendica/src/Database/Database.php(646): mysqli_stmt->execute()
#1 /friendica/src/Database/Database.php(763): Friendica\Database\Database->p()
#2 /friendica/src/Database/Database.php(1365): Friendica\Database\Database->e()
#3 /friendica/src/Database/DBA.php(417): Friendica\Database\Database->update()
#4 /friendica/src/Model/Photo.php(565): Friendica\Database\DBA::update()
#5 /friendica/src/Model/Photo.php(911): Friendica\Model\Photo::update()
#6 /friendica/src/Model/Photo.php(885): Friendica\Model\Photo::setPermissionForResource()
#7 /friendica/src/Model/Item.php(1076): Friendica\Model\Photo::setPermissionFromBody()
#8 /friendica/mod/item.php(200): Friendica\Model\Item::insert()
#9 /friendica/mod/item.php(79): item_insert()
#10 /friendica/src/LegacyModule.php(96): item_post()
#11 /friendica/src/LegacyModule.php(80): Friendica\LegacyModule->runModuleFunction()
#12 /friendica/src/BaseModule.php(233): Friendica\LegacyModule->post()
#13 /friendica/src/App.php(711): Friendica\BaseModule->run()
#14 /friendica/index.php(46): Friendica\App->runFrontend()
#15 {main}

I tried the "Check database structure" link in the admin menu. I don't know if it's relevant, but anyway it didn't write anything, and didn't help.

@SPiRiT369 SPiRiT369 added the Bug label Apr 24, 2024
@SPiRiT369
Copy link
Author

UPDATE:
After lots of tries to find what happened, it looks like enabling this option solves the problem:

image

@MrPetovan MrPetovan changed the title Incorrect integer value: '' for column friendica.photo Incorrect integer value: '' for column photo.accessible Apr 24, 2024
@annando
Copy link
Collaborator

annando commented Apr 24, 2024

I can imagine that it also works now when you disable the option again. It could be that we have got a problem with some default value.

@SPiRiT369
Copy link
Author

When I toggle it off again, the problem returns.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants