title: Variable Problem In My Discord Python Bot
body: <p>I wanted to make a bot which will send a fact every day (I took some code from there). But there is a problem. My bot sends same message every day. Why it doesn't work properly?</p>
  <pre><code>import os
  import time
  import discord
  import json
  from discord.ext import commands
  from datetime import datetime, time, timedelta
  import bilgiler_sözlüğü
  from server import server
  
  server()
  
  TOKEN = os.environ['bot_token']
  client = discord.Client()
  sira = 1
  
  def zaman():
      print(&quot;Zaman komutu çalıştırıldı.&quot;)
      while True:
          current_time = datetime.now().strftime(&quot;%H:%M&quot;)
          if current_time == &quot;05:45&quot;:
              global sayac
              print(&quot;Zaman eşleştirildi.&quot;)
              break
  
  zaman()
  
  
  
  @client.event
  async def on_ready():
    global sira
    print(&quot;{0.user}&quot;.format(client), &quot;çalıştırıldı.&quot;)
    channel = client.get_channel(1001947725635530805)
    try:
      await channel.send(bilgiler_sözlüğü.sözlük[sira])
      sira += 1
    except KeyError:
      await channel.send(&quot;Bilgilerim bitti!&quot;)
      
  
  client.run(TOKEN)
  </code></pre>
  <p>&quot;sira&quot; is the variable which pulls out my dictionary. It must increase day by day. What must I do?</p>