question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItΒ collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

error importing restobject

See original GitHub issue

When i try to import the restobject I got anerror message. Could you help me to figure out what did I miss here?

This is how I import it: from _restobject import RestObject

This is the error message:

raceback (most recent call last):
  File "./ilo.py", line 18, in <module>
    from _restobject import RestObject
ImportError: No module named '_restobject'

I installed the ilorest library as well:

pip install python-ilorest-library
Collecting python-ilorest-library
  Downloading python-ilorest-library-1.9.2.zip (78kB)
    100% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 81kB 129kB/s
Collecting jsonpatch (from python-ilorest-library)
  Downloading jsonpatch-1.16-py2.py3-none-any.whl
Collecting jsonpath_rw (from python-ilorest-library)
  Downloading jsonpath-rw-1.4.0.tar.gz
Collecting jsonpointer (from python-ilorest-library)
  Downloading jsonpointer-1.10.tar.gz
Collecting validictory (from python-ilorest-library)
  Downloading validictory-1.1.1.tar.gz
Collecting urlparse2 (from python-ilorest-library)
  Downloading urlparse2-1.1.1.tar.gz
Collecting ply (from jsonpath_rw->python-ilorest-library)
  Downloading ply-3.10.tar.gz (150kB)
    100% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 153kB 283kB/s
Collecting decorator (from jsonpath_rw->python-ilorest-library)
  Downloading decorator-4.0.11-py2.py3-none-any.whl
Requirement already satisfied: six in /usr/lib/python3.4/site-packages (from jsonpath_rw->python-ilorest-library)
Collecting recordtype (from urlparse2->python-ilorest-library)
  Downloading recordtype-1.1.tar.gz
Building wheels for collected packages: python-ilorest-library, jsonpath-rw, jsonpointer, validictory, urlparse2, ply, recordtype
  Running setup.py bdist_wheel for python-ilorest-library ... done
  Stored in directory: /root/.cache/pip/wheels/f6/09/94/270372428edee741558a548a2b376ff93fc1391f7f6b7026b8
  Running setup.py bdist_wheel for jsonpath-rw ... done
  Stored in directory: /root/.cache/pip/wheels/ff/80/3d/6d630248dd938306a8691b9658ee91e07fb794076d714f8ce8
  Running setup.py bdist_wheel for jsonpointer ... done
  Stored in directory: /root/.cache/pip/wheels/c6/63/b3/64aa830fca63497c9098d7a7b08058d261f7709727c7d93767
  Running setup.py bdist_wheel for validictory ... done
  Stored in directory: /root/.cache/pip/wheels/ae/96/32/1e175a036b68889ac08b1802219618bea8a3a020e376e3bc98
  Running setup.py bdist_wheel for urlparse2 ... done
  Stored in directory: /root/.cache/pip/wheels/d0/08/0e/1bb071cd176e00fcbc1dc7aba3e0f649b4f54c0e8c3203c7ac
  Running setup.py bdist_wheel for ply ... done
  Stored in directory: /root/.cache/pip/wheels/ad/dd/ad/8ce1991a7b380dfe23d6cc81a4de5c2775bc728b5a0a7721aa
  Running setup.py bdist_wheel for recordtype ... done
  Stored in directory: /root/.cache/pip/wheels/0e/52/54/c5f783e96e2b1f5364d360716b47768c21d84efa73d3745b45
Successfully built python-ilorest-library jsonpath-rw jsonpointer validictory urlparse2 ply recordtype
Installing collected packages: jsonpointer, jsonpatch, ply, decorator, jsonpath-rw, validictory, recordtype, urlparse2, python-ilorest-library
Successfully installed decorator-4.0.11 jsonpatch-1.16 jsonpath-rw-1.4.0 jsonpointer-1.10 ply-3.10 python-ilorest-library-1.9.2 recordtype-1.1 urlparse2-1.1.1 validictory-1.1.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:11

github_iconTop GitHub Comments

3reactions
tbarbettecommented, Aug 19, 2019

This file is still not distributed out of today’s β€œpip install”. Therefore the quick start example still does not work if followed β€œline by line”.

0reactions
bihary84commented, Jun 19, 2017

Thank you! I started to watch the project!

Read more comments on GitHub >

github_iconTop Results From Across the Web

error importing restobject Β· Issue #3 - GitHub
When i try to import the restobject I got anerror message. Could you help me to figure out what did I miss here?...
Read more >
GitlabParsingError when accessing a project with GitLab API ...
The first argument to gitlab.Gitlab() is the base URL of the instance not the full path to your project. e.g. https://gitlab.example.com .
Read more >
Getting started with the API - python-gitlab v3.12.0
Gitlab is the primary class, handling the HTTP requests. It holds the GitLab URL and authentication information. gitlab.base.RESTObject is the base class forΒ ......
Read more >
base.py - python-gitlab/python-gitlab - Sourcegraph
from gitlab import types as g_types. from gitlab.exceptions import GitlabParsingError. from .client import Gitlab, GitlabList. __all__ = [. "RESTObject",.
Read more >
python-gitlab Documentation - Read the Docs
RESTObject is the base class for all the GitLab v4 objects. ... errors. import gitlab import requests gl = gitlab.gitlab(url, token,Β ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found