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

Add issue to a user-level project #1306

Closed
pbiology opened this issue Jul 1, 2020 · 10 comments
Closed

Add issue to a user-level project #1306

pbiology opened this issue Jul 1, 2020 · 10 comments
Labels
core This issue is not accepting PRs from outside contributors enhancement a request to improve CLI

Comments

@pbiology
Copy link

pbiology commented Jul 1, 2020

Problem

I'm trying to add issues and have them being automatically picked up by the project kanban board.
When adding an issue I get an error saying could not add to project: 'project name' not found

I'm using gh version 0.10.1 on macOS 10.14.6

Command

the command I'm running is this:
gh issue create -t "Issue title" -b "A lot of great extra info here" -l enhancement -p projectName

Expected vs actual behavior

Was expecting it to find my project but it seems not to. Should I specify a path to the project somehow?

@pbiology pbiology added the bug Something isn't working label Jul 1, 2020
@AliabbasMerchant
Copy link
Contributor

AFAIK, the -p flag accepts a project in the form octo-org/1

@mislav
Copy link
Contributor

mislav commented Jul 1, 2020

@pbiology Thanks for writing in!

When you specify -p "my project name", we lookup that name (in a case-insensitive way) among the names of all projects in that repository or org until we find a match. Did you ensure that you are specifying the exact project name as it appears in the web UI? (Again, the case does not matter.) Does your project exist in the same repo, or in the organization of the repo?

@AliabbasMerchant No, we only support passing project titles. We do not support passing a path such as octo-org/1.

@AliabbasMerchant
Copy link
Contributor

Oh. Then I think our web mode for issue create may not be able to assign the project properly (coz the query parameter accepted by GitHub is the project path, not the name).
I will look into it and create an issue & PR if needed.

@pbiology
Copy link
Author

pbiology commented Jul 1, 2020

@mislav yeah I'm spelling it correct and the project is in my own personal account, as is the repo. I do have the repo set to private, in case that might affect things.

I tried switching the repo and project to public (It was set to private), but I still get the same error

The project is called ghTest can be found here: https://github.com/pbiology?tab=projects

The exact command I ran, from the linked repo called gh_test:
gh issue create -t "Second Issue" -b "A lot of great extra info here" -l enhancement -p ghtest

@pbiology
Copy link
Author

pbiology commented Jul 2, 2020

OK, so I found the problem.

I created my project in the top level of my account.
When I instead made a project inside the repo that I had linked to, it worked as I expected.

My hopes of this however, would be that having top level projects would let me get an overview of how the various projects of for instance an organisation are going, and easily see what different team members are working on.

@mislav
Copy link
Contributor

mislav commented Jul 2, 2020

@pbiology Ah, I see! We don't support user-level projects at the moment, so I'll turn this ticket into a feature request. Thank you!

@mislav mislav added enhancement a request to improve CLI and removed bug Something isn't working labels Jul 2, 2020
@mislav mislav changed the title Can't find project when adding new issue Add issue to a user-level project Jul 2, 2020
@pbiology
Copy link
Author

pbiology commented Jul 2, 2020

@pbiology Ah, I see! We don't support user-level projects at the moment, so I'll turn this ticket into a feature request. Thank you!

Excellent. I tried it for an organisation, and here it does work as I would have expected.
Thanks for the help

@ghost
Copy link

ghost commented Mar 26, 2022

Contrary, this does not work for org level projects for me. An issue that is part of an org level project also only shows repo level projects in the edit mode (gh issue edit 123 -> Projects)

Edit: It does not show beta projects. "Old style" org level projects are visible. Already tracked here: #4547

@ghost

This comment was marked as spam.

@cli cli blocked ghost Mar 28, 2022
@samcoe
Copy link
Contributor

samcoe commented Jun 5, 2023

Closing this as we are no longer adding features for classic projects and non-classic projects are getting their own dedicated command shortly.

@samcoe samcoe closed this as not planned Won't fix, can't repro, duplicate, stale Jun 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core This issue is not accepting PRs from outside contributors enhancement a request to improve CLI
Projects
None yet
Development

No branches or pull requests

5 participants