Метод строки isidentifier() поможет узнать, подходит ли данная строка в качестве имени объекта.
Вполне может заменить самостоятельно придуманную регулярку.
>>> 'some_name'.isidentifier()
True
Обычное имя переменной
>>> '私は手紙です'.isidentifier()
True
Юникод в качестве имени тоже доступен
>>> '1_name'.isidentifier()
False
Имя не может начинаться с цифры
>>> '੬_name'.isidentifier()
False
Включая все цифры юникода
>>> 'some name'.isidentifier()
False
Пробелы недопустимы
#basic
#DIA/USDT analysis :
#DIA is in an uptrend, forming higher highs (HHs) and higher lows (HLs). The price has retraced and tested the support zone, rebounding from that level. It is expected that the price will continue its bullish momentum from the current level and test the previous highs.
TF : 1W
Entry : $0.5230
Target : $1.2800
SL : $0.3480