Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #197889

Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB

Path csiph.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
From Lawrence D’Oliveiro <ldo@nz.invalid>
Newsgroups comp.sys.mac.system, alt.os.linux, alt.comp.os.windows-11, comp.lang.python
Subject Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB
Date Thu, 20 Aug 2026 22:57:43 -0000 (UTC)
Organization A noiseless patient Spider
Lines 19
Message-ID <11680p6$3s8jk$1@dont-email.me> (permalink)
References <116673g$ptq$1@nnrp.usenet.blueworldhosting.com> <1166bch$39qqm$2@dont-email.me> <1167a7q$l51$1@nnrp.usenet.blueworldhosting.com>
MIME-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
Injection-Date Thu, 20 Aug 2026 22:57:43 +0000 (UTC)
Injection-Info dont-email.me; logging-data="4072052"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+3ye0/hyboEHTMzaqP3Cd0"; posting-host="d46d153320d65deb2c289b81dac51f44"
User-Agent Pan/0.165 (Kostiantynivka)
Cancel-Lock sha1:TnDOzDX1jOtu12hNoooJExVtars= sha256:rp+rG60JWgXXSQThaTRDkjVeS1yIz035ZcyIlEkOWoc= sha1:ogfscPPItlLzwlGHRNyPaPezi04= sha256:F/kxfxcvaadxyw+8I3LOJmvoYEInsSpKZfRSl/2+T0U=
Xref csiph.com comp.sys.mac.system:146458 alt.os.linux:83090 alt.comp.os.windows-11:33864 comp.lang.python:197889

Cross-posted to 4 groups.

Show key headers only | View raw


On Thu, 20 Aug 2026 08:32:58 -0800, Maria Sophia wrote:

> If I were to adapt your db_iter concept while keeping parameterized
> queries safe, I'd probably modify it to accept a parameters tuple
> like this:
>
> Python
> def db_iter(conn, cmd, params=(), mapfn=lambda x: x):
>     """Executes cmd with parameters and yields mapped results."""
>     for item in conn.cursor().execute(cmd, params):
>         yield mapfn(item)

Yes, fair enough. I prefer to use APSW rather than the SQLite binding
in the standard library; that seems nicer in some ways, providing more
flexibility in placeholders for parameter substitution
<https://rogerbinns.github.io/apsw/example.html#why-you-use-bindings-to-provide-values>.

I tend to fall out of the habit of using placeholder mechanisms,
because they don’t cope with more advanced cases.

Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-08-20 07:46 +0000
  Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Maria Sophia <mariasophia@comprehension.com> - 2026-08-20 08:14 -0800
  Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Maria Sophia <mariasophia@comprehension.com> - 2026-08-20 08:32 -0800
    Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Lawrence D’Oliveiro <ldo@nz.invalid> - 2026-08-20 22:57 +0000
      Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Maria Sophia <mariasophia@comprehension.com> - 2026-08-21 01:37 -0800
  Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Maria Sophia <mariasophia@comprehension.com> - 2026-08-21 01:54 -0800
  Re: PSA: A python script to clone your phone exactly, over Wi-Fi or USB Maria Sophia <mariasophia@comprehension.com> - 2026-08-23 12:36 -0800

csiph-web