Git Product home page Git Product logo

Comments (11)

Loumiakas avatar Loumiakas commented on June 21, 2024

Yes, I have experienced same problem and came to the same conclusion as you, it seems like one of the recent commits broke it.

from rfcat.

atlas0fd00m avatar atlas0fd00m commented on June 21, 2024

@roaldnefs this wouldn't have anything to do with the latest migration to support py3, would it?
could you please verify correct functionality in py2.7+?

thanks
@

from rfcat.

coylen avatar coylen commented on June 21, 2024

I was using python 2.7 when i had the problem indicated above

edit: sorry didn't notice comment above was directed at someone else

from rfcat.

roaldnefs avatar roaldnefs commented on June 21, 2024

PR #40 is indeed causing the problems. I've reverted changes in #46. Unfortunately, I do not have time to resolve #44 and maintain compatibility with Python 3.

@coylen @Loumiakas, my apologies for any inconvenience this may have caused...

from rfcat.

atlas0fd00m avatar atlas0fd00m commented on June 21, 2024

@roaldnefs has been putting in significant effort to push RfCat into the Py3 world. this is an oversight on both our parts, please accept both of our apologies. thank you for bringing it to our attention!

@roaldnefs what's the best path forward?

@coylen would you be willing to submit a very simple unittest PR? i've just created a basic unittest file you can add it to: tests/test_basics.py
all you'd need to do is create a new function/method for the RfCatBasicTests class, which imports rflib and asserts some test of behavior. i created a simple example in the file if you're not familiar with unittests.

from rfcat.

Loumiakas avatar Loumiakas commented on June 21, 2024

Hey @roaldnefs and @atlas0fd00m, I would be willing to volunteer myself to continue where @roaldnefs left off with regards to porting rfcat to Python 3 (if he doesn't mind, of coarse). Granted, it would take some time for me to get up to speed with regards to 'futurize' package and rfcat code base.

from rfcat.

atlas0fd00m avatar atlas0fd00m commented on June 21, 2024

@roaldnefs @Loumiakas @coylen
please check out my latest commit. i took a slightly different tack on @roaldnefs 's backout PR. let me know if everyone is happy.

from rfcat.

roaldnefs avatar roaldnefs commented on June 21, 2024

@Loumiakas feel free to continue where I left off! If you create a work in progress PR I might be able to help you if I can find some free time.

@atlas0fd00m, if I'm not mistaken your solution still creates the same problem (in Python 3). If you attempt to run bytes([value]) over a bytes value this causes a TypeError, e.g.:

# Python 3.6.7 
>>> from builtins import bytes
>>> value = bytes([1])
>>> value = bytes([value])
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'bytes' object cannot be interpreted as an integer

A possible solution might be to check for the value type in correctbytes().

from rfcat.

atlas0fd00m avatar atlas0fd00m commented on June 21, 2024

i'm not sure what you're referring to, @roaldnefs , do you have an example with more context? what i'm seeing looks like you're creating a "bytes" object, then handing that into the list constructor []. that isn't what correctbytes() is supposed to do.
what i committed works pretty well on py2.7 that i'm working on.

from rfcat.

roaldnefs avatar roaldnefs commented on June 21, 2024

@atlas0fd00m, you solution should work fine in Python 2.7, but there are still problems when using Python 3 caused by line 23 in rflib/bits.py. I've updated my previous comment for clarification.

from rfcat.

atlas0fd00m avatar atlas0fd00m commented on June 21, 2024

dammit. i promised myself not to miss those.
i left [] around a couple of them. try now, @roaldnefs

from rfcat.

Related Issues (20)

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.