The doc you referenced is outdated.
https://s3-docs.fd.io/vpp/22.06/index.html rather unfortunately doesn't
mention the Python API at all. I'll see if I can add a doc with my example
there, for future readers.

The object to instantiate is now called VPPApiClient. Please take a look at
previous posts on this mailinglist (for example this one:
https://lists.fd.io/g/vpp-dev/message/21645) for additional tips on how to
use the VPP Python API.

groet,
Pim

On Wed, Jul 20, 2022 at 11:01 AM Krisztián Varga <vargakris...@gmail.com>
wrote:

> Hello Everyone,
>
> I just ran into a problem, that I cannot resolve: both on my ubuntu nodes
> (20.04 and 18.04) I have VPP installed, I've set the LD_LIBRARY_PATH to 
> /usr/lib/x86_64-linux-gnu/
> on the 18.04 machine, and
> /vpp/build-root/build-vpp-native/vpp/lib/x86_64-linux-gnu on the 20.04, so
> the path to libvppapiclient.so is known for the system. After this I did sudo
> python setup.py install, it worked fine on both of my nodes. I'm using
> python3.6 (and 3.8 on the newer ubuntu), importing vpp_papi works, however
> from vpp_papi import VPP doesn't want to work for me. I get ImportError:
> cannot import name 'VPP' from 'vpp_papi'
> (/usr/lib/python3/dist-packages/vpp_papi/__init__.py). I tried importing
> only vpp_papi and use vpp_papi.VPP but it doesn't seem to have such
> attribute.
>
> I tried with virtualenv also. I followed this:
> https://wiki.fd.io/view/VPP/Python_API. I have python3-vpp-api installed.
> Any idea for solving this import problem?
>
> Thank you for any answers.
>
> 
>
>

-- 
Pim van Pelt <p...@ipng.nl>
PBVP1-RIPE - http://www.ipng.nl/
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#21688): https://lists.fd.io/g/vpp-dev/message/21688
Mute This Topic: https://lists.fd.io/mt/92500699/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/leave/1480452/21656/631435203/xyzzy 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to