TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #205 · 22 јан.

Как работает функция reload()? Эта функция нужна для того, чтобы перезагрузить изменившийся код из py-файла без рестарта интерпретатора. Дело в том, что любой импортированный модуль при повторном импорте не будет перечитывать файл. Функция импорта вернёт уже загруженный в память объект модуля. Чтобы обновить код, нужно либо перезапустить всю программу, либо использовать функцию reload() from importlib import reload reload(my_module) 🔸 Функция reload() принимает в качестве аргумента только объект модуля или пакета. Она не может перезагрузить класс или функцию. Только весь файл целиком! 🔸 Перезагрузка пакета перезагрузит только его файл __init__.py, если он есть. Но не вложенные модули. 🔸Она не может перезагрузить ранее не импортированный модуль. 🔸При вызове функция reload() перечитывает и перекомпилирует код в файле, создавая новые объекты. После создания новых объектов перезаписывается ранее созданный неймспейс этого модуля. Это значит, что если где-то этот модуль импортирован через import и обращение к атрибутам происходит через неймспейс (имя) модуля, то такие атрибуты обновятся. Если какие-либо объекты из этого модуля импортированы через from то они будут ссылаться на старые объекты. Напишем простой модуль # mymodule.py x = 1 Теперь импортируем модуль и отдельно переменную х из модуля >>> import mymodule >>> from mymodule import x >>> print(mymodule.x) 1 >>> print(x) 1 Не перезапуская интерпретатор вносим изменения в модуль # mymodule.py x = 2 Делаем перезагрузку модуля и проверяем х ещё раз >>> reload(mymodule) >>> print(mymodule.x) 2 >>> print(x) 1 То же самое будет если присвоить любой объект переменной (даже словарь или список) Повторный импорт обновляет значение >>> from mymodule import x >>> print(x) 2 🔸Созданные инстансы классов не обновятся после перезагрузки модуля. Их придётся пересоздать. #tricks#basic

Резултати

Пронајдени 71 слични објави

Пребарај: #gala

当前筛选 #gala清除筛选
Coin Sonar

@CoinSonar · Post #244088 · 18.04.2026 г., 09:00

#GALA | Volume spike (USDT PAIR) 9 times the average volume 200.07K USDT traded in 15 min └Buying vol: 123.38K USDT 🟢 Boost score: 5/10 24h Vol: 1.96M USDT (Binance) Price: 0.00347 (-2.2% in 24h)

Hashtags

Coin Sonar

@CoinSonar · Post #243676 · 17.04.2026 г., 13:27

#GALA | Volume spike (USDT PAIR) 9 times the average volume 197.81K USDT traded in 15 min └Buying vol: 121.37K USDT 🟢 Boost score: 3/10 24h Vol: 1.96M USDT (Binance) Price: 0.00342 (-2.2% in 24h)

Hashtags

Pro Analysis

@proanalysistrader · Post #28387 · 14.01.2025 г., 16:21

#GALA/USDT analysis : #GALA is currently consolidating above the support zone and the 200 EMA. A price bounce is anticipated, allowing for a continuation of its bullish momentum aimed at testing previous highs. Wait for a breakout above the $0.03736 level for a long entry. TF : 1D Entry : $0.03736 Target : $0.06650 SL : $0.02860

Hashtags

Pro Analysis

@proanalysistrader · Post #28314 · 05.12.2024 г., 07:19

#GALA/USDT analysis : #GALA is in an uptrend, forming higher highs and higher lows. After retracing to the 200 EMA and a support zone, the price bounced back and broke the trendline. This suggests a bullish continuation, with expectations to test previous highs. TF : 15min Entry : $0.05933 Target : $0.06655 SL : $0.05497

Hashtags

Pro Analysis

@proanalysistrader · Post #28223 · 18.11.2024 г., 17:48

#GALA/USDT Analysis- After forming a symmetrical triangle pattern, the price broke out, achieving a 30% gain within three days. Currently, the price has completed a retest and is approaching its previous swing high. If it successfully breaks above this level, it has the potential to rally further by over 45%. T.F.- 1-D ENTRY- 0.0317 SL- 0.02720 TARGET- 0.04640 Note: If the stop-loss is triggered before entry, disregard the trade as the price action may develop differently.

Hashtags

Pro Analysis

@proanalysistrader · Post #27987 · 05.10.2024 г., 14:02

#GALA/USDT analysis : #GALA is in an uptrend, making higher highs (HHs) and higher lows (HLs). The price has recently tested the support zone and is expected to bounce back from there to test the previous swing high. TF : 1D Entry : $0.01984 Target : $0.02441 SL : $0.01824

Hashtags

American Crypto©

@americancryptotrading · Post #27573 · 30.03.2026 г., 09:44

🇺🇸#GALA/USDT is trading near the lowerborder of the fallingwedge on the weekly timeframe💁‍♂️ Looks good to buy✈️ American Crypto©

Hashtags

American Crypto©

@americancryptotrading · Post #27552 · 04.03.2026 г., 10:08

🇺🇸#GALA/USDT is facing the lowerborder of the fallingwedge on the weekly chart🧐 Strong upside potential on a bounce🐃 American Crypto©

Hashtags

American Crypto©

@americancryptotrading · Post #27512 · 23.01.2026 г., 10:12

🇺🇸#GALA/USDT is holding above the lowerboundary of the fallingwedge pattern on the weekly timeframe💁‍♂️ Strong upside potential on a bounce📈 American Crypto©

Hashtags

American Crypto©

@americancryptotrading · Post #27402 · 10.10.2025 г., 08:57

🇺🇸#GALA/USDT is moving inside the descendingtriangle on the weekly chart💁‍♂️ Breakout soon🐃 American Crypto©

Hashtags

American Crypto©

@americancryptotrading · Post #27359 · 29.08.2025 г., 09:33

🇺🇸#GALA/USDT is consolidating within the descendingtriangle pattern on the daily timeframe👀 Looks good for the midterm📈 American Crypto©

Hashtags

American Crypto©

@americancryptotrading · Post #27302 · 05.07.2025 г., 08:18

🇺🇸#GALA/USDT is facing the supportzone on the weekly timeframe💁‍♂️ Expecting a bounce soon✈️ American Crypto©

Hashtags

123•••56
ПретходнаСтраница 1 од 6Следна