Hey Andrei L.,
I was also facing similar issues and you will face same again with your solution when your project will have huge number of traces.
df_all_spans = client.get_spans_dataframe(project_name=project_name)
what worked out for me :
set timeout to some huge number
use query filter : SpanQuery().where(....)
use start_time and end_time with very small interval and in batch rather than all in one go