twiddli / happypanda

A cross platform manga/doujinshi manager with namespace & tag support
http://pewpew.moe/project/happypanda
Other
168 stars 32 forks source link

Start over #162

Closed twiddli closed 6 years ago

twiddli commented 7 years ago

Hello guys who still follow this project.

As you've noticed, I haven't been active at all these past months.

There are several reasons for that, one being school, another is lack of interest (I don't use HP that much anymore), and maybe the biggest of them all is Qt (the framework used for the GUI) and Python.

When I started working on HP, I was still new to Python and most of all Qt. This led to me making poor deci- ah whatever!

BOTTOMLINE

I want to start over

Zuescho commented 7 years ago

Great to hear from you again, yeah sad to hear you dont use it as much anymore. I'm myself used it more like an archive database than a reader but i always enjoyed it.

Do you now have more time besides school so you can get more dedicated to the start over?

twiddli commented 7 years ago

Yes, I'm all for starting over. Truth be told, I did actually work on HP since the last update where I tried to redo the internal DB structure and change the way galleries are handled. This, of course, was a nightmare and made me question why I was torturing myself like that, at which point I just snapped and said fuck it.

python_2016-10-02_23-55-19

I do actually want to create an application to manage my stuff, but if I'm going to do this, I'd need to start over, which is totally okay with me. I mean.. there is no rush.. lol.

Uhh about time, yes I have that. I tend to put all my time into a project If i get too invested. If it goes well, you'll see faster releases, if not, then... probably not as fast releases. The good thing is that I already got the internal DB structure down.

Zuescho commented 7 years ago

Looks great, i wish you the best luck with the project, i will keep a close eye. To my knowledge you are the last one to do this, so heads up

twiddli commented 7 years ago

just a correction, that screenshot is a shot of HP before i quit, not the new one.

DawgNewb commented 7 years ago

I was about to try ya programez today, but suddenly #162. Maybe I'll try again next release. No need to rush and take care :)

Indy27 commented 7 years ago

Maybe you should, you know, get help from people who're interested in working/coding/whatever this program. Faster releases and less bugs, I think.

ghost commented 7 years ago

@indy27 that is bit obvious though honestly.

glad you're still around Pewpews. I'm fine with you starting over, hope it goes well!

twiddli commented 7 years ago

@Indy27 Oh, thanks for the suggestion. Maybe I should host the project on Github, which makes it very easy for, you know, other people to chime in as well.

twiddli commented 7 years ago

@Indy27 though, if you're able to and want to help, that would be great.

Indy27 commented 7 years ago

Why not use ajax/js? Are they more difficult than coding in python?

twiddli commented 7 years ago

You mean using something like http://electron.atom.io/? Doable, but honestly no clue if it'll fix the issues I had with PyQt. Also, Python isn't difficult for me and has never been, just, stupid GUI library. We could totally try out using Electron if you're inclined on helping.

Indy27 commented 7 years ago

Maybe someone with js/css experience can help you (unfortunately I'm not one of them, and I tried python but it was just a pain in the ass; I only know little about html) but electron may look like something that could easily work with their auto-update and other stuff.

pandabuilder commented 7 years ago

Maybe separate the back end from the front end? That would open the possibility to use it with multiple clients, and a different language for the frontend.

twiddli commented 7 years ago

Yes, that's exactly what I'll be trying to do this time around.

emmauss commented 7 years ago

is it possible to make an android port? and also , isnt it difficult to make a gui app with c++, even with QT as a frontend?

twiddli commented 7 years ago

Hello, yes it will be possible to make an android client with the new HP. In the future, maybe, if someone hasn't already, I might make something for android. Well I like C++ more than Python so that's why.

emmauss commented 7 years ago

is the new HP any different from HPX, because you seem to reqularly update that, although you halted master when you opened this issue.

twiddli commented 7 years ago

HPX is the new HP :) I will eventually merge it over to the master branch when I've got a somewhat working version.

dillingercontrol commented 7 years ago

The biggest questions I have are: is HPX usable in a "production environment" and are the databases backward and forwards compatible?

twiddli commented 7 years ago

HPX database will not be backwards compatible with old HP database. On HPX "server" launch, data will automatically be pulled out from the old database and put in the new one. If you have a better idea or suggestion please tell me. The workflow for HPX is much better than it ever was for old HP. Continuous integration services/practices will be used to ensure a proper application before publishing. Though, as of now, HPX is still being worked on so nothing usable yet.

dillingercontrol commented 7 years ago

Importing HP's database to HPX is a good idea since HP will be depreciated in favor of HPX and it's updated database structure.

HP is robust and I haven't had any real trouble using it. I might try to do a few QoL fixes for HP while you work on HPX since it appears to be your primary focus.

rachmadaniHaryono commented 7 years ago

@Pewpews is new HPX will use sqlite3? becaues i have seen how complicated the database module. have you consider using http://docs.peewee-orm.com/en/latest/index.html? it is a bit simpler and similar to django model.

twiddli commented 7 years ago

@rachmadaniHaryono I did take a look at peewee before settling for SQLalchemy. Peewee does seem much simpler though. I will reevaluate and see if it's up for the job. Thanks.

rachmadaniHaryono commented 7 years ago

@Pewpews i don't know if i am the correct person, but can i suggest these things for the new happypanda

twiddli commented 7 years ago

@rachmadaniHaryono

rachmadaniHaryono commented 7 years ago

do you hate XML?

rather hate, i see python have json module which made it quite easy to convert from variable/class. there is also other such as yaml which is more readable and (c)pickle which is faster..

comparison json vs pickle

also if you are using flask, there is jsonify method which do the same

http://flask.pocoo.org/docs/0.11/api/#flask.json.jsonify

I wanted to avoid a project with hundreds of files but I see that some classes may have a need for a file of their own. I can start putting bigger classes in their own files if that's what you want.

i have seen the old happypanda files which have around 2000 lines. while IDE have easier overview for those file, editing and organizing those class can be quite nightmare (just like what you said to @emmauss).

i have played with old HP and try one class one file and i think i failed. even with that some sub module is needed and better naming convention is required.

see other cases where it fails

Yes happy_socketio is that fork. You mean installing and using the original module? I forked that module and added a few stuff so it was easier to incorporate it into the project.

if you are using virtualenv (and i recommend you should) you can install github fork using pip. you can also add github fork in requirements.txt. see this link http://stackoverflow.com/questions/30292039/pip-install-forked-github-repo

I did install flake8 but forgot all about it :( I will try and see if I can configure it to autorun on save.

fyi if you use git cli, you can add flake8 git hook see these links


other things:

i work on the same project which actually do the same thing. after my googling, i found out it is actually the routine practice on qt project. but if it is on usual python class, maybe make it as outer weak internal function(function with one leading underscore)?

see this case http://stackoverflow.com/q/326910

e.g. app_constants.py IMO is the correct one where there is little logic involved (even thought i'm not quite sure why some variable is changed despite the module name.)

but is settings.py correct?

twiddli commented 7 years ago

rather hate, i see python have json module which made it quite easy to convert from variable/class. there is also other such as yaml which is more readable, (c)pickle which is faster..

comparison json vs pickle

Just for clarification, XML is the message format clients and the server use to talk to eachothers with over TCP/IP. Using cpickle here is totally out of the question since clients might be created in a different language.

It's possible to replace XML with JSON/YAML though.

see other cases where it fails

I'm confused. I thought you wanted one class one file?

you can install github fork using pip. you can also add github fork in requirements.txt. see this link http://stackoverflow.com/questions/30292039/pip-install-forked-github-repo

Oh I didn't know this was possible. This does certainly make it a bit easier. I will do this.

fyi if you use git cli, you can add flake8 git hook see these links

Nice, thanks. Just what I needed.

is it required to have class/function in class/function?

Are you talking about distinguishing between private and public functions? Can you elaborate with an example from the project?

is it possible to differentiate where module which only contain global variable, and module which only have class/function? or is it correct to do so?

Yes I see what you mean, but am I not already doing that in the new project? Maybe you want exceptions_constants.py instead of exceptions.py? That's no issue at all. We can change that if you want. Also, I'm pretty sure constants.py will be the only one with not much logic involved.

simonrule commented 7 years ago

could you please in the new version add feature that will allow us to fetch from other sites like nhentai

twiddli commented 7 years ago

@simonrule Hi, implementing fetching from other sources has been on my TODO list for a long time. I will implement this for the initial release of the new happypanda.

ghost commented 7 years ago

Hello. Could you add support for reading metadata information from ComicRack, ComicBookLover and Doujin Renamer metadata formats?. Ability to write tags in above formats to the files would also be great.

rachmadaniHaryono commented 7 years ago

@simonrule do you want to test my nhen parser? happypanda/dev

simonrule commented 7 years ago

@rachmadaniHaryono yes that will be great