Hey Tim,

thank you for your early feedback!


> > (2) Syntax fixes and code-style.
> >
> > If I'm not wrong I saw mixed usage of tabs, 2-whitespace and
> > 4-whitespace indents. Of course, I can be wrong and we are using
> > 4-whitespaces everywhere, but I remember that I saw files using tabs
> > and 2-whitespaces.
> > It is boring work, but I can imagine, that people, who see this mixed
> > usage, might get frightened.
> > Also when it comes to code-style I would like to make everything well
> > ordered. Eg. splitting long lines and splitting multiple options, so
> > you can read the code without scrolling vertically too much.
>
> Remember that much of PyWin32 is automatically generated.  Automatically
> generated code is almost never pleasant to read.


Hmm, I never saw any generator for this. Instead I see that people are
doing additions manually already:
https://github.com/mhammond/pywin32/pull/1176
Do you know or can you look up, where this generator is? It would be great
to run this before build time.


> > (3) Self-explaining variable names
> >
> > Some variables are using abbreviations. Instead, I would like to use
> > full words, so the code is readable like a written book. Personally, I
> > like this a lot because the source actually tells you what it is doing
> > without any guesses.
>
> Again, much of PyWin32 is automatically generated from the Win32 C API.
> The names need to match the API, as terse as they may be.
>
> I am sympathetic to your plea, but renaming efforts like this are
> fraught with dangers.  It's awfully easy to cause duplicates or screw up
> the comments through an overactive search-and-replace.


I know, that's why it makes fun to clean it up a bit. I have the experiance
that I often hit superfluous variables in these situations.
So for whatever is not generated, I would suggets to make use of the
freedome of choosing meaningful variables.
However, this is my opinion, which does not mean that this should be really
done like that. :)


> > (6) Focusing more on Python3 compatibility
> >
> > The end of life of Python2 is at 2020 and therefore I would suggest
> > investing time into making the code compatible to Python3 asap.
>
> PyWin32 has been Python 3 compatible for many years.  To what are you
> referring?


Well, we need to run setup3.py for Python3 installation, which is
refactoring many files using lib2to3. With the end of Python2 I also expect
that this module will become dead.
These modules are not meant to be used forever, but creating a bridge over
a period of time where different standards are used.
And something that is already overdue is the use of print "bla" instead of
print("bla"). Python 2.7 already understands print("bla") without any
imports from the __future__ and since 2.6 is EOL, I would begin to fix that
at first.
_______________________________________________
python-win32 mailing list
python-win32@python.org
https://mail.python.org/mailman/listinfo/python-win32

Reply via email to