Git Product home page Git Product logo

broote's Introduction

Hello, world! ๐Ÿ‘‹

I'm a passionate technologist with a strong background in programming, data analytics, and IT support. I love solving complex problems and learning new technologies.

Certifications ๐ŸŽ“

  • Google Project Management
  • Google IT Support
  • Google Data Analytics
  • Google IT Automation with Python

Skills ๐Ÿ’ป

  • Programming: Python (superpower), C/C++
  • Data Analytics: Spreadsheets, SQL, Python
  • IT Support: Troubleshooting and other IT duties

Projects ๐Ÿš€

I have more than 10 personal projects on GitHub, mostly in Python and a few in C/C++. Some of my Python projects have been distributed to PyPI.

Other Technologies ๐ŸŒ

  • Computer graphics with Blender 3D
  • GIMP for image editing and retouch
  • Inkscape for vector image generation

Keep exploring and happy coding!

broote's People

Contributors

sekgobela-kevin avatar

Watchers

 avatar

broote's Issues

'ctrl-c' does not quit program when using 'thread_runner'

'thread_runner' in some cases cannot be interupted by 'ctrl-c' on windows.
This has been happening on perock but did not happen on Linux Ubuntu.
I tried to reproduse it but it seems to work for now with KeyboardInterrupt being raised.

Update to perock v0.2.0

Perock v0.2.0 has fixed bug that resulted in wronly named methods of runner classes.
Broote runner classes also were based on same issue so it needs update.

Record transformer feature

Record from table is less likely to be used raw as it especially by connector.
There needs a way to tarnform record before connector can use to ensure it is in right format.
The resulting object does not have to be a record by can be another type suitable for that bruteforce activity.

Remember that 'broote' is general purpose meaning its not what it may be used for.
Tranforming record could make it simple to perform bruteforce eliminating the need to define unneccessay funtions.

Session function not called when passed to runner

session argument should resukt in session called when creating session but the function is set
directly without being called. The bug is result of using 'or' operator instead of 'and' which expects
session to both be method and function.

Here is the source of bug with _runner.py.

@classmethod
def create_session(cls):
    # Creates session object to use when connecting with target
    if self_._session != None:
        is_function = inspect.isfunction(self_._session)
        # 'and' should be replaced by 'or'.
        if is_function and inspect.ismethod(self_._session):
            return self_._session()
        return self_._session
    return super().create_session()

'after_attempt' argument be renamed to 'after_connect'

'after_attempt' is not that clear of whats going on and is mostly used by perock.
'after_connect' makes it clear that the function will be called after making connection with target.
Words like 'attack' and 'attempt' need to be avoided and be replaced with 'connect'.

Runner arguments are not tested

Tests added from previous commits dont test arguments passed to runner.
Runner arguments are very useful and dictate how runner functions and its results.
Current tests only tested methods of runner instances without arguments passed to them.

Integrated tests are also not added but thankfully the unittest does call .start() of runner instances.

RuntimeError: Event Loop is Closed

Using broote.async_runner().start() causes errors 'RuntimeError: Event Loop is Closed'.
This does not happen when using await broote.async_runner().astart().

Here is how start() is implemented by broote.async_runner.

def start(self):
    if self._event_loop:
        loop = self._event_loop
    else:
        try:
            loop = asyncio.get_running_loop()
        except RuntimeError:
            loop = asyncio.new_event_loop()    
    loop.run_until_complete(self._runner.run())
    if not self._event_loop:
        loop.close()

'connect' argument be ranamed to 'connector'

'connector' is more suitable as it shows that function or callable is expected which connects to target.
'connect' is more of like requiring boolean which determines if runner should connect to target.

Integration of forcetable exceptions

Since 'forcetable' is included with broote, also its exceptions need to.
Exception classes for forcetable need to be accessed through broote to avoid importing forctable.
Forcetable need to be made as if its part of broote with everything included.

Package `__all__` attribute was not defined.

__all__ helps in filtering symbols when importing everying using asterisk/start import.
This is neccessary for avoiding modules of broote from colliding with another package using broote.
webrute is facing problems since broote has overided one of its modules.
This is caused by that broote start import also imports modules as __all__ was not defined at package level.

Forcetable that is imported by broote also did not define __all__ which risk broote symbols being overiden.
exceptions.py modules are likely to collide since packages may likely contain them.
Forcetable 'exceptions' module is also accessible through broote which can cause problems.

Session raises exception if passed directly to runner

There seems to be problem with session if passed direcly without being wrapped to callable.
Broote attemps to wrap session into callable but there seems to be a problem with it.

Here is bug within _broote.py

# Performs transformation on some attributes
if self._session is not None:
    if not _util.is_method_function(self._session):
        self._session = lambda: self._session

Problem had todo with lambda expression which returns session attribute but overide the session attribute.
Its like session is a callable that returns itself , this related to references.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.