Page MenuHomePhabricator

Viewing any file (regardless of size) in Diffusion throws Unhandled Exception.
Closed, ResolvedPublic

Description

Viewing files from git repo in diffusion complains about "large files"

Currently, my storage.local-disk.path is set to null. If I set this to anything, the problem goes away.

arcanist[master] commit: 57f6fb59d73994d90cd94143787424ce0fdbf73b
libphutil[master] commit: f43291e99d36045bc459e5133454c0d8fd8768ea
phabricator[master] commit: e433a09fde9d5935a9703506487346b135ab52fd

EXCEPTION: (Exception) Unable to upload file: this server is not configured with any storage engine which can store large files. at [<phabricator>/src/applications/files/uploadsource/PhabricatorFileUploadSource.php:217]
arcanist(head=master, ref.master=57f6fb59d739), phabricator(head=master, ref.master=e433a09fde9d), phutil(head=master, ref.master=f43291e99d36)
#0 <#2> PhabricatorFileUploadSource::getChunkEngine() called at [<phabricator>/src/applications/files/uploadsource/PhabricatorFileUploadSource.php:128]
#1 <#2> PhabricatorFileUploadSource::writeChunkedFile() called at [<phabricator>/src/applications/files/uploadsource/PhabricatorFileUploadSource.php:47]
#2 <#2> PhabricatorFileUploadSource::uploadFile() called at [<phabricator>/src/applications/diffusion/query/filecontent/DiffusionFileContentQuery.php:73]
#3 <#2> DiffusionFileContentQuery::executeQuery() called at [<phabricator>/src/applications/diffusion/query/DiffusionQuery.php:88]
#4 <#2> DiffusionQuery::execute() called at [<phabricator>/src/applications/diffusion/conduit/DiffusionFileContentQueryConduitAPIMethod.php:42]
#5 <#2> DiffusionFileContentQueryConduitAPIMethod::getResult(ConduitAPIRequest) called at [<phabricator>/src/applications/diffusion/conduit/DiffusionQueryConduitAPIMethod.php:148]
#6 <#2> DiffusionQueryConduitAPIMethod::execute(ConduitAPIRequest) called at [<phabricator>/src/applications/conduit/method/ConduitAPIMethod.php:118]
#7 <#2> ConduitAPIMethod::executeMethod(ConduitAPIRequest) called at [<phabricator>/src/applications/conduit/call/ConduitCall.php:135]
#8 <#2> ConduitCall::executeMethod() called at [<phabricator>/src/applications/conduit/call/ConduitCall.php:85]
#9 <#2> ConduitCall::execute() called at [<phabricator>/src/applications/diffusion/query/DiffusionQuery.php:81]
#10 <#2> DiffusionQuery::callConduitWithDiffusionRequest(PhabricatorUser, DiffusionGitRequest, string, array) called at [<phabricator>/src/applications/diffusion/controller/DiffusionController.php:216]
#11 <#2> DiffusionController::callConduitWithDiffusionRequest(string, array) called at [<phabricator>/src/applications/diffusion/controller/DiffusionBrowseController.php:158]
#12 <#2> DiffusionBrowseController::browseFile(DiffusionBrowseResultSet) called at [<phabricator>/src/applications/diffusion/controller/DiffusionBrowseController.php:47]
#13 <#2> DiffusionBrowseController::handleRequest(AphrontRequest) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:237]
#14 phlog(Exception) called at [<phabricator>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:32]
#15 PhabricatorDefaultRequestExceptionHandler::handleRequestException(AphrontRequest, Exception) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:632]
#16 AphrontApplicationConfiguration::handleException(Exception) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:242]
#17 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:149]
#18 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phabricator>/webroot/index.php:17]

Event Timeline

Maybe I'm missing something obvious, You say if you set the local-disk path the error goes away. So what is the bug you are reporting, specifically, and how can we reproduce it.

set that field to null, and you can repro it. I did not get this error prior, and I should not be getting an "upload" error as I try to simply view a source file in my git repo via diffusion.

set that field to null, and you can repro it.

I can't reproduce this locally nor on this server. How are you configured to store files? What does "get this error prior" mean.

If you just updated Phabricator, how long has it been and did you restart PHP/Apache?

I had never setup anything for file storage in the past. It was never configured.
I've restarted php/apache many times, including immediately after I updated it as the documentation states to do.

I haven't tried to reproduce this, but the error about "store large files" seems out-of-place if the files are small.

b51a859636ac was recent, so maybe it did break something.

These files were well under 1MB FWIW.

Can you look and see what your limit is set to?

pasted_file (229×779 px, 44 KB)

/applications/view/PhabricatorFilesApplication/

(also maybe helpful, what PHP/OS you are running)

I don't see anything obvious in the code and can't fail it in my sandbox, but I am not the almighty @epriestley.

PHP 5.5.9-1ubuntu4.14 (cli) (built: Oct 28 2015 01:34:46)
Ubuntu LTS

mine looks identical to yours (app settings)

and also the culprit! hoo hoo hoo!!

I feel dumb because in my testing I set the field to literal null and not null.

Thanks for the report @perezd and sorry for my bad testing!