Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

"All we are given is possibilities -- to make ourselves one thing or another." -- Ortega y Gasset


devel / comp.lang.python / Re: C API PyObject_CallFunctionObjArgs returns incorrect result

SubjectAuthor
o Re: C API PyObject_CallFunctionObjArgs returns incorrect resultChris Angelico

1
Re: C API PyObject_CallFunctionObjArgs returns incorrect result

<mailman.238.1646674400.2329.python-list@python.org>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=17428&group=comp.lang.python#17428

  copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail
From: ros...@gmail.com (Chris Angelico)
Newsgroups: comp.lang.python
Subject: Re: C API PyObject_CallFunctionObjArgs returns incorrect result
Date: Tue, 8 Mar 2022 04:33:07 +1100
Lines: 13
Message-ID: <mailman.238.1646674400.2329.python-list@python.org>
References: <MxWmaxK--3-2@tutanota.com>
<5ad962fc-1257-dd8d-96ab-541ae5bae2fa@mrabarnett.plus.com>
<Mx_KxMD--3-2@tutanota.com>
<CAPTjJmrcOZVwB0g+aScJ7V8svx1_iW-jeOsNUdN9LKKanGLQ+A@mail.gmail.com>
<Mx_Mknz--3-2@tutanota.com>
<CAPTjJmqh98fptjrpE5MzY56ZfztGTthL16PZ8PGyMr6uEY_qtQ@mail.gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
X-Trace: news.uni-berlin.de wE6n4Cx1qzVCgCKTK/+0xAp9+Lubu7RaSh7AvuwXUemA==
Return-Path: <rosuav@gmail.com>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=pass
reason="2048-bit key; unprotected key"
header.d=gmail.com header.i=@gmail.com header.b=pKkvTBDb;
dkim-adsp=pass; dkim-atps=neutral
X-Spam-Status: OK 0.001
X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '2022': 0.05; 'mar': 0.07;
'string': 0.07; 'subject:API': 0.07; 'subject:result': 0.09;
'chrisa': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris
angelico': 0.16; 'protocol,': 0.16; 'received:209.85.221.42':
0.16; 'received:mail-wr1-f42.google.com': 0.16;
'subject:incorrect': 0.16; 'subject:returns': 0.16; 'wrote:':
0.16; 'tue,': 0.19; 'to:addr:python-list': 0.20; 'library': 0.26;
'message-id:@mail.gmail.com': 0.32; 'header:In-Reply-To:1': 0.34;
'received:google.com': 0.34; 'from:addr:gmail.com': 0.35;
'received:209.85': 0.37; 'received:209': 0.39; 'list': 0.39;
'method': 0.61; "you'll": 0.73
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
h=mime-version:references:in-reply-to:from:date:message-id:subject:to;
bh=+GHTrzOZfbj1e9DMZHs4ULsupFkhfuoGgwM7+XYIHd4=;
b=pKkvTBDbJ8dArmzn8qy9A59Daj0okPJnDnNa2rRUr66job4PkMxJsmvZTFh7am5fZs
ImtWVLn1qj1g9N7Kaa1Ck+mLvp516W9IF/0sFVYslJ70uv+fvfqdMvELF3ADo3r4tUW1
E5d5+rM8LTejkueHUe8slQ2RqcedaXGZ5+30zvECkLM1/OEpo40RIWAS0GKi564AjgYn
8ZDyMdvYLZFWX5inP1e6yh8QSki+AZrpKNgN91sqeaES+YO+rL/gktjvombWZ+25rhC9
QIRLHE5NmswJM45sTKq1BQ24ofK7u1KT6XKJbDmeERbrhB8PyM8bMoVNnxFK6sqv884y
k+xw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=x-gm-message-state:mime-version:references:in-reply-to:from:date
:message-id:subject:to;
bh=+GHTrzOZfbj1e9DMZHs4ULsupFkhfuoGgwM7+XYIHd4=;
b=NlSyYzMcIL8qrImh2/EE9GA9/Qv3znXGd1q4KzJQ4hNWOcC0DplPDF3TS//9fSdmPo
/ca/7KyfjuJNkg6vDPu/ns3TR98ugye3s4z1IIqlbAzXRGs3Mei6ORjYw4nBVeXd2+G/
XPUGOC10KcIXY5YEd7sUiRZunCW0bZuCx/z1u1jQeiXF4TEyI+ytMAg03LpXaafZtVtU
yKv9G+v+mTSpb/D9Etda/p7J444rGB9NN1OnXe9ScCuKe4dC39dWkoV6YXw61vDAqiTE
JFGMgcJQE8sWkfk2NqGej3Dvd/8aHaB8VkvzfY3gTnwRPntiTjWgoPNzSw2KjJdg4ff1
kQ9A==
X-Gm-Message-State: AOAM531HXVAsokK3G9ck/ogb0oYwaRBK5Lhf/jNLpgXBrQGe0YqNrWF7
7MkN7I0Z5mnRezdNqA2rMZCgBOpZiYP7pZE6uWT9ppGefd8=
X-Google-Smtp-Source: ABdhPJymWIpKUIk/zKLnv2J9gKnz1kjYlna2AIC7xNbduKIhhCxvlHQTA6zipa7TiLCLLs1+Nrd4sSlrUVbgvcXU1Mg=
X-Received: by 2002:a5d:6a09:0:b0:1f0:6530:2e45 with SMTP id
m9-20020a5d6a09000000b001f065302e45mr8797753wru.160.1646674398794; Mon, 07
Mar 2022 09:33:18 -0800 (PST)
In-Reply-To: <Mx_Mknz--3-2@tutanota.com>
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <CAPTjJmqh98fptjrpE5MzY56ZfztGTthL16PZ8PGyMr6uEY_qtQ@mail.gmail.com>
X-Mailman-Original-References: <MxWmaxK--3-2@tutanota.com>
<5ad962fc-1257-dd8d-96ab-541ae5bae2fa@mrabarnett.plus.com>
<Mx_KxMD--3-2@tutanota.com>
<CAPTjJmrcOZVwB0g+aScJ7V8svx1_iW-jeOsNUdN9LKKanGLQ+A@mail.gmail.com>
<Mx_Mknz--3-2@tutanota.com>
 by: Chris Angelico - Mon, 7 Mar 2022 17:33 UTC

On Tue, 8 Mar 2022 at 04:13, Jen Kris <jenkris@tutanota.com> wrote:
>
>
> The PyObject str_sentence is a string representation of a list. I need to convert the list to a string like "".join because that's what the library call takes.
>

What you're doing is the equivalent of str(sentence), not
"".join(sentence). Since the join method is part of the string
protocol, you'll find it here:

https://docs.python.org/3/c-api/unicode.html#c.PyUnicode_Join

ChrisA

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor