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

Fail to create pull request #9987

Closed
skabashnyuk opened this issue Jun 11, 2018 · 2 comments
Closed

Fail to create pull request #9987

skabashnyuk opened this issue Jun 11, 2018 · 2 comments
Assignees
Labels
kind/bug Outline of a bug - must adhere to the bug report template. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code.
Milestone

Comments

@skabashnyuk
Copy link
Contributor

Description

Not able to create pull request.

Reproduction Steps

  1. Clone your github repository. Example: https://github.com/skabashnyuk/petclinic
  2. Checkout to some branch. Example fix
  3. Commit some changes.
  4. Try to create PR.
    pr_bug
@skabashnyuk skabashnyuk added the kind/bug Outline of a bug - must adhere to the bug report template. label Jun 11, 2018
@RomanNikitenko RomanNikitenko self-assigned this Jun 11, 2018
@RomanNikitenko RomanNikitenko added the status/in-progress This issue has been taken by an engineer and is under active development. label Jun 11, 2018
@skabashnyuk
Copy link
Contributor Author

skabashnyuk commented Jun 11, 2018

Couse of the issue is a fact that during panel initialization fired 4 PartStackStateChangedEvent simultaneously. Those 4 events generate 4 org.eclipse.che.plugin.pullrequest.client.workflow.Context with the wrong state inside because of this code from WorkflowExecutor class

  public void init(final VcsHostingService vcsHostingService, final ProjectConfig project) {
    final Optional<Context> contextOpt = getContext(project.getName());
    if (!contextOpt.isPresent()) {
      doInit(vcsHostingService, project);
    } else {
      checkVcsState(contextOpt.get())
          .then(
              new Operation<Boolean>() {
                @Override
                public void apply(Boolean stateChanged) throws OperationException {
                  if (stateChanged) {
                    invalidateContext(contextOpt.get().getProject());
                    doInit(vcsHostingService, project);
                  } else {
                    eventBus.fireEvent(new CurrentContextChangedEvent(contextOpt.get()));
                  }
                }
              });
    }
  }

are not adapted for a 4 sequentially events.

@vparfonov vparfonov added the severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code. label Jun 11, 2018
@RomanNikitenko
Copy link
Member

I reproduced the bug.
In my case I watch that SelectionChangedEvent is fired 4 times simultaneously.
pullreq_bug

@RomanNikitenko RomanNikitenko added status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. and removed status/in-progress This issue has been taken by an engineer and is under active development. status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. labels Jun 12, 2018
@RomanNikitenko RomanNikitenko added this to the 6.7.0 milestone Jun 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Outline of a bug - must adhere to the bug report template. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code.
Projects
None yet
Development

No branches or pull requests

3 participants