Skip to content

As a user, when I try to create a repo when using the /token command and I don't fill in the project fields I get an error #384

@texastoast

Description

@texastoast

Description

When using the /token command to add a repo, if your repo isn't listed you need to click the create repo button. When you do this, there are 3 fields:

  • Projects, which is marked as optional
  • Project name, also marked as optional
  • Repo name, required

If you leave both "optional" fields blank, you receive an error:

[error] GenServer #PID<0.677.0> terminating
** (ArgumentError) errors were found at the given arguments:

  * 1st argument: not a binary

    :erlang.binary_to_integer(nil)
    (slax 0.0.1) lib/slax_web/websockets/token.ex:80: SlaxWeb.Token.handle_payload/1
  ...

Filling in either of these optional fields allows the repo to be added. If you leave the Projects field blank and fill in the Project name field, that name appears in the "Projects" selector on future attempts.

It appears that this is an either/or option: either select an existing project or create a new project. However it is not clear from the UI that this is the case and it is also not clear what these project fields are referring to or how they are used.

Screenshot on 2024-03-27 at 11-52-09

Scenario: select existing project

  • Given I'm a user using the /token command to add a repo to Slax
  • When I select Create Repo in the Token Modal
  • Then I have the option to select an existing Project
  • And in the configuration modal I can select an existing Project from the Projects drop down
  • And I can enter the name of the repo where the Project exists
  • And once I submit I can select the added Repo in the Token Modal from the Repo drop down

Scenario: create new project

  • Given I'm a user using the /token command to add a repo to Slax
  • When I select Create Repo in the Token Modal
  • Then I have the option to create a new Project
  • And in the configuration modal I can enter a new Project name
  • And I can enter the name of the repo where the Project exists
  • And once I submit I can select the added Repo in the Token modal from the Repo drop down

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions