Page MenuHomePhabricator

PhabricatorDataNotAttachedException exception trying to add a 2nd user @mention to project description
Closed, ResolvedPublic

Description

I tried to edit https://phabricator.wikimedia.org/project/profile/1587/ Google-Code-In-2015 to add @Nemo_bis as an admin and on save got:

Unhandled Exception ("PhabricatorDataNotAttachedException")

Attempting to access attached data on PhabricatorProject, but the data is not actually attached. Before accessing attachable data on an object, you must load and attach it.

Data is normally attached by calling the corresponding needX() method on the Query class when the object is loaded. You can also call the corresponding attachX() method explicitly.

I was able to add @Aklapper to the project description; only @Nemo_bis causes the error

Event Timeline

jayvdb created this task.Dec 10 2015, 6:52 AM
jayvdb raised the priority of this task from to Needs Triage.
jayvdb updated the task description. (Show Details)
jayvdb added a project: Phabricator.
jayvdb added subscribers: jayvdb, Nemo_bis.
Restricted Application added subscribers: StudiesWorld, scfc, Aklapper. · View Herald TranscriptDec 10 2015, 6:52 AM
Aklapper triaged this task as Normal priority.Dec 10 2015, 9:29 AM

I can confirm this. Thanks for reporting.

Aklapper renamed this task from PhabricatorDataNotAttachedException exception modifying project to PhabricatorDataNotAttachedException exception trying to add a @mention to project description.Dec 10 2015, 9:30 AM
Aklapper set Security to None.

On my local installation that already happens when just trying to set the task summary to: @jan, @acko (both users exist).

[2015-12-10 10:29:11] EXCEPTION: (PhabricatorDataNotAttachedException) Attempting to access attached data on PhabricatorProject, but the data is not actually attached. Before accessing attachable data on an object, you must load and attach it.\n\nData is normally attached by calling the corresponding needX() method on the Query class when the object is loaded. You can also call the corresponding attachX() method explicitly. at [<phabricator>/src/infrastructure/storage/lisk/PhabricatorLiskDAO.php:174]
arcanist(head=master, ref.master=4a680c762b2e), phabricator(head=master, ref.master=20e6a
4200dbc), phutil(head=master, ref.master=0b37f385b8cd)
  #0 <#2> PhabricatorLiskDAO::assertAttachedKey(array, string) called at [<phabricator>/src/applications/project/storage/PhabricatorProject.php:121]
  #1 <#2> PhabricatorProject::isUserMember(string) called at [<phabricator>/src/applications/project/storage/PhabricatorProject.php:88]
  #2 <#2> PhabricatorProject::hasAutomaticCapability(string, PhabricatorUser) called at [<phabricator>/src/applications/policy/filter/PhabricatorPolicyFilter.php:478]
  #3 <#2> PhabricatorPolicyFilter::checkCapability(PhabricatorProject, string) called at [<phabricator>/src/applications/policy/filter/PhabricatorPolicyFilter.php:214]
  #4 <#2> PhabricatorPolicyFilter::apply(array) called at [<phabricator>/src/applications/policy/filter/PhabricatorPolicyFilter.php:84]
  #5 <#2> PhabricatorPolicyFilter::hasCapability(PhabricatorUser, PhabricatorProject, string) called at [<phabricator>/src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php:1317]
  #6 <#2> PhabricatorApplicationTransactionEditor::buildSubscribeTransaction(PhabricatorProject, array, array) called at [<phabricator>/src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php:1431]
  #7 <#2> PhabricatorApplicationTransactionEditor::expandSupportTransactions(PhabricatorProject, array) called at [<phabricator>/src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php:745]
  #8 <#2> PhabricatorApplicationTransactionEditor::applyTransactions(PhabricatorProject, array) called at [<phabricator>/src/applications/project/controller/PhabricatorProjectEditDetailsController.php:140]
  #9 <#2> PhabricatorProjectEditDetailsController::handleRequest(AphrontRequest) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:237]
  #10 phlog(PhabricatorDataNotAttachedException) called at [<phabricator>/src/aphront/handler/PhabricatorDefaultRequestExceptionHandler.php:32]
  #11 PhabricatorDefaultRequestExceptionHandler::handleRequestException(AphrontRequest, PhabricatorDataNotAttachedException) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:632]
  #12 AphrontApplicationConfiguration::handleException(PhabricatorDataNotAttachedException) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:242]
  #13 AphrontApplicationConfiguration::processRequest(AphrontRequest, PhutilDeferredLog, AphrontPHPHTTPSink, MultimeterControl) called at [<phabricator>/src/aphront/configuration/AphrontApplicationConfiguration.php:149]
  #14 AphrontApplicationConfiguration::runHTTPRequest(AphrontPHPHTTPSink) called at [<phabricator>/webroot/index.php:17]
jayvdb updated the task description. (Show Details)Dec 10 2015, 11:43 AM
Aklapper renamed this task from PhabricatorDataNotAttachedException exception trying to add a @mention to project description to PhabricatorDataNotAttachedException exception trying to add a 2nd user @mention to project description.Dec 10 2015, 11:48 AM

Odd that it doesn't happen in the upstream.

Nemo_bis removed a subscriber: Nemo_bis.Jan 17 2016, 9:00 PM
Restricted Application added a subscriber: Luke081515. · View Herald TranscriptJan 17 2016, 9:00 PM
Aklapper lowered the priority of this task from Normal to Low.Feb 9 2016, 10:15 PM

I think we probably fixed this by accident in 8463ad26 (or possibly earlier). The last few frames of the stack trace are in code that no longer exists at HEAD.

Aklapper closed this task as Resolved.Feb 18 2016, 11:20 AM
Aklapper claimed this task.

This problem is fixed since yesterday's update. Closing as resolved.