Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 370708

Summary: [status] "data.items.model.items is undefined" when acquiring Git Status for an empty clone
Product: [ECD] Orion Reporter: Tomasz Zarna <tomasz.zarna>
Component: GitAssignee: Szymon Brandys <Szymon.Brandys>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: libingw, susan
Version: 0.4   
Target Milestone: 0.4 RC1   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Tomasz Zarna CLA 2012-02-06 07:03:15 EST
Steps:
1. Init a new repo
2. Open "Git Status" for it
=> In the Console I can see:
TypeError: data.items.model.items is undefined
(undefined="[object Object]")
git-status-table.js (line 1151)
...
Comment 1 Susan McCourt CLA 2012-02-06 13:24:14 EST
I will take a look.  Not sure if this is commands or the specific command...
Comment 2 Susan McCourt CLA 2012-02-07 14:02:35 EST
I fixed the git-status side of this, by tightening up the visibleWhen so ensure all the properties expected in the href callback are there.

But I suspect if I actually tried to do anything else on this page, it would fail, since there are no branches.

I think that additionally we need to tighten up the visibleWhen for the git status command itself.  The link should probably not be appearing on the repo page at all until there's a branch defined?   Or something like that...Szymon will know....

Moving bug to Szymon.
Comment 3 Szymon Brandys CLA 2012-02-14 08:16:30 EST
(In reply to comment #2)
> But I suspect if I actually tried to do anything else on this page, it would
> fail, since there are no branches.

For new init'zed repos 'master' branch is created. It's active and you can't delete it, so we are safe to show Git Status href for these repos. One thing I noticed (again) is bug Bug 350012.