Hi!
Locklainn wrote:
I like this proposal. We were talking and had realized that we were not
collectively making design decisions. We DO make overall architectural
decisions, but the design aspect got left out. We seem to take the "GET
IT DONE" design process. We were talking about having some way to make
sure our design is sound before we just bust in and start coding. This
isn't to say to use the waterfall method. We should most certainly do
some iterations of the design. It is more or less making ourselves more
aware of needing to assist each other in a design before we each
independently start coding what we want to code.
Glad you like it :-)
Probably there is no such thing as a design being finished ever (hence
those tests and everything to make refactoring possible) ;-) But I think
we are on the same page here.
As for the waterfall model it of course depends on the size of the
waterfall. We are not waiting until OGP is finished and then implement
the library but we do it in parallel. And the iteration in this proposal
is sort of in going from highlevel to lowlevel. There is of course also
no reason why somebody shouldn't tell the progress on the list or at
some huddle and get some feedback or so. Then this can also be an
iteration over this component and level.
I think this is a great proposal. I would also like to add that we need
a way to determine what decisions need the round table for design. Right
now, it seems the round table is used for architectural dependencies
only. Is this the level we want to keep or should we all be discussing
more detailed decisions, like how a component might be coded.
I'd think the more comes over the mailing list the better and if there
comes up some point of deeper discussion we can do this in some
roundtable (what is the roundtable anyway? Enus' office hours? ). For
some bigger component or general direction we probably should discuss
this in a bigger round. Then the owner of the project (or maybe there
should be 2 co-owners for peer review?) can propose some solution. The
documentation part can of course also be done by a bigger group and the
brainstorming part on how to use it as well.
I think in general it would be good to post interface ideas always to
the list. So everybody knows what components are there and how to use them.
Thanks for your feedback!
-- Christian
Christian Scholz wrote:
Hi there!
Locklainn and I had a little discussion yesterday about a process we
don't yet have, which is about how we do design discussions etc.
So in order to kickstart this I thought I come up with some proposal
we can start to discuss.
So here it goes:
1. Identify a problem to solve.
This should not be too difficult as we have many to solve ;-)
2. Identify what's blocking a solution
like before handling packets we might want to have some component
which receives them.
3. Understand and document the problem domain
In order to come up with a good design/architecture everybody should
at least roughly understand the problem. That means we need to work
through the specs (if they are available) or pressure people to make
them or walk through code and write it down ourselves.
As said, maybe we don't need to go down to the smallest bit here but
e.g. for event queue stuff it might mean having some documentation
what roughly happens with that queue. What is sent, what is received,
when, why, what are the special cases we need to take care of (in
case of UDP it might be retries, acks and such).
4. Optional: Play around with some rough code to show how it could work.
This might be very valuable as for many people (like me) it's then
easier to understand and could be run with debug prints etc. to see
what's happening. Sort of like the stuff in examples/
5. Identify the components
Based on the example script or the spec we might identify some
components which we can model then. In case of the Event Queue it
might be some Queue class. It also might need some communications
endpoint.
6. Write an example
As I like the top-down/test-driven approach I usually start with
some example on how I would use that component, e.g. by adding it
to some example code based on the library we already have.
This makes the interfaces clearer IMHO.
It can also directly be written as a doctest (login.txt was the
one I wrote for implementing the login procedure which meant
dissecting the example script and "cutting" it into components.
The good thing about a doctest is that it also can be tested.
7. Implement all the components used in the doctest and break them up
into smaller components again. Basically the same method could
apply, so you repeat 5,6,7 until the component is small enough and
e.g. a UDP socket. It depends on how much you want to have low level
components in the end in how much you cut them into pieces.
For login we e.g. have some high level API in api.py, some medium
level is what is used in api.py (Credentials, IPlaceAvatar etc.)
and lowlevel would be the actual capabilities implementation and
networking code.
Of course while you do 7 you should add tests as it fits. It makes
always sense to write them first and implement the code then. At least
for me it makes it clearer what I am actually trying to write.
In the 5-6-7 loop you could even implement some mockup code first which
simulates the expected behaviour of the more low level components.
This can later be used in the test itself as well and thus can stay in.
As for writing doctests first it might make sense for others to grasp
at the beginning what you are doing and how it can be used. They can
even start using it right away if some mockup code is in place.
Probably regular reports on the list on what one is doing is also good
but then again we have the huddles for this. It might make sense
though to share some code examples or example uses.
So much for my quick'n'dirty process proposal.
As for coding guidelines, I would like to add:
- Follow PEP-8 http://www.python.org/dev/peps/pep-0008/ at least for
naming things.
- add docstrings wherever possible
- add doctests inside docstrings where it makes sense (e.g. when some
method is a bit more complex and you want to show how to use it).
That's actually all what comes to mind right now.
Talk to you later!
-- Christian
_______________________________________________
Click here to unsubscribe or manage your list subscription:
https://lists.secondlife.com/cgi-bin/mailman/listinfo/pyogp
--
Christian Scholz Homepage: http://comlounge.net
COM.lounge blog: http://mrtopf.de/blog
Luetticher Strasse 10 Skype: HerrTopf
52064 Aachen Video Blog: http://comlounge.tv
Tel: +49 241 400 730 0 E-Mail [EMAIL PROTECTED]
Fax: +49 241 979 00 850 IRC: MrTopf, Tao_T
neue Show: TOPFtäglich (http://mrtopf.de/blog/category/topf-taglich/)
_______________________________________________
Click here to unsubscribe or manage your list subscription:
https://lists.secondlife.com/cgi-bin/mailman/listinfo/pyogp