•  
      request #10196 Cannot display the blob of a file through the Git web viewer if there is no master branch
    Infos
    #10196
    Thomas Gerbet (tgerbet)
    2017-05-04 16:37
    2017-05-04 14:37
    10468
    Details
    Cannot display the blob of a file through the Git web viewer if there is no master branch
    If you will get a stack trace like:
    Fatal error: Call to a member function GetHash() on a non-object in /tmp/gitphp-tuleap/smarty/templates_c/%%D9^D98^D9848B98%%blob.tpl.php on line 23
    Call Stack
    # Time Memory Function Location
    1 0.0001 666376 {main}( ) ../index.php:0
    2 0.0429 7450496 GitPlugin->process( ) ../index.php:39
    3 0.0561 8863768 PluginController->process( ) ../gitPlugin.class.php:643
    4 0.0613 9043592 PluginController->executeViews( ) ../PluginController.class.php:236
    5 0.1069 10641720 PluginViews->display( ) ../PluginController.class.php:185
    6 0.1069 10642160 call_user_func_array ( ) ../PluginViews.class.php:60
    7 0.1069 10642408 GitViews->view( ) ../PluginViews.class.php:60
    8 0.1071 10648896 GitViews_ShowRepo->display( ) ../GitViews.class.php:234
    9 0.1074 10671584 GitViews_ShowRepo_Content->display( ) ../ShowRepo.class.php:108
    10 0.1206 10892368 GitViews_ShowRepo_Content->displayContent( ) ../Content.class.php:112
    11 0.1207 10892416 GitViews_ShowRepo_Content->displayRepositoryContent( ) ../Content.class.php:121
    12 0.1207 10892576 GitViews_GitPhpViewer->getContent( ) ../Content.class.php:144
    13 0.1207 10934224 GitViews_GitPhpViewer->getView( ) ../GitPhpViewer.class.php:40
    14 0.1209 10936184 include( '/usr/share/gitphp-tuleap/index.php' ) ../GitPhpViewer.class.php:65
    15 0.1301 11438904 GitPHP_ControllerBase->Render( ) ../index.php:157
    16 0.1365 11638328 Smarty->display( ) ../ControllerBase.class.php:346
    17 0.1365 11638424 Smarty->fetch( ) ../Smarty.class.php:1106
    18 0.1367 11642328 include( '/tmp/gitphp-tuleap/smarty/templates_c/%%D9^D98^D9848B98%%blob.tpl.php' ) ../Smarty.class.php:1256

    Reproduction steps:
    1. Create a a new Git repo
    2. Commit something in a branch that is not master and publish it
    3. Try the blob of a file of your commit
    SCM/Git
    All
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Empty
    Stage
    Empty
    Closed
    2017-05-04
    Attachments
    Empty
    References
    Referenced by request #10196

    Artifact Tracker v5

    rel #10116 9.8

    Follow-ups

    User avatar
    Thomas Gerbet (tgerbet)2017-05-04 16:37
    Fixed in the gitphp-tuleap starting version 0.2.5-13.

    • Status changed from Under review to Closed
    • Connected artifacts
    • Close date set to 2017-05-04