Python Forum
How to print the content of the object?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to print the content of the object?
#5
Hi @janaki26794,

Here is how I worked around it. Save the result of the mapping in a variable then call the attribute on the variable like shown below.

response = self.session.get(self.base_url + section + area_id + "/", verify=True)
        if response.status_code == 200:
           [b] result = Pavlova().from_mapping(response.json(), Group)[/b]
            [b]return result.name[/b]
        else:
            return None
Seems we are working on the same project Big Grin message me if you want to. Goodluck!
Reply


Messages In This Thread
RE: How to print the content of the object? - by Glowyee - Jul-29-2019, 08:41 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  print all method and property of list object engmoh 4 2,958 Oct-26-2019, 05:33 PM
Last Post: engmoh

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020