<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/lldb/packages/Python/lldbsuite/support, branch users/nico/python-1</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>[lldb] Remove use of __future__ in python</title>
<updated>2023-08-14T21:14:48+00:00</updated>
<author>
<name>Alex Langford</name>
<email>alangford@apple.com</email>
</author>
<published>2023-08-11T21:46:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=e634c2f7149392b62e93c1b2b75701a12bc06721'/>
<id>e634c2f7149392b62e93c1b2b75701a12bc06721</id>
<content type='text'>
These were useful primarily for the Python 2 to 3 transition. Python 2
is no longer supported so these are no longer necessary.

Differential Revision: https://reviews.llvm.org/D157759
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These were useful primarily for the Python 2 to 3 transition. Python 2
is no longer supported so these are no longer necessary.

Differential Revision: https://reviews.llvm.org/D157759
</pre>
</div>
</content>
</entry>
<entry>
<title>[NFC][Py Reformat] Reformat python files in lldb</title>
<updated>2023-05-25T19:54:09+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2023-05-25T15:48:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=2238dcc39358353cac21df75c3c3286ab20b8f53'/>
<id>2238dcc39358353cac21df75c3c3286ab20b8f53</id>
<content type='text'>
This is an ongoing series of commits that are reformatting our Python
code. Reformatting is done with `black` (23.1.0).

If you end up having problems merging this commit because you have made
changes to a python file, the best way to handle that is to run `git
checkout --ours &lt;yourfile&gt;` and then reformat it with black.

RFC: https://discourse.llvm.org/t/rfc-document-and-standardize-python-code-style

Differential revision: https://reviews.llvm.org/D151460
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is an ongoing series of commits that are reformatting our Python
code. Reformatting is done with `black` (23.1.0).

If you end up having problems merging this commit because you have made
changes to a python file, the best way to handle that is to run `git
checkout --ours &lt;yourfile&gt;` and then reformat it with black.

RFC: https://discourse.llvm.org/t/rfc-document-and-standardize-python-code-style

Differential revision: https://reviews.llvm.org/D151460
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Remove uses of six module (NFC)</title>
<updated>2022-08-12T02:06:15+00:00</updated>
<author>
<name>Dave Lee</name>
<email>davelee.com@gmail.com</email>
</author>
<published>2022-08-05T19:35:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=56f9cfe30c4488aade888905bb6280ecb952a613'/>
<id>56f9cfe30c4488aade888905bb6280ecb952a613</id>
<content type='text'>
With lldb (&amp; llvm) requiring Python 3.6+, use of the `six` module can be removed.

Differential Revision: https://reviews.llvm.org/D131304
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With lldb (&amp; llvm) requiring Python 3.6+, use of the `six` module can be removed.

Differential Revision: https://reviews.llvm.org/D131304
</pre>
</div>
</content>
</entry>
<entry>
<title>[LLDB] Update inspect getargspec to getfullargspec</title>
<updated>2022-04-20T20:33:26+00:00</updated>
<author>
<name>Muhammad Omair Javaid</name>
<email>omair.javaid@linaro.org</email>
</author>
<published>2022-04-20T20:32:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=5341b5f8d3cec9a38867bc4745fd680946300b87'/>
<id>5341b5f8d3cec9a38867bc4745fd680946300b87</id>
<content type='text'>
This patch replaces getargspec with getfullargspec in funcutils.py.
getargspec has been deprecated by python 11x release. This is
important to run LLDB testsuite in Windows/Arm64 platform
where Python native will be available from python release onwards.

Note: getfullargspec is not available in python 2

Reviewed By: labath

Differential Revision: https://reviews.llvm.org/D121786
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch replaces getargspec with getfullargspec in funcutils.py.
getargspec has been deprecated by python 11x release. This is
important to run LLDB testsuite in Windows/Arm64 platform
where Python native will be available from python release onwards.

Note: getfullargspec is not available in python 2

Reviewed By: labath

Differential Revision: https://reviews.llvm.org/D121786
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb/test] Replace shlex.join with shlex.quote</title>
<updated>2021-10-29T11:42:06+00:00</updated>
<author>
<name>Pavel Labath</name>
<email>pavel@labath.sk</email>
</author>
<published>2021-10-29T11:33:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=b42d51ba9ad1f85e6b6f3508e6c2c4ab5ee22ac1'/>
<id>b42d51ba9ad1f85e6b6f3508e6c2c4ab5ee22ac1</id>
<content type='text'>
join is only available since python-3.8, but the all the interesting
magic happens in shlex.quote, which has been around since 3.3.

Use shlex.quote, and instead provide a home-grown helper function to
handle the joining.

Differential Revision: https://reviews.llvm.org/D112802
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
join is only available since python-3.8, but the all the interesting
magic happens in shlex.quote, which has been around since 3.3.

Use shlex.quote, and instead provide a home-grown helper function to
handle the joining.

