From unknown Tue May 19 04:33:04 2026
X-Loop: owner@bugs.x2go.org
Subject: Bug#1200: [X2Go-Dev] Environment variables not set
Reply-To: Bruno CAPELETO <bruno.capeleto@abcreseau.com>, 1200@bugs.x2go.org
Resent-From: Bruno CAPELETO <bruno.capeleto@abcreseau.com>
Resent-To: x2go-dev@lists.x2go.org
Resent-CC: X2Go Developers <x2go-dev@lists.x2go.org>
X-Loop: owner@bugs.x2go.org
Resent-Date: Wed, 16 Aug 2017 09:20:02 +0000
Resent-Message-ID: <handler.1200.B1200.1502875077374@bugs.x2go.org>
Resent-Sender: owner@bugs.x2go.org
X-X2Go-PR-Message: followup 1200
X-X2Go-PR-Package: x2goserver
X-X2Go-PR-Keywords: 
Received: via spool by 1200-submit@bugs.x2go.org id=B1200.1502875077374
          (code B ref 1200); Wed, 16 Aug 2017 09:20:02 +0000
Received: (at 1200) by bugs.x2go.org; 16 Aug 2017 09:17:57 +0000
X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on
	ymir.das-netzwerkteam.de
X-Spam-Level: 
X-Spam-Status: No, score=-2.6 required=3.0 tests=BAYES_00,DKIM_SIGNED,
	DKIM_VALID,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,URIBL_BLOCKED autolearn=ham
	autolearn_force=no version=3.4.1
Received: from localhost (localhost [127.0.0.1])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTP id 698E55DAD0
	for <1200@bugs.x2go.org>; Wed, 16 Aug 2017 11:17:51 +0200 (CEST)
