Re: Guide in Deskop Application Development in Python for newbies

2015-11-11 Thread Leonard Andrew Mesiera
Thank you sir @Chris Warrick for your great suggestion, even though I
really got overwhelmed by the things that I need to study to get this
project done. I'm really new to programming  so I havent heard or even
tried DJANGO, but on your suggestion, if thats what I need to get my
project done, that would I do. It would really take alot of time for me to
finish this project, but thank you man, I really appreciate your help

On Sun, Nov 8, 2015 at 5:22 PM, Chris Warrick  wrote:

> On 7 November 2015 at 15:44,   wrote:
> > How do you start building a desktop application in python? I mean where
> do I start? Besides installing python on your windows what else do I need,
> and any suggestion on how do I accomplish this project.
> >
> > Right now I really want to finish this beauty pageant judging system
> which requires to have a client and a server, client would be for the
> judges and a server that computes the scores from all the categories, (i do
> hope you get I want mean by that project). I just finished reading
> Headfirst Python and I really loving this language, so any help from all
> the great programmers here would be so great.
> > --
> > https://mail.python.org/mailman/listinfo/python-list
>
> This project requires two very different components, or one monolithic
> server.
>
> The first one is the server. It basically needs to talk to clients
> (via HTTP) and to a database. This is a trivial app to write in your
> favorite web framework, eg. Django [0]. Come up with a good database
> structure (read the excellent tutorial and documentation, should get
> you there), write some models. But you can’t write your views just
> yet. Because the views you write depend strictly on the client.
>
> For the client, you basically have two choices:
> (a) write a web application in Django;
> (b) use a GUI framework and make a standalone desktop application.
>
> If you choose option (a), you need to learn HTML/CSS and write the
> views for your Django application (or use a ready-made front-end
> framework, eg. Bootstrap [1]). This is the simplest choice, and it
> takes a lot of work away from you. Your users will use their favorite
> web browser to access the voting system, log in, and make their votes,
> and there is no special setup for them (apart from giving them
> credentials to access your app). Your Django views will use the
> built-in Django templating, forms, and is relatively simple to do
> (might even be doable in a weekend).
>
> Route (b) is much more complicated. To follow this route, you need to
> pick a GUI framework. There are also multiple options, I personally
> recommend PySide, but you could also try wxWidgets, pygobject or kivy.
> The web app side of things will require serializing data to JSON and
> writing a RESTful API, but there are ready-made solutions for many web
> frameworks [2].
> But most of those come with a catch: they usually make you produce
> ugly code, because they are wrappers around ugly C++ APIs. And then
> you need to write code to talk to your HTTP server. You can’t use the
> beautiful requests library, because it will block — so there’s more
> work ahead, unless you want your app to be unresponsive every time you
> talk to the server. For example, in Qt, you would need to use Qt
> networking capabilities (which work asynchronously within the event
> loop), or some other implementation that you can use asynchronously
> (eg. Twisted, but then you lock yourself to Python 2, which is bad, or
> threading, which has its limitations…)
> And then you need to distribute your app to your users. Which is
> already hard, because you need to coordinate Python, your GUI
> framework, and your app. Are your users on Windows, Linux, or OS X? If
> you have at least one person on a platform, you will need some sort of
> testing environment…
>
> And no matter which route you choose, you can’t do much without a
> Linux server, so there’s more learning to do.
>
> Sadly, developing big things is hard and requires a lot of knowledge —
> especially if you’re a one-man-band.
> Here’s a short list of skills you need, with a subjectively suggested
> implementation and ease of implementation:
>
> * understanding of the HTTP protocol (*)
> * web application development (Django *)
> * database schema writing (planning out the structure + Django ORM **)
> * app server setup (uWSGI + nginx + Linux ***)
> * database setup (PostgreSQL *** or something simpler[3])
> * Route A:
>   * HTML/CSS skills; a front-end framework (Bootstrap **)
> * Route B:
>   * RESTful APIs (Django REST Framework ***/* if you use OAuth)
>   * GUI framework (PyQt )
>   * talking to your server from within the framework (/*)
>
> [0]: https://www.djangoproject.com/
> [1]: http://getbootstrap.com/
> [2]: http://www.django-rest-framework.org/
> [3]: If this is going to be VERY small, you could go with a sqlite
> database, which requires zero setup, but which is not suited for

Re: Guide in Deskop Application Development in Python for newbies

2015-11-11 Thread Leonard Andrew Mesiera
Thank you sir @Chris Warrick for your great suggestion, even though I
really got overwhelmed by the things that I need to study to get this
project done. I'm really new to programming  so I havent heard or even
tried DJANGO, but on your suggestion, if thats what I need to get my
project done, that would I do. It would really take alot of time for me to
finish this project, but thank you man, I really appreciate your help

On Wed, Nov 11, 2015 at 8:38 PM, Leonard Andrew Mesiera <
leonardmesi...@gmail.com> wrote:

> Thank you sir @Chris Warrick for your great suggestion, even though I
> really got overwhelmed by the things that I need to study to get this
> project done. I'm really new to programming  so I havent heard or even
> tried DJANGO, but on your suggestion, if thats what I need to get my
> project done, that would I do. It would really take alot of time for me to
> finish this project, but thank you man, I really appreciate your help
>
>
> On Sun, Nov 8, 2015 at 5:22 PM, Chris Warrick <kwpol...@gmail.com> wrote:
>
>> On 7 November 2015 at 15:44,  <leonardmesi...@gmail.com> wrote:
>> > How do you start building a desktop application in python? I mean where
>> do I start? Besides installing python on your windows what else do I need,
>> and any suggestion on how do I accomplish this project.
>> >
>> > Right now I really want to finish this beauty pageant judging system
>> which requires to have a client and a server, client would be for the
>> judges and a server that computes the scores from all the categories, (i do
>> hope you get I want mean by that project). I just finished reading
>> Headfirst Python and I really loving this language, so any help from all
>> the great programmers here would be so great.
>> > --
>> > https://mail.python.org/mailman/listinfo/python-list
>>
>> This project requires two very different components, or one monolithic
>> server.
>>
>> The first one is the server. It basically needs to talk to clients
>> (via HTTP) and to a database. This is a trivial app to write in your
>> favorite web framework, eg. Django [0]. Come up with a good database
>> structure (read the excellent tutorial and documentation, should get
>> you there), write some models. But you can’t write your views just
>> yet. Because the views you write depend strictly on the client.
>>
>> For the client, you basically have two choices:
>> (a) write a web application in Django;
>> (b) use a GUI framework and make a standalone desktop application.
>>
>> If you choose option (a), you need to learn HTML/CSS and write the
>> views for your Django application (or use a ready-made front-end
>> framework, eg. Bootstrap [1]). This is the simplest choice, and it
>> takes a lot of work away from you. Your users will use their favorite
>> web browser to access the voting system, log in, and make their votes,
>> and there is no special setup for them (apart from giving them
>> credentials to access your app). Your Django views will use the
>> built-in Django templating, forms, and is relatively simple to do
>> (might even be doable in a weekend).
>>
>> Route (b) is much more complicated. To follow this route, you need to
>> pick a GUI framework. There are also multiple options, I personally
>> recommend PySide, but you could also try wxWidgets, pygobject or kivy.
>> The web app side of things will require serializing data to JSON and
>> writing a RESTful API, but there are ready-made solutions for many web
>> frameworks [2].
>> But most of those come with a catch: they usually make you produce
>> ugly code, because they are wrappers around ugly C++ APIs. And then
>> you need to write code to talk to your HTTP server. You can’t use the
>> beautiful requests library, because it will block — so there’s more
>> work ahead, unless you want your app to be unresponsive every time you
>> talk to the server. For example, in Qt, you would need to use Qt
>> networking capabilities (which work asynchronously within the event
>> loop), or some other implementation that you can use asynchronously
>> (eg. Twisted, but then you lock yourself to Python 2, which is bad, or
>> threading, which has its limitations…)
>> And then you need to distribute your app to your users. Which is
>> already hard, because you need to coordinate Python, your GUI
>> framework, and your app. Are your users on Windows, Linux, or OS X? If
>> you have at least one person on a platform, you will need some sort of
>> testing environment…
>>
>> And no matter which route you choose, you can’t do much without a
>> Linux server, so the