Hi all,

Last year I was struggling to get some code to pass CI in
pypa/packaging. There were other issues, but one that suprised me most
was learning to ALWAYS use double quotes (") to get the code to pass the
lint check (type checking). Anything using single quotes (') as string
delimiters were not accepted as a STRING type.

I am not questioning the demands of the lint checker - rather - I am
offering my services (aka time) to work through core to make CPython
pass it's own (I assume) PEP recommendations or guidelines.

Again, this is not a bug-report - but an offer to assist with what I see
as an inconsistency.

If my assistance in this area is appreciated/desired I would appreciate
one or more core developers to assist me with managing the PR process.
Not for speed, but I would not want to burden just one core developer.

My approach would entail opening a number of related 'issues' for
different pieces: e.g., Lib, Modules, Python, Documentation where some
Lib|Modules|Python pieces might need to be individual 'issues' due to
size and/or complexity.

I do not see this as happening 'overnight'.

so-called simple things to fix:

In Documentation:

The return value is the result of the evaluated expression. Syntax
errors are reported as exceptions. Example:

x = 1

eval('x+1')
2 Change the text above to state eval("x+1") - assuming the lint process
would no longer accept eval('x+1') as proper typed syntax. And, then,
hoping this is still regarded as 'simple' make sure code such as
ctypes.util.find_library() is consistent, returning strings terminated
by double quotes rather than the single quotes as of now. >>> import
ctypes.util >>> ctypes.util.find_library("c") >>> 'libc.a(shr.o)' >>>
ctypes.util.find_library("ssl") >>> 'libssl.a(libssl.so)' Something more
"complex" may be the list of names dir() returns: >>> >>> import
sysconfig >>> dir(sysconfig)) ['_BASE_EXEC_PREFIX', '_BASE_PREFIX',
'_CONFIG_VARS', '_EXEC_PREFIX', '_INSTALL_SCHEMES', '_PREFIX',
'_PROJECT_BASE', '_PYTHON_BUILD', '_PY_VERSION', '_PY_VERSION_SHORT',
'_PY_VERSION_SHORT_NO_DOT', '_SCHEME_KEYS', '_USER_BASE', '__all__',
'__builtins__', '__cached__', '__doc__', '__file__', '__loader__',
'__name__', '__package__', '__spec__', '_expand_vars', '_extend_dict',
'_generate_posix_vars', '_get_default_scheme',
'_get_sysconfigdata_name', '_getuserbase', '_init_non_posix',
'_init_posix', '_is_python_source_dir', '_main', '_parse_makefile',
'_print_dict', '_safe_realpath', '_subst_vars', '_sys_home',
'get_config_h_filename', 'get_config_var', 'get_config_vars',
'get_makefile_filename', 'get_path', 'get_path_names', 'get_paths',
'get_platform', 'get_python_version', 'get_scheme_names',
'is_python_build', 'os', 'pardir', 'parse_config_h', 'realpath',
'scheme', 'sys'] >>> Regards, Michael

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/DZGPIUWBI75KMIG6VPRXKDZBN3L4MQKF/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to