Logik-matchbox install problem

[root@ws105 logik]# ./INSTALL.command

Shader installer running python 3.6.8 (default, Apr 16 2020, 01:36:27)

[GCC 8.3.1 20191121 (Red Hat 8.3.1-5)]

Loading and parsing manifest...

Finding installs of IFFS that host shaders...

Installing matchboxes:

/opt/Autodesk/presets/2021.2.1/matchbox/shaders (version 2021.2.1)

Traceback (most recent call last):

File "./INSTALL.command", line 77, in <module>

logik.install_into_dir(dest_path, 'matchbox', pkgdir, shader_info_dicts)

File "/tmp/tmpddb63fen/installer_helpers.py", line 111, in install_into_dir

TypeError: object of type 'filter' has no len()

Way back when browsing glsl’s was slow I wrote a ‘compile’ script that used shader_builder to make everything into .mx/.lx and also install them, and also have since added a bunch of features I found personally useful like a skip list (I mean, I love PacMan as much as anyone, but…) and a categorizer that will put shaders into subdirectories based on what they start with.

It’s up at my github if you want to give it a go instead.

@julik ? Any ideas?

I think it is related to python3?

@Alan the install script is probably geared towards python2 and it might be challenging to make it compatible with both python3 and python2, although I could try. Is your python3 install your system’s or Flame’s? The idea with the installer was initially that it had to run reliably on whichever python is provided by Flame itself, which so far is still python2. So:

  • Can you please run a which python in your shell?
  • Can some other people ( @randy ?) run which python in their shells too?

I was able to get the INSTALL.command to work. This was on my test ADSK 8.2 + DKU vm (NO installation of flame)

I’m not that great with python, but I changed this line:

applicable_matchboxes = filter(lambda s: s[\'shader_type\'] == shader_type and s[\'required_matchbox_version\'] <= sw_version, shader_info_dicts)\n

to this:
applicable_matchboxes = list(filter(lambda s: s[\'shader_type\'] == shader_type and s[\'required_matchbox_version\'] <= sw_version, shader_info_dicts))\n

and the script completed the installation (AFAICT).

[root@vxfhost MatchboxShaderCollection]# ./INSTALL.command
Shader installer running python 3.6.8 (default, Apr 16 2020, 01:36:27)
[GCC 8.3.1 20191121 (Red Hat 8.3.1-5)]
Loading and parsing manifest...
Finding installs of IFFS that host shaders...
Installing matchboxes:
/opt/Autodesk/presets/2022/matchbox (version 2022.0.0)
328 shaders satisfy version and type, installing.
         Creating directory /opt/Autodesk/presets/2022/matchbox/LOGIK
Installing lightboxes:
/opt/Autodesk/presets/2022/action/lightbox (version 2022.0.0)
10 shaders satisfy version and type, installing.
         Creating directory /opt/Autodesk/presets/2022/action/lightbox/LOGIK
Installation complete!


[root@vxfhost ~]# python -V
Python 3.6.8

[root@vxfhost ~]# alternatives --list | grep  python
python                  auto    /usr/libexec/no-python
python3                 auto    /usr/bin/python3.6

HTH.