class_docstr: The GitHub Projects Table implementation
class_docstr_tok: ["The","GitHub","Projects","Table","implementation"]
docstr: Pulls data from the GitHub "List repository projects" API
  
  Parameters
  ----------
  query : ast.Select
     Given SQL SELECT query
  
  Returns
  -------
  pd.DataFrame
  
      GitHub projects matching the query
  
  Raises
  ------
  ValueError
      If the query contains an unsupported condition
docstr_tok: ["Pulls","data","from","the","GitHub","``","List","repository","projects","''","API","Parameters","--","--","--","--","--","query",":","ast.Select","Given","SQL","SELECT","query","Returns","--","--","--","-","pd.DataFrame","GitHub","projects","matching","the","query","Raises","--","--","--","ValueError","If","the","query","contains","an","unsupported","condition"]
code: def select(self, query: ast.Select) -> pd.DataFrame:
      """Pulls data from the GitHub "List repository projects" API
  
      Parameters
      ----------
      query : ast.Select
         Given SQL SELECT query
  
      Returns
      -------
      pd.DataFrame
  
          GitHub projects matching the query
  
      Raises
      ------
      ValueError
          If the query contains an unsupported condition
      """
  
      select_statement_parser = SELECTQueryParser(
          query, "projects", self.get_columns()
      )
  
      (
          selected_columns,
          where_conditions,
          order_by_conditions,
          result_limit,
      ) = select_statement_parser.parse_query()
  
      total_results = result_limit if result_limit else 20
  
      self.handler.connect()
  
      github_projects_df = pd.DataFrame(columns=self.get_columns())
  
      start = 0
  
      while True:
          try:
              for project in self.handler.connection.get_repo(
                  self.handler.repository
              ).get_projects()[start : start + 10]:
                  raw_data = project.raw_data
                  github_projects_df = pd.concat(
                      [
                          github_projects_df,
                          pd.DataFrame(
                              [
                                  {
                                      "owner_url": self.check_none(
                                          raw_data["owner_url"]
                                      ),
                                      "url": self.check_none(
                                          raw_data["url"]
                                      ),
                                      "html_url": self.check_none(
                                          raw_data["html_url"]
                                      ),
                                      "columns_url": self.check_none(
                                          raw_data["columns_url"]
                                      ),
                                      "id": self.check_none(
                                          raw_data["id"]
                                      ),
                                      "node_id": self.check_none(
                                          raw_data["node_id"]
                                      ),
                                      "name": self.check_none(
                                          raw_data["name"]
                                      ),
                                      "body": self.check_none(
                                          raw_data["body"]
                                      ),
                                      "number": self.check_none(
                                          raw_data["number"]
                                      ),
                                      "state": self.check_none(
                                          raw_data["state"]
                                      ),
                                      "created_at": self.check_none(
                                          raw_data["created_at"]
                                      ),
                                      "updated_at": self.check_none(
                                          raw_data["updated_at"]
                                      ),
                                      "creator_login": self.check_none(
                                          raw_data["creator"]["login"]
                                      ),
                                      "creator_id": self.check_none(
                                          raw_data["creator"]["id"]
                                      ),
                                      "creator_url": self.check_none(
                                          raw_data["creator"]["url"]
                                      ),
                                      "creator_html_url": self.check_none(
                                          raw_data["creator"][
                                              "html_url"
                                          ]
                                      ),
                                      "creator_site_admin": self.check_none(
                                          raw_data["creator"][
                                              "site_admin"
                                          ]
                                      ),
                                  }
                              ]
                          ),
                      ]
                  )
  
                  if github_projects_df.shape[0] >= total_results:
                      break
          except IndexError:
              break
  
          if github_projects_df.shape[0] >= total_results:
              break
          else:
              start += 10
  
      select_statement_executor = SELECTQueryExecutor(
          github_projects_df,
          selected_columns,
          where_conditions,
          order_by_conditions,
      )
  
      github_projects_df = select_statement_executor.execute_query()
  
      return github_projects_df
  
imports: import pandas
  from typing import List
  from mindsdb.integrations.libs.api_handler import APITable
  from mindsdb.integrations.handlers.utilities.query_utilities import SELECTQueryParser, SELECTQueryExecutor
  from mindsdb.integrations.utilities.sql_utils import extract_comparison_conditions
  from mindsdb.utilities import log
  from mindsdb_sql.parser import ast
label_desc: Use image node_id 1 for calling the GithubProjectsTable obj's underlying member method code with example usage: obj.select(query) and returns: github_projects_df