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

Pythonize pbench-log-timestamp #2027

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

zulcss
Copy link
Contributor

@zulcss zulcss commented Dec 8, 2020

Replace shell script with python script and add unit test.

Signed-off-by: Charles Short [email protected]

Replace shell script with python script and add unit test.

Signed-off-by: Charles Short <[email protected]>
@zulcss zulcss closed this Dec 8, 2020
@zulcss zulcss self-assigned this Dec 8, 2020
@portante
Copy link
Member

portante commented Dec 8, 2020

@zulcss did you mean to close this?

@zulcss zulcss reopened this Dec 8, 2020
Copy link
Member

@portante portante left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs to work with streams of data from a PIPE, and also needs a rebase.

@click.command()
def main():
""" Add timestamp to user input"""
stdin = click.get_text_stream("stdin").read()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be a generator so that stdin can be a pipe and each line read from the pipe is timestamped and written out.

Further, I think we'll want to make sure it is not using buffered I/O so that folks can inspect the output easily as it is generated.

Copy link
Member

@riya-17 riya-17 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@portante portante added Agent Code Infrastructure enhancement tools Of and related to the operation and behavior of various tools (iostat, sar, etc.) labels Dec 11, 2020
@portante portante added this to the v0.71 milestone Dec 11, 2020
@portante portante assigned portante and unassigned zulcss Jan 15, 2021
@portante
Copy link
Member

I'll own driving this change into the repository.

@portante portante changed the base branch from master to main January 28, 2021 22:05
@portante portante marked this pull request as draft January 28, 2021 22:14
@portante portante assigned webbnh and unassigned portante Feb 12, 2021
@portante portante modified the milestones: v0.71, v0.72 Apr 13, 2021
@portante portante removed this from the v0.72 milestone Sep 14, 2022
@portante portante added this to the v0.73 milestone Sep 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Agent Code Infrastructure enhancement tools Of and related to the operation and behavior of various tools (iostat, sar, etc.)
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

4 participants