There's always more that can be said, but this is a fairly frequently asked question. You can find more in the FAQ but let me help out and direct you to three particularly pertinent threads.
Why did England and France only declare war on Germany while Russia invaded Poland too ? from /u/Balnibarbian.
Why didn’t Britain and/or France declare war on the Soviet Union when the Soviets teamed with Hitler’s Nazis to take down Poland? from /u/Sergey_Romanov.
and finally In September 1939 Germany and the Soviet Union attacked Poland. Poland had defensive treaties with the great Britain and France. They declared war on Germany but not on the soviet Union. Why? from /u/Georgy_K_Zhukov.