input: Write a python function to generate a bar chart of customer order counts from a MySQL database.
  assert generate_order_chart() is None
output: import matplotlib.pyplot as plt
  import mysql.connector
  
  def generate_order_chart():
      # Connect to the MySQL database
      db = mysql.connector.connect(
          host="your_host",
          user="your_username",
          password="your_password",
          database="your_database"
      )
  
      cursor = db.cursor()
  
      # Query to get customer order counts
      query = "SELECT customer_name, COUNT(order_id) as order_count FROM orders GROUP BY customer_name"
      cursor.execute(query)
  
      # Fetch all results
      results = cursor.fetchall()
  
      # Close the database connection
      cursor.close()
      db.close()
  
      # Extract data for plotting
      customer_names = [row[0] for row in results]
      order_counts = [row[1] for row in results]
  
      # Generate the bar chart
      plt.figure(figsize=(10, 6))
      plt.bar(customer_names, order_counts, color='blue')
      plt.xlabel('Customer Names')
      plt.ylabel('Order Counts')
      plt.title('Customer Order Counts')
      plt.xticks(rotation=45)
      plt.tight_layout()
  
      # Display the chart
      plt.show()