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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #210 · 3 фев.

Что делать если нужно поставить какую-то Python-библиотеку а root-прав нет? То есть в систему библиотеку никак и ничего не поставить. Есть как минимум два способа это решить правильно! 🔸 Сделать виртуальное окружение и ставить там что угодно. Это позволит создать полностью независимое исполняемое окружение для ваших приложений. Все библиотеки будут храниться в домашней директории юзера а значит доступ на запись имеется. Создать очень просто: python3 -m venv ~/venvs/myenvname Теперь активируем окружение # Linux source ~/venvs/myenvname/bin/activate # Windows %userprofile%\venvs\myenvname\Scripts\activate.bat Можно ставить любые библиотеки и запускать приложение. Это стандартный метод работы с любым проектом. Если еще не используете его, то пора начинать. Даже при наличии root доступа! 🔸 Бывает, что нет возможности запустить приложение из своего виртуального окружения. Например, его запускает какой-то сервис от вашего юзера и вставить активацию окружения вы не можете. В этом случае можно установить библиотеки для Python не глобально в систему, а только для юзера. Выполните этот код в консоли: python3 -m site Вы получите что-то такое: sys.path = [ '/home/user', '/usr/lib/python37.zip', '/usr/lib/python3.7', '/usr/lib/python3.7/lib-dynload', '/home/user/.local/lib/python3.7/site-packages', ... ] USER_BASE: '/home/user/.local' USER_SITE: '/home/user/.local/lib/python3.7/site-packages' ENABLE_USER_SITE: True Нас интересует параметр USER_SITE. Это путь к пользовательским библиотекам, которые доступны по умолчанию, если они есть. Именно сюда будут устанавливаться модули если добавить флаг --user при установке чего-либо через pip pip install --user requests Для этой команды не нужны root-права. После неё можно запускать системный интерпретатор без виртуальных окружений и установленная библиотека будет доступна для текущего юзера. Параметр USER_BASE показывает корневую директорию для хранения user-библиотек. Её можно изменить с помощью переменной окружения PYTHONUSERBASE export PYTHONUSERBASE=~/pylibs python3 -m site ... USER_BASE: '/home/user/pylibs' USER_SITE: '/home/user/pylibs/lib/python3.7/site-packages' Получается некоторое подобие виртуального окружения для бедных 😁 которое можно менять через эту переменную (не делайте так!Лучше venv!) 🔸 Дописывание пути в PYTHONPATH Этот способ не входит в список "двух правильных", но тоже рабочий. Здесь придётся сделать всё несколько сложней. Сначала ставим библиотеку в любое место указывая путь установки pip3 install -t ~/mylibs modulename Библиотека установится без привязки к какому-либо интерпретатору. То есть по умолчанию не будет видна. Теперь в нужный момент добавляем этот путь в sys.path или в PYTHONPATH. Не буду советовать так делать. Единственный раз когда этот способ мне пригодился и решил поставленную задачу, это при создании общей библиотеки для кластера компьютеров. Модули лежат в сети и подгружаются для всех из одного и того же места. То есть обновлять файлы требуется только один раз а не на всех хосты отдельно. Минусы такого подхода: ▫️Нужно всем хостам пробить нужный путь в .bashrc или ещё куда-то чтобы он сетапился на старте. ▫️Чем больше хостов тем больше нагрузка на сеть. Иногда такой способ не подходит именно по этой причине. Тогда Ansible вам в помощь. ▫️Не очень подходит если хосты с разными операционками. Некоторые библиотеки различаются для Linux и Windows (там, где есть бинарники) и приходится мудрить более сложные схемы. #tricks#basic

Резултати

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

Пребарај: #libra

当前筛选 #libra清除筛选
Garantex News Russia

@garantexnews · Post #14359 · 18.02.2025 г., 13:00

📉Крах токена LIBRA стал самой обсуждаемой темой 🚩 Президент Аргентины Хавьер Милей оказался в центре скандала после обрушения токена LIBRA. Цена взлетела до $5, но затем рухнула ниже $1. Пострадали 40 000 инвесторов, а ущерб превысил $4 млрд. 💻 В соцсетях обсуждают роль Милея в афере и требуют его отставки. Также под удар попал Хейден Дэвис, создатель LIBRA и Melania, которого обвиняют в финансовых махинациях. 🚩 Многие юзеры призывают отказаться от мемкоинов на Solana, так как мошенники используют этот блокчейн для запуска фейковых проектов. 🚩 Solana занял второе место по числу упоминаний в соцсетях. Юзеры сходятся во мнении, что курс SOL напрямую зависит от обстановки вокруг мемкоинов, развернутых на этом блокчейне. 🚩 Пользователи также поддержали предложение Илона Маска по проверке золотых резервов Форт-Нокса. #LIBRA#Solana#Криптовалюты