Differential Revision: https://reviews.llvm.org/D112802
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb/Python] Remove unused imports (NFC)</title>
<updated>2020-01-03T00:55:09+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2020-01-03T00:14:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=d265c8bf0d1e6eed3c97dfb96f98712e5adc8bf7'/>
<id>d265c8bf0d1e6eed3c97dfb96f98712e5adc8bf7</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb/Python] Remove unused support file (NFC)</title>
<updated>2020-01-03T00:55:09+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2020-01-03T00:13:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=8580397f2e7d389940fbdd5575f26271df743aee'/>
<id>8580397f2e7d389940fbdd5575f26271df743aee</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldbsuite] Remove unused support files</title>
<updated>2019-10-29T23:56:59+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2019-10-29T23:26:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=5cc2e0651fed7764f02421db1ba1719a10f17d25'/>
<id>5cc2e0651fed7764f02421db1ba1719a10f17d25</id>
<content type='text'>
To the best of my understanding these files or their content is nowhere
referenced.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To the best of my understanding these files or their content is nowhere
referenced.
</pre>
</div>
</content>
</entry>
<entry>
<title>[testsuite] Drop characters that can't be decoded, restoring parity with Py2.</title>
<updated>2019-03-07T17:45:53+00:00</updated>
<author>
<name>Davide Italiano</name>
<email>davide@freebsd.org</email>
</author>
<published>2019-03-07T17:45:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=bd53e768d22c2c0e329bc08b2002ebd1d74ffaa6'/>
<id>bd53e768d22c2c0e329bc08b2002ebd1d74ffaa6</id>
<content type='text'>
Tests that check the output of `memory find` may trip over
unreadable characters, and in Python 3 this is an error.

llvm-svn: 355612
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Tests that check the output of `memory find` may trip over
unreadable characters, and in Python 3 this is an error.

llvm-svn: 355612
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix lldb-server test suite for python3</title>
<updated>2019-02-15T07:47:06+00:00</updated>
<author>
<name>Pavel Labath</name>
<email>pavel@labath.sk</email>
</author>
<published>2019-02-15T07:47:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=0af864b4b2af54a9c238df793e50b2f81f956b78'/>
<id>0af864b4b2af54a9c238df793e50b2f81f956b78</id>
<content type='text'>
Summary:
This patch finishes the python3-ification of the lldb-server test suite.
It reverts the partial attempt in r352709 to encode/decode the string
via utf8 before writing to the socket. This wasn't enough because the
gdb-remote protocol can sometimes (but not very often) carry binary
data, and the utf8 codec chokes on that. Instead I add utility functions
to the "seven" module for performing "identity" transformations on the
byte data. This basically drills back the hole in the python type system
that the string/bytes distinction was supposed to plug. That is not
ideal, but was the best solution of the alternatives I could come up
with. The options I considered were:
- make use of the type system to add type safety to the test suite: This
  required making a lot of changes to the test suite, since most of the
  strings would now become byte objects instead, and it was not even
  fully clear to me where to draw the line. One extreme solution would
  be to just use byte objects everywhere, as the protocol doesn't
  support non-ascii characters anyway. However, this appeared to be:
  a) weird, because most of the protocol actually deals with strings,
     but we would have to prefix everything with 'b'
  b) clunky, because the handling of the bytes objects is sufficiently
     different in PY2 and PY3 (e.g. b'a'[0] is a string in PY2, but an
     int in PY3).
- using the latin1 codec (which gives an identity transformation for the
  first 256 code points of unicode) instead of the custom
  bytes_to_string functions. This almost could work, but it was still
  slightly different between python 2 and 3, because in PY2 in would
  return a unicode object, which would then cause problems when
  combined with regular strings if it contained 8-bit chars.

With this in mind, I think the best solution for the time being is to
just coerce everything into the string type as early as possible, and
have things proceed indentically on both python versions. Once we stop
supporting python3, we can revisit the idea of using bytes objects more
prevasively.

Reviewers: davide, zturner, serge-sans-paille

Subscribers: lldb-commits

Differential Revision: https://reviews.llvm.org/D58177

llvm-svn: 354106
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Summary:
This patch finishes the python3-ification of the lldb-server test suite.
It reverts the partial attempt in r352709 to encode/decode the string
via utf8 before writing to the socket. This wasn't enough because the
gdb-remote protocol can sometimes (but not very often) carry binary
data, and the utf8 codec chokes on that. Instead I add utility functions
to the "seven" module for performing "identity" transformations on the
byte data. This basically drills back the hole in the python type system
that the string/bytes distinction was supposed to plug. That is not
ideal, but was the best solution of the alternatives I could come up
with. The options I considered were:
- make use of the type system to add type safety to the test suite: This
  required making a lot of changes to the test suite, since most of the
  strings would now become byte objects instead, and it was not even
  fully clear to me where to draw the line. One extreme solution would
  be to just use byte objects everywhere, as the protocol doesn't
  support non-ascii characters anyway. However, this appeared to be:
  a) weird, because most of the protocol actually deals with strings,
     but we would have to prefix everything with 'b'
  b) clunky, because the handling of the bytes objects is sufficiently
     different in PY2 and PY3 (e.g. b'a'[0] is a string in PY2, but an
     int in PY3).
- using the latin1 codec (which gives an identity transformation for the
  first 256 code points of unicode) instead of the custom
  bytes_to_string functions. This almost could work, but it was still
  slightly different between python 2 and 3, because in PY2 in would
  return a unicode object, which would then cause problems when
  combined with regular strings if it contained 8-bit chars.

With this in mind, I think the best solution for the time being is to
just coerce everything into the string type as early as possible, and
have things proceed indentically on both python versions. Once we stop
supporting python3, we can revisit the idea of using bytes objects more
prevasively.

Reviewers: davide, zturner, serge-sans-paille

Subscribers: lldb-commits

Differential Revision: https://reviews.llvm.org/D58177

llvm-svn: 354106
</pre>
</div>
</content>
</entry>
</feed>
