-
Notifications
You must be signed in to change notification settings - Fork 974
feat(cli): add coder exp tasks list #19496
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
Conversation
4310e5d
to
b269f85
Compare
c1a203d
to
ea4b615
Compare
5d1bd5b
to
5d0a8cc
Compare
r.Route("/{user}", func(r chi.Router) { | ||
r.Use(httpmw.ExtractOrganizationMembersParam(options.Database, api.HTTPAuth.Authorize)) | ||
|
||
r.Get("/", api.tasksList) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review: This path was not conducive to listing other members tasks (e.g. owner).
Note: I don't think it is, but would appreciate validation if the above httpmw is needed for the list endpoint.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see httpmw.OrganizationMemberParam
in use in coderd/aitasks.go
so I think you're good 👍
5d0a8cc
to
5665d32
Compare
5665d32
to
9a5f639
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cli/exp_tasklist.go
Outdated
type taskListRow struct { | ||
Task codersdk.Task `table:"t,recursive_inline"` | ||
|
||
StateChanged string `table:"state changed"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: suggest naming StateChangedAt
or similar so that the semantics are clearer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this is relative, how about StateChangeAgo
?
Fixes coder/internal#892
Fixes coder/internal#896
Example output: