Basically, I think it's possible Doctor Strange was Groundhog Day–ing the whole movie and didn't tell anyone.
There have been all kinds of rumors, involving set photos, and leaked toy manuals, and all kinds of other nonsense over the last year that have led fans to expect time travel to happen in Endgame in some form. It's become the predominant Endgame fan theory.
On Titan, toward the end of Infinity War, Doctor Strange tells Tony Stark that he used the Time Stone to look into the future, and he viewed 14 million possible outcomes. Only in one of those did the Avengers win.
The whole sequence is supposed to lead us to believe that somehow Strange giving Thanos the Time Stone will lead to the 1 in 14,000,605 chance that Thanos could be defeated. The assumption is that Endgame will follow the remaining Avengers as they figure out how to reverse the effects of the Snap.
The Ancient One explains that the ability to peer into one's future using the Time Stone is limited by the lifespan of the user. Basically, you can only look in the future as far as your own death.
"I spent so many years peering through time...looking at this exact moment. But I can't see past it," the Ancient One tells Strange.
Which would mean that Doctor Strange could look into the future as much as he goddamn pleased, but he would be unable to look past the moment he was dusted on Titan.
At the end of Doctor Strange, Strange uses a Time Stone–powered time loop to defeat Dormammu, the interdimensional entity trying to eat the universe or whatever. Strange traps himself and Dormammu in a loop where Strange gets killed over and over again, only for the Time Stone to reset him.
“So I keep a watch list of individuals and beings from other realms that may be a threat to this world. Your adopted brother Loki is one of those beings," Strange says.
Strange also knew where Odin was on Earth. Basically, Strange, by the time we meet him in Ragnarok, has become like the MCU's space CIA. He's keeping tabs on everybody.
And we know Pepper and Tony haven't gotten married yet because later Tony says, "Wong, you are invited to my wedding."
Of course, everything leading up to Titan makes more sense if Doctor Strange was actually trying to get captured.
The reason Heimdall can protect Asgard so well is because he can see and hear everything that happens in the Nine Realms. Which means that if Doctor Strange activated the Time Stone, Heimdall would know. He knows everything that's happening at any given moment.
(Fans are pretty convinced Shuri was successful.)
(While it has yet to be confirmed in the movies, in the comics the "Infinity Gems" only work inside the dimension they're activated in. So Ant-Man, being in a different realm, was most likely protected from the Snap.)
In the Endgame trailer, we see the remaining Avengers going into space. They're dressed like this.
Both times we've seen the Quantum Realm, it's involved some kind of timey-wimey nonsense. Many fans are speculating that it could be used to break through space and time and travel into the past.
In Ant-Man and the Wasp, we learn that Janet Van Dyne, the original Wasp, gained the ability to appear in dreams and break through dimensional barriers after spending time in the Quantum Realm.
Also, the only two stones not present at the Battle of New York are the Power Stone and the Reality Stone. Rocket would know where the Power Stone is. Thor would know where the Reality Stone is. And Nebula knows where the Soul Stone is. Who gets sacrificed to get it, though, is a question for a whole other post.