Venture Village Wall 🦄

@venturevillagewall · Post #4161 · 15.02.2025 г., 16:00

Token LIBRA Crashes 94% in Hours 🚨 Argentine President Javier Milei's promoted token LIBRA plummeted 94% shortly after launch, with insiders cashing out over $107 million. Initial market cap peaked at $4.56 billion but has dropped to $174 million. The token was marketed as a tool to boost Argentina's economy. Milei later removed his promotional post and blamed political opponents for the fallout. 📉 Link to details: Full story #Crypto#Argentina#LIBRA#Trading#MarketCrash#TokenSale#InsiderTrading#ETH#VC #Crypto#Argentina#LIBRA#Trading#MarketCrash#TokenSale#InsiderTrading#ETH#VC

てんびん座♎ Source by pixiv 水鏡ひづめ 原始标签:#宝石#异色瞳#长发#星座#12星座#Libra#てんびん座 自定义标签:#甜妹#紫色系 尺寸: 3830x5096 @CosineGallery | 网站 | 3580, 3581

Venture Village Wall 🦄

@venturevillagewall · Post #4163 · 16.02.2025 г., 01:00

Market Moves: KIP Protocol & Canada Banks KIP Protocol states token issuance is under Kelsier Ventures. Argentine President Milei pledged support but will reinvest $100M into Libra tokens. Meanwhile, Canada's National Bank and Bank of Montreal acquire a total of $1.315B in $MSTR shares. KIP Protocol Link #KIP#Kelsier#Argentina#Libra#Bitcoin#MSTR#Canada#Finance#Investment#MarketMaking#Crypto#VC

🦅 [ perspective ix ]

@perspectiveix · Post #1848 · 18.06.2019 г., 10:30

​​💰Libra: Facebook confirms its cryptocurrency launching in 2020 #Libra is designed not to be a speculative asset, like #Bitcoin, but a form of digital money backed by a reserve of assets. The company has formed the nonprofit Libra Association with 27 other partners to oversee Libra and its development. The partnership includes venture capital firms, nonprofit organizations, #cryptocurrency firms, and massive corporate financial, telecommunications, and technology service providers, including #Coinbase, #Mastercard, #Visa, #eBay, #PayPal, #Stripe, #Spotify, #Uber, #Lyft, and #Vodafone. While the Libra Association will have members based globally, it will be headquartered in Geneva, Switzerland🇨🇭 Facebook has a business incentive to build on top of the Libra #blockchain, and it’s launching its own subsidiary to do just that called #Calibra (see the GIF below - Credit: Facebook). According to Kevin Weil, Facebook's VP of Product, Calibra will live inside of Facebook Messenger and WhatsApp at launch, but will also have a standalone iOS and Android app. 🔗 Read more the Verge. 🚀@PerspectiveIX

Chico_Tumblr

@Chico_Tumblr · Post #7582 · 06.04.2022 г., 18:28

La manera de hacer enojar a cada signo😤: #Aries♈️: Ignorandolo. #Tauro♉️: Pedirle más de lo que puede hacer. #Geminis♊️: Presionarlo a hacer algo que no quiere hacer. #Cancer♋️: Obligale a admitir que está equivocado. #Leo♌️: Niego sus palabras. #Virgo♍️: Que le lleven la contraria en lo que sea. #Libra♎️: Excluyendole de tus planes. #Escorpio♏️: Cometiendo errores absurdos. #Sagitario♐️: Cancelando un plan a última hora. #Capricornio♑️: Dile cómo tiene que hacer las cosas. #Acuario♒️: Cortale las alas. #Piscis♓️: No le des las gracias nunca. @EsTuHoroscopo.🔮

⚜🌺LA PUTA DEL POETA🌸

@laputadelpoeta · Post #14916 · 27.01.2023 г., 21:59

Lo que a los signos mas les gusta de su pareja🥰: #Aries♈️: Que le dejé ponerse sus sudaderas. #Tauro♉️: Que le haga una playlist. #Geminis♊️: Que le dejé hablar de sus pasiones. #Cancer♋️: Que hable de sus sentimientos sin timidez. #Leo♌️: Que le diga que es el/la más guapx. #Virgo♍️: Que siga hablándole aunque desaparezca durante días. #Libra♎️: Que tengan el mismo gusto musical que él/ella. #Escorpio♏️: Que se pueda hablar de cualquier cosa con su pareja. #Sagitario♐️: Que se ría de cualquier meme que le enseñe. #Capricornio♑️: Que vea cualquier serie con él/ella. #Acuario♒️: Que entienda que necesita su espacio. #Piscis♓️: Que recuerde cualquier pequeño detalle. @EsTuHoroscopo.🔮