X-Virus-Scanned: Debian amavisd-new at ymir.das-netzwerkteam.de
Received: from ymir.das-netzwerkteam.de ([127.0.0.1])
	by localhost (ymir.das-netzwerkteam.de [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id GFeTHpvBkgTf for <1200@bugs.x2go.org>;
	Wed, 16 Aug 2017 11:17:45 +0200 (CEST)
Received: from mail-yw0-x22a.google.com (mail-yw0-x22a.google.com [IPv6:2607:f8b0:4002:c05::22a])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTPS id ACC875DACD
	for <1200@bugs.x2go.org>; Wed, 16 Aug 2017 11:17:44 +0200 (CEST)
Received: by mail-yw0-x22a.google.com with SMTP id p68so19102926ywg.0
        for <1200@bugs.x2go.org>; Wed, 16 Aug 2017 02:17:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=abcreseau-com.20150623.gappssmtp.com; s=20150623;
        h=mime-version:in-reply-to:references:from:date:message-id:subject:to
         :cc;
        bh=HdGT1dpNXnFSPHGC4fGm2BDn/fBBoTwJCwgsPwrQYkY=;
        b=LZE7oXaXJ4zwhipbGYw94lMac48PJStIUfpjydfvhR5WUY+KPvYPI7I9fi9BEk4fwA
         wIx6JZuRe/vCkhmZ2486W0eull0oo2rK7M2P5nxcABr5JS6yd26pccvoha5iwuBa1JvH
         2DilaeW2G92MEJfsxRyP4cg5qhDI8mgUkD4Sm0HCGDWq3st/zHLOcT+asD867OoUP4IV
         2mtpI5JdBG+hw86AI4IMXSRF3JRHzSRIC8/IROzN+TeqgyzInoDWhN14DCoBNSf+KR8m
         fkZP8GnPDfUEeLiCuVX+m8IH1c4YX5dXHg3AFdnxZZ/mZkggxQSshOKXKNttDhY0lCww
         41aw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:mime-version:in-reply-to:references:from:date
         :message-id:subject:to:cc;
        bh=HdGT1dpNXnFSPHGC4fGm2BDn/fBBoTwJCwgsPwrQYkY=;
        b=bR80P8nk0wlOcd/G2Vu5o3ofQwU2x4PcAmvF14BRpd8a9Sg8i1H0U4nJ3Ls8e5ZhIj
         SXIWDiUIZwM4023K7JuW59RRXz9jdgPLSzyFCFOhtFm5HxWfwfFpV0pIcwW0k1wtqnVQ
         x8f16crvUzM6CdEpG/KNoCFl5tDjqKVCCh0myg7VE8wHTtajmXy7m0r/5RBUtxRRlNng
         TqDQSM9rAqRledZSikiww+M4TPMrLkYe/a4RdIFyJ/U82csv8b+raUF7AyO+lMPW93Jj
         1Yx8zOwRw4/tpbZN6+0F6ETmM2Alp1jINm2nbae6cRYj6V+mGAbZG4fZWbthmxNfAkYs
         J0jw==
X-Gm-Message-State: AHYfb5iG3k/3ROGH/g7Q9SoLsML3yo/Conpwu+Si2S+HVRvmSR2aTQe8
	oeBzxM13gB1Xym6U0dG1bJbSrAEHlCOK0Cc=
X-Received: by 10.37.173.200 with SMTP id d8mr813904ybe.273.1502875063042;
 Wed, 16 Aug 2017 02:17:43 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.129.60.10 with HTTP; Wed, 16 Aug 2017 02:17:42 -0700 (PDT)
X-Originating-IP: [78.233.84.236]
In-Reply-To: <5e2e5f4b-b445-09d5-1834-ad53f845a03e@ionic.de>
References: <CABa3fk4QCDwjuqZbXPzMWDqd0vrpJGVYAEZzm1VBKoAis8n=zg@mail.gmail.com>
 <5e2e5f4b-b445-09d5-1834-ad53f845a03e@ionic.de>
From: Bruno CAPELETO <bruno.capeleto@abcreseau.com>
Date: Wed, 16 Aug 2017 11:17:42 +0200
Message-ID: <CABa3fk7jruJbtVzhC=zUd1gcVwJr88inRvX-z8e9N_gkLZ9tew@mail.gmail.com>
To: Mihai Moldovan <ionic@ionic.de>
Cc: 1200@bugs.x2go.org
Content-Type: multipart/alternative; boundary="f403045ec22c465fb60556db5e33"

--f403045ec22c465fb60556db5e33
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

2017-08-11 5:29 GMT+02:00 Mihai Moldovan <ionic@ionic.de>:

> Control: reassign -1 x2goserver 4.0.1.20
>
> First of all, x2goserver 4.0.1.20 actually is the correct stable release.
> 4.1.0.0 are the current nightly releases.
>
> I personally don't care much about what version is tested, but knowing
> whether
> there's a difference in behavior between the stable and nightly versions =
is
> certainly helpful.
>

Same issues with both versions.


>
>
> On 08/10/2017 12:24 PM, Bruno CAPELETO wrote:
> > Package: <x2goserver> Version: <4.0.1.20-0x2go1+git20170412.
> 1125+9.main.1>
> >
> > # uname -a Linux mtcie1 4.9.0-3-amd64 #1 SMP Debian 4.9.30-2+deb9u1
> > (2017-06-18) x86_64 GNU/Linux
> >
> >
> >
> > The below bugs are most probably related to each other, that's why I op=
en
> > one case for all of them.
> >
> > The issues are the following : I want to use the French software Laurux=
,
> > which is based on Gambas interpreter, via a x2go session running on a
> Debian
> > 9 server running LXDE (same issues seen on an Ubuntu server, x2goserver
> > version =3D 4.0.1.20-0~1125~ubuntu14.04.1)..
> >
> > As a prerequisite, the software is installed on the server and runs wel=
l
> on
> > a local session.
> >
> > 1. Whatever the client (Windows or Linux 4.0.3.1-4), the local
> environment
> > variables are not set properly and the software - which needs French
> > localization - crashes. That could be "solved" the following way :
> > /etc/x2go/Xsession :
> >
> > ... LANG=3Dfr LC_ALL=3Dfr_FR.UTF-8 export LANG export LC_ALL ...
> >
> > That seems to be a revival of older bugs, but it is definitely still
> here.
>
> How exactly did you set the locale?
>
> The "Debian way" would be to run dpkg-reconfigure locales as root and
> select the
> desired locale(s) to generate and then select the default one.
>

That is exactly the way  I set the locales.

>
> /etc/environment should not contain any locale settings.
>

/etc/environmnent is empty


>
> LANGUAGES and especially LC_ALL should normally not be set. LANGUAGES is =
a
> GNU-only list of fallback locales. LANG is the preferred way to set the
> locale,
> since it's being used if all of the LC_* env variables are empty.
> "dpkg-reconfigure locales" will do the right thing=E2=84=A2.
>

I confirm $LANGUAGES and $LC_ALL are not set on a local session.


>
>
> > 2. At the start of a new session, one gets a windows with an error
> message
> > "No session for pid ..." ; that bug has already been reported several
> times
> > in x2go bug tracking and marked as solved. Actually it is not on my
> brand new
> > system.
>
> What session are you starting exactly? I cannot find the string "No
> session for
> pid" in x2goserver's source code. Not sure what to do with this.
>

I found out it is a reported bug related to LXDE : cf
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D864402


>
>
> > 3. The single application mode does not work with some of the
> applications,
> > including that Laurux / Gambas. For example it works with
> /usr/bin/leafpad,
> > but /usr/bin/libreoffice makes the x2go session crash.
>
> That's certainly possible. The most likely cause, as Uli explained, is
> that the
> command daemonizes itself right after launching it. This leads to the X2G=
o
> scripts assuming that the program exited and subsequently also terminatin=
g
> the
> session. We've seen such behavior every now and then and worked around it=
.
>
> However, it looks like x2goagent is crashing when you start libreoffice i=
n
> your
> case. That shouldn't happen. My gut feeling is that this might be another
> GTK3
> incompatibility.
>
> I could try to reproduce this in a clean stretch VM.
>

Perfectly reproducible in my case on 2 installations.


>
>
> > 4. The mouse double clic does not work in a x2go session, but only -
> within
> > the Gambas software (works well for example when launching an
> application)
> > and only - when the x2go client is running in a Windows environment (no
> > problem when client in a Linux environment)
>
> That sounds like Gambas is doing something funny, though. As far as I was
> able
> to gather, Gambas seems to be using Qt5 as its drawing toolkit.
>
> The package qtbase5-examples should contain a binary at
> /usr/lib/x86_64-linux-gnu/qt5/examples/widgets/widgets/
> mousebuttons/mousebuttons
> which spits out received mouse events.
>
> Can you try that - especially with double clicking - and see what it
> outputs?
>

$
/usr/lib/x86_64-linux-gnu/qt5/examples/widgets/widgets/mousebuttons/mousebu=
ttons
failed to get the current screen resources
QXcbConnection: XCB error: 172 (Unknown), sequence: 169, resource id: 175,
major code: 149 (Unknown), minor code: 20
"Mouse Press: raw button=3D1  Qt=3DLeftButton\n heldbuttons LeftButton "
"Mouse Release: raw button=3D1  Qt=3DLeftButton\n heldbuttons NoButton"
"Mouse DoubleClick: raw button=3D1  Qt=3DLeftButton\n heldbuttonsLeftButton=
 "
"Mouse Release: raw button=3D1  Qt=3DLeftButton\n heldbuttons NoButton"

Reminder : the double click works when for example I launch an application
from the desktop shortcut.
It is only in this gambas software that it does not work, and only when
using x2go Windows client (works perfectly well with x2go linux client).


>
>
>
> Mihai
>
>

--f403045ec22c465fb60556db5e33
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_extra"><div><div class=3D"gmail_signat=
ure"><div dir=3D"ltr"><div><br></div></div></div></div><div class=3D"gmail_=
quote">2017-08-11 5:29 GMT+02:00 Mihai Moldovan <span dir=3D"ltr">&lt;<a hr=
ef=3D"mailto:ionic@ionic.de" target=3D"_blank">ionic@ionic.de</a>&gt;</span=
>:<br><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;b=
order-left:1px solid rgb(204,204,204);padding-left:1ex">Control: reassign -=
1 x2goserver 4.0.1.20<br>
<br>
First of all, x2goserver 4.0.1.20 actually is the correct stable release.<b=
r>
4.1.0.0 are the current nightly releases.<br>
<br>
I personally don&#39;t care much about what version is tested, but knowing =
whether<br>
there&#39;s a difference in behavior between the stable and nightly version=
s is<br>
certainly helpful.<br></blockquote><div><br></div><div>Same issues with bot=
h versions.</div><div>=C2=A0</div><blockquote class=3D"gmail_quote" style=
=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding=
-left:1ex">
<span class=3D"gmail-"><br>
<br>
On 08/10/2017 12:24 PM, Bruno CAPELETO wrote:<br>
&gt; Package: &lt;x2goserver&gt; Version: &lt;4.0.1.20-0x2go1+git20170412.<=
wbr>1125+9.main.1&gt;<br>
&gt;<br>
&gt; # uname -a Linux mtcie1 4.9.0-3-amd64 #1 SMP Debian 4.9.30-2+deb9u1<br=
>
&gt; (2017-06-18) x86_64 GNU/Linux<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; The below bugs are most probably related to each other, that&#39;s why=
 I open<br>
&gt; one case for all of them.<br>
&gt;<br>
&gt; The issues are the following : I want to use the French software Lauru=
x,<br>
&gt; which is based on Gambas interpreter, via a x2go session running on a =
Debian<br>
&gt; 9 server running LXDE (same issues seen on an Ubuntu server, x2goserve=
r<br>
&gt; version =3D 4.0.1.20-0~1125~ubuntu14.04.1)<wbr>..<br>
&gt;<br>
&gt; As a prerequisite, the software is installed on the server and runs we=
ll on<br>
&gt; a local session.<br>
&gt;<br>
&gt; 1. Whatever the client (Windows or Linux 4.0.3.1-4), the local environ=
ment<br>
&gt; variables are not set properly and the software - which needs French<b=
r>
&gt; localization - crashes. That could be &quot;solved&quot; the following=
 way :<br>
&gt; /etc/x2go/Xsession :<br>
&gt;<br>
&gt; ... LANG=3Dfr LC_ALL=3Dfr_FR.UTF-8 export LANG export LC_ALL ...<br>
&gt;<br>
&gt; That seems to be a revival of older bugs, but it is definitely still h=
ere.<br>
<br>
</span>How exactly did you set the locale?<br>
<br>
The &quot;Debian way&quot; would be to run dpkg-reconfigure locales as root=
 and select the<br>
desired locale(s) to generate and then select the default one.<br></blockqu=
ote><div><br></div><div>That is exactly the way =C2=A0I set the locales.</d=
iv><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;bord=
er-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
/etc/environment should not contain any locale settings.<br></blockquote><d=
iv><br></div><div>/etc/environmnent is empty</div><div>=C2=A0</div><blockqu=
ote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px=
 solid rgb(204,204,204);padding-left:1ex">
<br>
LANGUAGES and especially LC_ALL should normally not be set. LANGUAGES is a<=
br>
GNU-only list of fallback locales. LANG is the preferred way to set the loc=
ale,<br>
since it&#39;s being used if all of the LC_* env variables are empty.<br>
&quot;dpkg-reconfigure locales&quot; will do the right thing=E2=84=A2.<br><=
/blockquote><div><br></div><div>I confirm $LANGUAGES and $LC_ALL are not se=
t on a local session.</div><div>=C2=A0</div><blockquote class=3D"gmail_quot=
e" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204)=
;padding-left:1ex">
<span class=3D"gmail-"><br>
<br>
&gt; 2. At the start of a new session, one gets a windows with an error mes=
sage<br>
&gt; &quot;No session for pid ...&quot; ; that bug has already been reporte=
d several times<br>
&gt; in x2go bug tracking and marked as solved. Actually it is not on my br=
and new<br>
&gt; system.<br>
<br>
</span>What session are you starting exactly? I cannot find the string &quo=
t;No session for<br>
pid&quot; in x2goserver&#39;s source code. Not sure what to do with this.<b=
r></blockquote><div><br></div><div>I found out it is a reported bug related=
 to LXDE : cf=C2=A0<a href=3D"https://bugs.debian.org/cgi-bin/bugreport.cgi=
?bug=3D864402">https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D864402</=
a></div><div>=C2=A0</div><blockquote class=3D"gmail_quote" style=3D"margin:=
0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<span class=3D"gmail-"><br>
<br>
&gt; 3. The single application mode does not work with some of the applicat=
ions,<br>
&gt; including that Laurux / Gambas. For example it works with /usr/bin/lea=
fpad,<br>
&gt; but /usr/bin/libreoffice makes the x2go session crash.<br>
<br>
</span>That&#39;s certainly possible. The most likely cause, as Uli explain=
ed, is that the<br>
command daemonizes itself right after launching it. This leads to the X2Go<=
br>
scripts assuming that the program exited and subsequently also terminating =
the<br>
session. We&#39;ve seen such behavior every now and then and worked around =
it.<br>
<br>
However, it looks like x2goagent is crashing when you start libreoffice in =
your<br>
case. That shouldn&#39;t happen. My gut feeling is that this might be anoth=
er GTK3<br>
incompatibility.<br>
<br>
I could try to reproduce this in a clean stretch VM.<br></blockquote><div><=
br></div><div>Perfectly reproducible in my case on 2 installations.</div><d=
iv>=C2=A0</div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0p=
x 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<span class=3D"gmail-"><br>
<br>
&gt; 4. The mouse double clic does not work in a x2go session, but only - w=
ithin<br>
&gt; the Gambas software (works well for example when launching an applicat=
ion)<br>
&gt; and only - when the x2go client is running in a Windows environment (n=
o<br>
&gt; problem when client in a Linux environment)<br>
<br>
</span>That sounds like Gambas is doing something funny, though. As far as =
I was able<br>
to gather, Gambas seems to be using Qt5 as its drawing toolkit.<br>
<br>
The package qtbase5-examples should contain a binary at<br>
/usr/lib/x86_64-linux-gnu/qt5/<wbr>examples/widgets/widgets/<wbr>mousebutto=
ns/mousebuttons<br>
which spits out received mouse events.<br>
<br>
Can you try that - especially with double clicking - and see what it output=
s?<br></blockquote><div><br></div><div><div>$ /usr/lib/x86_64-linux-gnu/qt5=
/examples/widgets/widgets/mousebuttons/mousebuttons</div><div>failed to get=
 the current screen resources</div><div>QXcbConnection: XCB error: 172 (Unk=
nown), sequence: 169, resource id: 175, major code: 149 (Unknown), minor co=
de: 20</div><div>&quot;Mouse Press: raw button=3D1 =C2=A0Qt=3DLeftButton\n =
heldbuttons LeftButton &quot;</div><div>&quot;Mouse Release: raw button=3D1=
 =C2=A0Qt=3DLeftButton\n heldbuttons NoButton&quot;</div><div>&quot;Mouse D=
oubleClick: raw button=3D1 =C2=A0Qt=3DLeftButton\n heldbuttonsLeftButton &q=
uot;</div><div>&quot;Mouse Release: raw button=3D1 =C2=A0Qt=3DLeftButton\n =
heldbuttons NoButton&quot;</div></div><div><br></div><div>Reminder : the do=
uble click works when for example I launch an application from the desktop =
shortcut.</div><div>It is only in this gambas software that it does not wor=
k, and only when using x2go Windows client (works perfectly well with x2go =
linux client).</div><div>=C2=A0</div><blockquote class=3D"gmail_quote" styl=
e=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);paddin=
g-left:1ex">
<span class=3D"gmail-HOEnZb"><font color=3D"#888888"><br>
<br>
<br>
Mihai<br>
<br>
</font></span></blockquote></div><br></div></div>

--f403045ec22c465fb60556db5e33--
