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

Loading spinner for graphql commands #703

Draft
wants to merge 60 commits into
base: charm-hack-week-main
Choose a base branch
from

Conversation

nramabad
Copy link
Contributor

@nramabad nramabad commented May 11, 2022

@codecov
Copy link

codecov bot commented May 11, 2022

Codecov Report

Base: 26.95% // Head: 26.79% // Decreases project coverage by -0.16% ⚠️

Coverage data is based on head (6f39b9c) compared to base (737e92e).
Patch coverage: 1.72% of modified lines in pull request are covered.

❗ Current head 6f39b9c differs from pull request most recent head 0f90a2f. Consider uploading reports for the commit 0f90a2f to get more accurate results

Additional details and impacted files
@@                   Coverage Diff                    @@
##           charm-hack-week-main     #703      +/-   ##
========================================================
- Coverage                 26.95%   26.79%   -0.17%     
========================================================
  Files                        41       41              
  Lines                      4529     4560      +31     
========================================================
+ Hits                       1221     1222       +1     
- Misses                     3165     3195      +30     
  Partials                    143      143              
Impacted Files Coverage Δ
api/api.go 3.75% <1.72%> (-0.02%) ⬇️
cmd/setup.go 47.10% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@nramabad nramabad changed the title Bubble exp 2 Loading spinner for graphql commands May 11, 2022
nramabad and others added 26 commits May 12, 2022 15:48
This is actually meant to be used in the CircleCI terraform provider,
which uses the CLI as a library. As such I'm not adding any
CLI-user-visible way of interacting with schedules as part of this.
* Test

* revert

* Adding PR template to CLI

* Moved file out of folder as many online sources state that this could be why this file is not working
Added to the template with our standard categories
cont changes

Fixed some of those changes up

Co-authored-by: corinnesollows <[email protected]>

Co-authored-by: corinnesollows <[email protected]>

Added in org id and made vcs and org name optional

Co-authored-by: corinnesollows <[email protected]>

Vendor

Add AppendRestPostHandler to clitest to be able to test rest endpoints. Add integration test flag to context to ensure that the rest client is used

Tests created

Co-authored-by: corinnesollows <[email protected]>

create context with VCS and org Name tests

test

Fix tests

Add API bindings for the pipeline scheduling REST API

This is actually meant to be used in the CircleCI terraform provider,
which uses the CLI as a library. As such I'm not adding any
CLI-user-visible way of interacting with schedules as part of this.

Added comments to changes and added functions

Attempting to add some new tests

test fixes

test

var

Fix API context tests

setup rest unit tests and make one succesful test

Add should handle an error request with createContextWithOrgID test
Also some markdown auto-formatting changes that got applied.
…late

remove "analytics events added" from PR template
* Org UUID support

* Made two methods

* Test for OrgId

* Comments
…eout-1

Increase http client timeout to 60s
…-decision

added make decision policy command
…ts (#741)

* update go.mod to declare go1.18 and updated CI to use Go 1.18 for tests
* use cimg/go:1.18 as go executor
* update golangci-lint for compat with go1.18
The original image was based on a deprecated version of Ubuntu. Testing on 1.17
The existing pull request is several months old, and as such there is a newer version of this (newer) image available now; let's use that instead.
The "restore cache" step is taking far, far too long compared to previous runs (total run 40-60 minutes or more, versus under 4 minutes previously). Consistent with our [documentation](https://circleci.com/docs/2.0/caching#managing-caches), since we've updated the Go version significantly, we should also update our cache keys so we can generate a new cache.
[EXT-242] Upgrade Golang version in Dockerfile
- Directly use golangci-lint in Docker in CI
- Remove unused lint scripts and Makefile targets
- Update Makefile to call golangci-lint directly for lint target (for local use)
- Update golangci-lint version from 1.35 to 1.46
- Remove golangmetalinter config, which was seemingly ignored, and add a config
  for golangci-lint
- Resolve one new lint warning from a test case
- Update formatting on files that were not properly formatted
corinnesollows and others added 30 commits July 4, 2022 11:47
* If user is attempting to follow a project that is not in bitbucket or git then warn them we do not support it

* Syntax fixes

* Error correcti0n
* [RT-603] Migrate CLI to use runner.circleci.com

Jira: [RT-603](https://circleci.atlassian.net/browse/RT-603)

As part of the incident remediation for [Runner UI & CLI making requests to the wrong domain](https://circleci.atlassian.net/l/c/ou0ABPYK), migrate the CLI to use `runner.circleci.com` for runner related operations. This is needed as the infra team starts to depreacate `www-proxy`.
Add Runner team to CODEOWNERS of runner packages
Command fix

Keep the header content type

Unused var removal

testing

Testing one more time

Test

Refactor info into using API info package to match project standards

reformat org info table with tablewriter

Use the same tablewriter solution from context.go to print out a more readable org-info table. Return nil instead of err in the penultimate line.

Refactor API to use client from root instead
This is in order to respect TLS rules for custom.

Fix tests

remove unused flag

assert output because my local env is borked
I'm just gonna push a bunch of stuff to the CI because my local env is broken for some reason.

I don't know why things are broken locally but meh
I'll squash all these later.

I don't know

Revert rest handler in tests
I don't know I'm shooting at straws right now.
I might just change the entire way we're doing things.
If this doesn't work because I'm sick of working with Gomega.

Refactor Info and write tests
Refactored the info stuff into it's own package because the CMD package
was getting to be too big. Wrote standard tests without Gingko as
it was unnecessary and causing problems.

Info Org error 500 message handling test.
Test the expected case where a 500 message returned.

Info API client tests
Write tests for happy path and bad path for info tests.

Add documentation to info api client stuff.

Add DS_Store to gitignore and remove the file.

Revert client changes.

Extract validator and write a test for it.

Refactor ServerURL parsing from config into method
Refactor the ServerURL implementations from the code into a method
found within the config itself since it seems like an appropriate
place to put the code.

Fix broken import references

use validator.Validator type

Settings ServerURL test
* stripped name from Policy CLI commands
* update policy agent and remove name from policy apis
* added metafile flag for policy decisions
…om-certs

[EXT-307] Use SkipInsecureVerify to HTTP call used by runner command
* Add prompt during policy push
* Add policy diff subcommand
* made policy path positional argument in policy decide and eval commands
Co-authored-by: Sagar Gupta <[email protected]>
* added examples for policy commands

* updated example
* Removing Codecov from CLI
URL was previously not suitable for cloning. This change will allow the user to copy and paste the command.
PR is switching to use the SSH for cloning
Co-authored-by: Marc O'Morain <[email protected]>
Co-authored-by: corinnesollows <[email protected]>
* Overwrote default cobra command help menu
* Added testing env var
… bubble-exp-2

# Conflicts:
#	api/api.go
#	go.mod
#	go.sum
* chore: Dynamically print flag options

Signed-off-by: Adam Harvey <[email protected]>

* fix: Forcibly sort keys to ensure consistency

Signed-off-by: Adam Harvey <[email protected]>

* fix: Alphabetical sorting of flag values

Signed-off-by: Adam Harvey <[email protected]>

Signed-off-by: Adam Harvey <[email protected]>
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

Successfully merging this pull request may close these issues.