Venture Village Wall 🦄

@venturevillagewall · Post #4162 · 15.02.2025 г., 19:00

Milei Withdraws LIBRA Support Amid Cash Out Argentinian President Javier Milei retracts his endorsement of $LIBRA after insiders reportedly cashed out $107 million. The move raises questions about transparency and the impact on the cryptocurrency's reputation. For more details, visit The Block. #Argentina#Milei#LIBRA#Crypto#DeFi#Blockchain#Investment#Transparency#Finance#Market#News#Updates#Economy#InsiderTrading#Regulation#Securities#Volatility#Trends#DigitalCurrency#Cryptocurrency

Venture Village Wall 🦄

@venturevillagewall · Post #4157 · 15.02.2025 г., 07:00

Insights on Crypto Developments 🚨 Important updates in the crypto sector: 1. Trump's Crypto Czar, David Sacks, hints at "important announcements" for digital assets soon. 2. KIP Protocol claims support for the LIBRA token by Argentina's president. Backed by Animoca Ventures and involved with the AI project *Open Campus*. Read more 3. Argentine President Mile clarifies his earlier tweet supporting a private startup, stating he lacked details at the time and has since deleted the post after further understanding. Read more #Crypto#AI#VC#Animoca#Argentina#KIPProtocol#Trump#DigitalAssets#Milei#LIBRA#OpenCampus#Startup#Partnerships#Decentralization#Finance#Blockchain#Tech

Venture Village Wall 🦄

@venturevillagewall · Post #4179 · 18.02.2025 г., 07:00

Investors Flock to Legal Tech Startups Despite a downturn in the venture capital market, record investments were made last year in legal tech startups focusing on AI solutions. These startups are securing rounds of $50-100 million as investor interest surges. Read more here: FastFounder article In other news, President Javier Milei of Argentina clarified that he only disseminated information about the LIBRA token, not promoted it, and confirmed meetings with individuals involved in its launch. This comes after a brief spike in LIBRA's price following his shared purchase instructions. Additionally, the CEO of Jupiter, Ben Chow, has resigned amid a rising scrutiny of the LIBRA project. Full News #AI#Crypto#VC#LegalTech#StartupInvestment#Argentina#LIBRA#VentureCapital#Investment#Technology#M&A #Blockchain#XRP#SEC#Audit#Innovation#TechTrends#MarketTrends

Venture Village Wall 🦄

@venturevillagewall · Post #4197 · 20.02.2025 г., 07:00

AI Infrastructure Opportunities Emerging! New potential for large-scale AI infrastructure projects! 🤖🔗 While fears of AI replacing humans persist, the reality shows a need for collaboration. Specialized platforms are essential for this interaction. Check out inspirations for creating your own platform here. Additionally, Nansen analysts report that 15,431 wallets experienced significant profit/loss on LIBRA: 86% lost $251M, while a few gained $180M. Recent crypto updates: BTC ETF outflow: $64M, ETH ETF inflow: $19M. During the last 24 hours, 74K traders were liquidated, totaling $139M. Largest liquidation: ETH/USDT at $2M on Binance. #AI#Crypto#VC#Blockchain#Investment#Finance#Tech#DataScience#MarketTrends#Nansen#Wallets#LIBRA#BTC#ETH#Liquidation#ETFs#ProfitLoss#Infrastructure#Innovation#DigitalEconomy#Trading

Venture Village Wall 🦄

@venturevillagewall · Post #4168 · 16.02.2025 г., 19:00

Argentina's Opposition Eyes Impeachment Over LIBRA Argentina's opposition is considering impeachment for President Milei after conflicting support for the LIBRA token. This follows a controversial launch that saw rapid investment and then a significant drop in value, leading to accusations of mismanagement and deception. The situation raises questions about political influence in cryptocurrency projects. Read more: Reuters #Argentina#LIBRA#Crypto#Impeachment#Milei#Investment#MarketManipulation#EconomicCrisis#Blockchain#DeFi#RugPull#Politics#Cryptocurrency#TokenLaunch#InsiderTrading#Securities#AI#VC

12
ПретходнаСтраница 1 од 2Следна