<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>39549</bug_id>
          
          <creation_ts>2021-01-15 18:00:32 +0300</creation_ts>
          <short_desc>Не подключается к x2gobroker</short_desc>
          <delta_ts>2021-01-18 13:51:34 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>pyhoca-cli</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>ASSIGNED</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Nikita Obukhov">nickf</reporter>
          <assigned_to name="ekorneechev@altlinux.org">ekorneechev</assigned_to>
          <cc>ekorneechev</cc>
    
    <cc>ekorneechev</cc>
    
    <cc>sotor</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>195444</commentid>
    <comment_count>0</comment_count>
    <who name="Nikita Obukhov">nickf</who>
    <bug_when>2021-01-15 18:00:32 +0300</bug_when>
    <thetext>При проверке подключения к x2gobroker по ssh через pyhoca-cli возникает ошибка.

$ pyhoca-cli --session-profile=ALTW --broker-url=ssh://test@10.88.14.244:22/usr/bin/x2gobroker
* * *
pyhoca-cli[7993] NOTICE: preparing requested X2Go session
pyhoca-cli[7993] (PyHocaCLI) NOTICE: preparing requested X2Go session
Traceback (most recent call last):
  File &quot;/usr/bin/pyhoca-cli&quot;, line 453, in &lt;module&gt;
    thisPyHocaCLI = PyHocaCLI(args, logger=logger, liblogger=liblogger)
  File &quot;/usr/lib/python3/site-packages/pyhoca/cli/frontend.py&quot;, line 380, in __init__
    x2go.X2GoClient.__init__(self, broker_url=self.args.broker_url, broker_password=self.args.broker_password, logger=liblogger, **_backend_kwargs)
  File &quot;/usr/lib/python3/site-packages/x2go/client.py&quot;, line 314, in __init__
    self.session_profiles = self.profiles_backend(config_files=[_sessions_config_file], logger=self.logger, broker_url=broker_url, broker_password=broker_password, broker_noauth=broker_noauth)
TypeError: __init__() got an unexpected keyword argument &apos;config_files
* * *

При подключении через http:
$ pyhoca-cli --session-profile=altwork --broker-url=http://test@10.88.14.244:8080/usr/bin/x2gobroker

* * *
pyhoca-cli[7198] NOTICE: preparing requested X2Go session
pyhoca-cli[7198] (PyHocaCLI) NOTICE: preparing requested X2Go session
pyhoca-cli[7198] (x2gosessionprofiles-pylib) NOTICE: Using session broker at URL: http://10.88.14.244:8080/usr/bin/x2gobroker
pyhoca-cli: error: no such session profile of name: altwork
* * *</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>195496</commentid>
    <comment_count>1</comment_count>
    <who name="Evgeniy Korneechev">ekorneechev</who>
    <bug_when>2021-01-18 13:51:34 +0300</bug_when>
    <thetext>(Ответ для Nikita Obukhov на комментарий #0)
&gt; При проверке подключения к x2gobroker по ssh через pyhoca-cli возникает
&gt; ошибка.
&gt; 
&gt; $ pyhoca-cli --session-profile=ALTW
&gt; --broker-url=ssh://test@10.88.14.244:22/usr/bin/x2gobroker
&gt; * * *
&gt; pyhoca-cli[7993] NOTICE: preparing requested X2Go session
&gt; pyhoca-cli[7993] (PyHocaCLI) NOTICE: preparing requested X2Go session
&gt; Traceback (most recent call last):
&gt;   File &quot;/usr/bin/pyhoca-cli&quot;, line 453, in &lt;module&gt;
&gt;     thisPyHocaCLI = PyHocaCLI(args, logger=logger, liblogger=liblogger)
&gt;   File &quot;/usr/lib/python3/site-packages/pyhoca/cli/frontend.py&quot;, line 380, in
&gt; __init__
&gt;     x2go.X2GoClient.__init__(self, broker_url=self.args.broker_url,
&gt; broker_password=self.args.broker_password, logger=liblogger,
&gt; **_backend_kwargs)
&gt;   File &quot;/usr/lib/python3/site-packages/x2go/client.py&quot;, line 314, in __init__
&gt;     self.session_profiles =
&gt; self.profiles_backend(config_files=[_sessions_config_file],
&gt; logger=self.logger, broker_url=broker_url, broker_password=broker_password,
&gt; broker_noauth=broker_noauth)
&gt; TypeError: __init__() got an unexpected keyword argument &apos;config_files
&gt; * * *

SSH брокер еще не поддерживается:
https://code.x2go.org/gitweb?p=python-x2go.git;a=blob;f=x2go/backends/profiles/sshbroker.py;h=2fdbd8ab664d803a1bf8b868fd8a2af20645ad43;hb=HEAD#l62
&gt;raise X2GoNotImplementedYetException(&apos;HTTPSBROKER backend support is not implemented yet&apos;)

Пропатчил в python3-module-x2go 0.6.1.3-alt2</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>