strinking / mawabot

A Discord selfbot to do tasks
MIT License
4 stars 2 forks source link

math.py interferes with standard math module #38

Closed aeshthetic closed 7 years ago

aeshthetic commented 7 years ago

the file mawabot/mawabot/cogs/general/math.py interferes with modules that depend on the math module found in the python standard library

raylu commented 7 years ago

this shouldn't be an issue in python3? can you describe the problem in more detail?

emmiegit commented 7 years ago

It shouldn't interfere, since the two imports are different.

import math # built-in library
from .math import a, b, c # math.py
aeshthetic commented 7 years ago

An issue occurred where the requests module attempted to import math and failed to do so within the directory, until I renamed math.py to mmath.py in order to test whether it was interfering with the import, and that's what seemed to be causing the issue. image image

emmiegit commented 7 years ago

Oh well. Can you rename math.py to calc.py (and adjust the header comment and stuff appropriately)? Thanks Abhijay.

aeshthetic commented 7 years ago

alright; thanks

raylu commented 7 years ago

I don't see requests in the traceback (nor do I think it's compatible with asyncio anyway). can you paste the relevant code and traceback instead of screenshots?

emmiegit commented 7 years ago

Fixed in 0f183a1