Trebek / pydealer

A simple package containing classes/methods for constructing decks of playing cards (standard 'French deck'). Could be used for a CLI game, or even a graphical game as well.
http://pydealer.rtfd.org
GNU General Public License v3.0
78 stars 19 forks source link

Can't use pydealer from Python3 #18

Closed MickaelG closed 9 years ago

MickaelG commented 9 years ago

I have installed pydealer using pip. It works well using python2. However, when I try to use it using python3, I have the following error: AttributeError: 'module' object has no attribute 'Deck'

import pydealer dir(pydealer) ['builtins', 'cached', 'doc', 'file', 'loader', 'name', 'package', path', 'spec']

Trebek commented 9 years ago

That's not the full error traceback message is it? If not, could you possibly post the whole message? That way I can actually see where the error is occurring.

I will also test the package myself. I usually use Python 2.7, and to be honest, haven't really tested this package too thoroughly with Python 3. I guess I'm going to have to do that (should have done that already).

You can also try downloading and installing the 'dev' version, which is fully functional, but may have a bug here or there. It is partially updated, and has been changed around quite a bit. It's possible that the issue you're having isn't an issue any more - or, conversely, that there are even more problems. I hope not though. If you want to try it out, click here to download it.

I haven't really worked on this package in a while - life getting in the way - but I will take a look at it, and see if I can iron this bug out. If I can't, maybe someone else can.

Edit: Actually, maybe I'll finally release the update for this package in the next day or two. Just looking through what I've got here, locally, and I think it's good enough to release. I have done quite a bit more work since that last dev push, including writing/generating full documentation for the package, using Sphinx. I think I'm going to try hosting the docs on readthedocs.

I don't want to update until I get this figured out though.

Trebek commented 9 years ago

Committed the latest changes to the dev branch. I think this is the push that I'll actually release. Try it out, see if it works for you. I tried it, using Python 3.2 (I know that is an old version, but it's what was on the computer I was using), and it seemed to work fine when I toyed with it. Passed all of the 98 tests, in the tests folder as well. I figure it should still probably work in the later versions of Py3.

If not, let me know. Sorry for my sloppy testing practices. This is just a hobby for me, and I am far from professional.

MickaelG commented 9 years ago

It works perfectly fine with last version. Thanks for the update and the useful software.

Trebek commented 9 years ago

Very glad to hear that! And you are welcome. Glad someone has found it useful in some way.

And actually, I should probably be thanking you, for bringing this to my attention, and giving me motivation to update this little package. I had neglected it for many months before the update. So thanks!