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

Identify that information are from scancode or another tool #513

Closed
pombredanne opened this issue Feb 22, 2017 · 13 comments
Closed

Identify that information are from scancode or another tool #513

pombredanne opened this issue Feb 22, 2017 · 13 comments

Comments

@pombredanne
Copy link
Contributor

For results such as packages, there is no direct way to determine from the JSON that this came from scancode or another tool. This is implicit. We should have a way to list which tool provided data explicitly.

@pombredanne
Copy link
Contributor Author

A way to track which tools have touched a JSON could be to include some history/log so we know this has been touched by scancode, then aboutcode manager then something else, etc.

@patniharshit
Copy link

Hi, I am new here. Looking to contribute. Can you guide me on how to start with this issue?

@kartiksibal
Copy link

@pombredanne I'd like to resolve this, if no one is working on it.

If no one is. I was thinking of making a log file, wherein, whenever a tool makes changes to the JSON. There is an explicit record. Which can maybe be done, by creating a wrapper/decorator? I am not sure if I am expressing my thought correctly here. Please do share your approach.

Thanks :-)

@pombredanne
Copy link
Contributor Author

@patniharshit @kartiksibal I guess only one of the two of you should work on this.

@patniharshit what's your approach? did you start? @kartiksibal same question.

@kartiksibal Your approach sounds ok. Show me some code so I can understand what you mean exactly.

@kartiksibal
Copy link

@pombredanne Sure. I'll do that.

@kartiksibal
Copy link

kartiksibal commented Mar 7, 2017

@pombredanne I am thinking of making a @log, decorator, for this, which we can maybe add to the main functions of our tools. Wherein, it will basically write to a file whenever a change to JSON has been made, containing the name of the tool used.

Am I somewhere near, to what your expectations are with this? :-)

@patniharshit
Copy link

@pombredanne I didn't had any ideas in particular. I was hoping to get started here if somebody could guide me on what to do.
But since kartiksibal has something, I am cool with he going ahead with this.

@kartiksibal
Copy link

@patniharshit I think, what matters is coming up with an efficient solution to the problem, it doesn't matter who does it. We are here to improvise the product and learn. :-D

I'd love to know how you were thinking of approaching this issue. :-)

@pombredanne
Copy link
Contributor Author

@kartiksibal I can comment when I see some code.

@kartiksibal
Copy link

kartiksibal commented Mar 8, 2017

@pombredanne Sir, I have made a very minuscule change in /src/scancode/cli.py. Just when we dump the JSON data, I have added this . Is this somewhere on the lines of what you were expecting with this enhancement? :-)

@pombredanne
Copy link
Contributor Author

@kartiksibal you wrote:

I have made a very minuscule change in /src/scancode/cli.py. Just when we dump the JSON data, I have added this . Is this somewhere on the lines of what you were expecting with this enhancement? :-)

It is hard for me to review paste bins: do you mind make a PR for your change or attach or submit a patch instead?

@kartiksibal
Copy link

@pombredanne Apologies for the delay, got too engrossed in the project and I messed up a little here. 😅

@pombredanne pombredanne added this to the v3.0 milestone Oct 20, 2017
@pombredanne
Copy link
Contributor Author

This is closed in favor of tracking this in #211

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants