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

av pr create gets oom error when empty branch in stack #449

Open
msmanek-dd opened this issue Nov 6, 2024 · 3 comments
Open

av pr create gets oom error when empty branch in stack #449

msmanek-dd opened this issue Nov 6, 2024 · 3 comments

Comments

@msmanek-dd
Copy link

I have the following branch setup:

    * msmanek-criteria-10                         
    │                                             
    * msmanek-criteria-05                         
    │                                             
    │ * msmanek-criteria-03                       
    ├─┘                                           
    * msmanek-criteria-00                         
    │                                             
    * master                                      

Criteria 00, 05, and 10 all have commits and associated PRs. Criteria 03 does not.

When I try and stack sync with github, it get's the following error:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x0 pc=0x104fcc750]

goroutine 1 [running]:
github.com/aviator-co/av/internal/actions.UpdatePullRequestWithStack({0x105729ae8, 0x105d4fb00}, 0x1400047f170, {0x10572e2d8, 0x1400049a8c0}, {0x14000038ae0, 0x13})
        /home/runner/work/av/av/internal/actions/pr.go:900 +0xd0
github.com/aviator-co/av/internal/actions.UpdatePullRequestsWithStack({0x105729ae8, 0x105d4fb00}, 0x1400047f170, {0x10572e2d8, 0x1400049a8c0}, {0x14000252180?, 0x1?, 0x105729ae8?})
        /home/runner/work/av/av/internal/actions/pr.go:942 +0x78
main.init.func13(0x105cfec80, {0x105d4fb00?, 0x4?, 0x10521bfab?})
        /home/runner/work/av/av/cmd/av/pr_create.go:114 +0x49c
github.com/spf13/cobra.(*Command).execute(0x105cfec80, {0x105d4fb00, 0x0, 0x0})
        /home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:985 +0x834
github.com/spf13/cobra.(*Command).ExecuteC(0x105cfd860)
        /home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1117 +0x344
github.com/spf13/cobra.(*Command).Execute(...)
        /home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1041
main.main()
        /home/runner/work/av/av/cmd/av/main.go:110 +0x3c

Thankfully it at least pushes my PR to github. But, the nice handy comment on the top that shows the stack does not show up.

This is remedied by deleting criteria 03 branch locally and then running av stack tidy (PS: how does orphan work?)

Would love a fix though :)

@msmanek-dd
Copy link
Author

@jainankit -> now this one is a real bug that i think needs to be fixed

@jainankit
Copy link
Contributor

Thanks for reporting the issue. Seems like the issue with an empty branch, we will take a look.

@msmanek-dd
Copy link
Author

thank you :)

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

No branches or pull requests

2 participants