Properly import click echo
This commit is contained in:
parent
094ac8c3a8
commit
27279c9686
|
@ -30,7 +30,7 @@ import cli_lib.ansiprint as ansiprint
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: {}'.format(request_uri), err=True)
|
click.echo('API endpoint: {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
|
@ -27,7 +27,7 @@ import cli_lib.ansiprint as ansiprint
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
|
@ -28,7 +28,7 @@ import cli_lib.ansiprint as ansiprint
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
|
@ -26,7 +26,7 @@ import cli_lib.ansiprint as ansiprint
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
|
@ -29,7 +29,7 @@ import cli_lib.ansiprint as ansiprint
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
|
@ -32,7 +32,7 @@ import cli_lib.ceph as ceph
|
||||||
|
|
||||||
def debug_output(config, request_uri, response):
|
def debug_output(config, request_uri, response):
|
||||||
if config['debug']:
|
if config['debug']:
|
||||||
import click.echo
|
from click import echo
|
||||||
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
click.echo('API endpoint: POST {}'.format(request_uri), err=True)
|
||||||
click.echo('Response code: {}'.format(response.status_code), err=True)
|
click.echo('Response code: {}'.format(response.status_code), err=True)
|
||||||
click.echo('Response headers: {}'.format(response.headers), err=True)
|
click.echo('Response headers: {}'.format(response.headers), err=True)
|
||||||
|
|
Loading…
Reference in New Issue