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

A mission to produce a beautiful and comprehensible code base. (Documenting and Refactoring) #46

Merged
merged 10 commits into from
Jan 11, 2018

Conversation

KingAkeem
Copy link
Member

getweblinks.py module now uses two functions to validate urls instead of check if 'http' or 'https' exist in the url. Both functions use regular expressions to check the validity of a url, one is specially geared towards onion urls because it's what it will be used mostly for.
Also put integers into constant variables so there's no "magic constants"

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Updating my branch
To socket code and put it in side of a function. Also took out the
Controller module since it wasn't actually being used.
Removed code that wasn't being called and now using
regular expressions to validate urls
Instead of just checking if string contains http or https
Uses two functions which use regular expressions to match
valid urls. One funciton is specifically geared towards
onion address and the other is for general url validation.
@PSNAppz PSNAppz requested a review from agrepravin January 10, 2018 17:04
Copy link
Member

@PSNAppz PSNAppz left a comment

Choose a reason for hiding this comment

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

Approved.

@PSNAppz
Copy link
Member

PSNAppz commented Jan 11, 2018

@KingAkeem Let me know when this is ready to merge.

@KingAkeem
Copy link
Member Author

@PSNAppz I've already finished the documentation. I also added functions that use regular expression to validate urls. I'm going to work on fixing the flag that saves information to a json file, it's not giving an error but the json file is not being produced.

@PSNAppz
Copy link
Member

PSNAppz commented Jan 11, 2018

@KingAkeem Oh ok is there a test case for that flag?

@PSNAppz PSNAppz closed this Jan 11, 2018
@PSNAppz PSNAppz reopened this Jan 11, 2018
@KingAkeem KingAkeem closed this Jan 11, 2018
@KingAkeem KingAkeem reopened this Jan 11, 2018
@KingAkeem KingAkeem closed this Jan 11, 2018
@KingAkeem
Copy link
Member Author

Didn't mean to reopen it but there is a test case for the save file module

@PSNAppz
Copy link
Member

PSNAppz commented Jan 11, 2018

@KingAkeem Sorry I accidentally clicked comment and close. No need to close. This will be merged soon.

@PSNAppz PSNAppz reopened this Jan 11, 2018
@KingAkeem
Copy link
Member Author

Got you, what should the JSON file contain. It says {datatype: data}, but what kind of datatypes and data are you trying to save?

@PSNAppz
Copy link
Member

PSNAppz commented Jan 11, 2018

@KingAkeem See this PR

Using the -s flag will now save the results in a json file
within the current working directory.
@KingAkeem
Copy link
Member Author

The -s flag is now working correctly according to the pull request, should be ready for merge.

@KingAkeem KingAkeem changed the title Added more documenation and refactored code more A mission to produce a beautiful and comprehensible code base. (Documenting and Refactoring) Jan 11, 2018
@PSNAppz PSNAppz added this to the TorBot V1.1 milestone Jan 11, 2018
@PSNAppz
Copy link
Member

PSNAppz commented Jan 11, 2018

@KingAkeem Thank you for the PR. You did a great job. making this project a better one. Keep up the good work.

@PSNAppz PSNAppz merged commit 6870714 into DedSecInside:dev Jan 11, 2018
@KingAkeem
Copy link
Member Author

Thanks, I really appreciate. I just enjoy programming especially Python and this project has potential to be really interesting.

@PSNAppz PSNAppz removed the request for review from agrepravin January 11, 2018 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants