I am trying to write an app that connects to 2 databases at the same
time using components.
There is a component to handle logon forms to each db.
The index page has a LOAD for each db logon component and they load
fine.
But my form.accepts are failing because they seem to be getting the
"wrong" session.
Here is a little console print-trace showing session at the beginning
and end of each function (TSlogin and B1login), the first 2 calls are
from the index page:
B1login
request.vars: <Storage {}>
session: <Storage {'_Session__hash': '\xc8[\xd5\xc1#\xd8e
\x10\xe3\x06\x0ba\xddT
\x92m'}>
B1 logon form created
B1 form key = 4093a0a5-5fb0-45eb-a87c-69f864198f31
<Storage {'_formkey[B1login]': '4093a0a5-5fb0-45eb-
a87c-69f864198f31',
'_Session__hash': '\xc8[\xd5\xc1#\xd8e\x10\xe3\x06\x0ba\xddT\x92m'}>
so far so good, _formkey[B1login] added in
TSlogin
request.vars: <Storage {}>
session: <Storage {'_Session__hash': '\xc8[\xd5\xc1#\xd8e
\x10\xe3\x06\x0ba\xddT
\x92m'}>
TS logon form created
TS form key = adbe24ef-8515-4874-bc08-d8c11c5eb01d
<Storage {'_Session__hash': '\xc8[\xd5\xc1#\xd8e\x10\xe3\x06\x0ba\xddT
\x92m',
'_formkey[TSlogin]': 'adbe24ef-8515-4874-bc08-d8c11c5eb01d'}>
_formkey[TSlogin] added in, but note that _formkey[B1login] is not
there even though is the same session hash
TSlogin
request.vars: <Storage {'userid': 'denes', 'host': '192.168.0.88',
'_formkey': 'adbe24ef-8515-4874-bc08-d8c11c5eb01d',
'password': 'xxx', '_formname': 'TSlogin', 'onoff': 'logon'}>
session: <Storage {
'_formkey[B1login]': '4093a0a5-5fb0-45eb-a87c-69f864198f31',
'_Session__hash': '"\xb2\x1d7H\x1e\xc4\x9a)p{\x136\xfeu2'}>
TS logon form created
TS form key = bbbffb53-002d-4c9f-bf16-786366d21c86
<Storage {'_formkey[B1login]': '4093a0a5-5fb0-45eb-a87c-69f864198f31',
'_Session__hash': '"\xb2\x1d7H\x1e\xc4\x9a)p{\x136\xfeu2',
'_formkey[TSlogin]': 'bbbffb53-002d-4c9f-bf16-786366d21c86'}>
here TSlogin fails because session only has _formkey[B1login]