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

Error response from consul kv get should be written to stderr not stdout #2527

Closed
pheitman opened this issue Nov 22, 2016 · 1 comment
Closed
Milestone

Comments

@pheitman
Copy link

If you have a question, please direct it to the
consul mailing list if it hasn't been
addressed in either the FAQ or in one
of the Consul Guides.

When filing a bug, please include the following:

consul version for both Client and Server

Client: Consul v0.7.1
Server: Consul v0.7.1

consul info for both Client and Server

Client:

[Client `consul info` here]

Server:

agent:
	check_monitors = 0
	check_ttls = 1
	checks = 3
	services = 10
build:
	prerelease = 
	revision = 'a9455cd
	version = 0.7.1
consul:
	bootstrap = false
	known_datacenters = 1
	leader = false
	leader_addr = 192.168.2.35:8300
	server = true
raft:
	applied_index = 12488
	commit_index = 12488
	fsm_pending = 0
	last_contact = 38.772958ms
	last_log_index = 12488
	last_log_term = 2
	last_snapshot_index = 8218
	last_snapshot_term = 2
	latest_configuration = [{Suffrage:Voter ID:192.168.2.35:8300 Address:192.168.2.35:8300} {Suffrage:Voter ID:192.168.2.34:8300 Address:192.168.2.34:8300} {Suffrage:Voter ID:192.168.2.33:8300 Address:192.168.2.33:8300}]
	latest_configuration_index = 1
	num_peers = 2
	protocol_version = 1
	protocol_version_max = 3
	protocol_version_min = 0
	snapshot_version_max = 1
	snapshot_version_min = 0
	state = Follower
	term = 2
runtime:
	arch = amd64
	cpu_count = 2
	goroutines = 73
	max_procs = 2
	os = linux
	version = go1.7.3
serf_lan:
	encrypted = true
	event_queue = 0
	event_time = 14
	failed = 0
	health_score = 0
	intent_queue = 0
	left = 0
	member_time = 9
	members = 5
	query_queue = 0
	query_time = 1
serf_wan:
	encrypted = true
	event_queue = 0
	event_time = 1
	failed = 0
	health_score = 0
	intent_queue = 0
	left = 0
	member_time = 1
	members = 1
	query_queue = 0
	query_time = 1

Operating system and Environment details

CentOS 6.8

Description of the Issue (and unexpected/desired result)

consul kv get foo

returns

Error! No key exists at: foo

but it writes it to stdout and not stderr the way 'vault read secret/foo' does

Reproduction steps

Run 'consul kv get foo >/tmp/consul.out' and examine the contents of /tmp/consul.out

Log Fragments or Link to gist

Include appropriate Client or Server log fragments. If the log is longer
than a few dozen lines, please include the URL to the
gist.

TIP: Use -log-level=TRACE on the client and server to capture the maximum log detail.

@slackpad slackpad added this to the 0.7.2 milestone Nov 22, 2016
@kyhavlov kyhavlov modified the milestones: 0.8.0, 0.7.2 Dec 14, 2016
@slackpad slackpad modified the milestones: 0.8.0, 0.8.1 Mar 30, 2017
@slackpad slackpad modified the milestones: 0.8.1, 0.8.2 Apr 12, 2017
@slackpad
Copy link
Contributor

Fixed in #2548.

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

No branches or pull requests

3 participants