Skip to content

Error retrieving the ticket details #6

@Anusree368

Description

@Anusree368

Hi Team,

While trying to retrieve the following details of certain tickets we have faced errors as shown below.

  1. Owner name
  2. Comment

Code:

import clientcentral.ticketformatting as tf
from clientcentral.clientcentral import ClientCentral
import clientcentral.query as operators
from tabulate import tabulate

# Production 'false' will run on qa.clientcentral.io
cc = ClientCentral(production=True, token="xyz")

tickets = cc.query_tickets().filter_by(
                    operators.and_( 
                                    operators.comparison("workspace_id", "=", "625"),
                                    operators.comparison("updated_at", ">", "'2023-05-29'")
                                   )
                                  ).all()

for ticket in tickets:
    try:
        print(ticket.ticket_id)
        print(ticket.comments)
        
    except Exception as e:
                print(f"Error retrieving ticket data: {e}")

Error:

image

image

Please note we are facing errors only for certain tickets but we are unable to find any similarities between them. Please try to replicate it and let me know a valuable solution.

Thanks!!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions