Code With Python
39.2K subscribers
891 photos
28 videos
22 files
773 links
This channel delivers clear, practical content for developers, covering Python, Django, Data Structures, Algorithms, and DSA – perfect for learning, coding, and mastering key programming skills.
Admin: @HusseinSheikho || @Hussein_Sheikho
Download Telegram
This media is not supported in your browser
VIEW IN TELEGRAM
πŸ’» GHOSTCREW β€” A Python AI tool for penetration testers and security professionals that conducts vulnerability searches in any services.

It works like a red team within your system. You describe the task in plain language β€” then it plans the attack itself, selects tools, and proceeds through the entire process: from reconnaissance to reporting. Without manual fiddling and endless commands.

What it can do in practice:

➑️ Checks everything: code, business logic, network traffic, protocols.
➑️ Analyzes the found vulnerabilities and explains where the problem is and how to fix it.
➑️ Works autonomously β€” you just launch it and get a full-fledged research.
➑️ Connects MCP servers and tools (nmap, metasploit, ffuf, etc.) itself.
➑️ Uses Pentesting Task Trees for meaningful decision-making, not just brute force.
➑️ Supports ready-made workflows for comprehensive checks.
➑️ Generates detailed reports in Markdown with facts and recommendations.
➑️ Remembers the dialogue context and doesn't "get lost" after a couple of requests.
➑️ Sees real files: wordlists, payloads, configs β€” and uses them in its work.
➑️ Allows you to choose an AI model and customize its behavior.
➑️ No registration and no restrictions.

βš™οΈ Installation:
git clone https://github.com/GH05TCREW/ghostcrew.git
cd ghostcrew
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt


▢️ Usage:
python main.py


⚠️ The information is provided solely for informational purposes. And it encourages to pay attention to security issues.

β™ŽοΈ GitHub/Instructions

#python #soft #github
Please open Telegram to view this post
VIEW IN TELEGRAM
❀3
✨ global variable | Python Glossary ✨

πŸ“– A variable defined at the top level of a module.

🏷️ #Python
😰 A repository of more than 100+ ready-made Python scripts that solve a bunch of tasks - without reinventing the wheel and suffering at night.

πŸ’¬ parsing and searching on the internet;
πŸ’¬ working with photos and videos;
πŸ’¬ keyloggers and password managers;
πŸ’¬ cloning websites;
πŸ’¬ automating routines;
πŸ’¬ and dozens of other useful things for real cases.

πŸ”₯ Ready-made practice + code, suitable for both learning and work.

⬇️ Save it, it will definitely come in handy!

#python #soft #github
Please open Telegram to view this post
VIEW IN TELEGRAM
❀6πŸ‘1
Forwarded from PyData Careers
πŸ”₯ Generating fake data in Python β€” no pain at all

If you're testing forms, mockups, or just want to play with data, there's Mimesis β€” a generator of fake data. Names, emails, addresses, and phone numbers. There's a location setting that allows you to select a country, and the data will be generated accordingly.

πŸ“¦ Installation:
from typing import Dict
from mimesis.enums import Gender
from mimesis import Person

def generate_fake_user(locale: str = "es", gender: Gender = Gender.MALE) -> Dict[str, str]:
    """
    Generates fake user data based on the locale and gender.

    :param locale: The locale (for example, 'ru', 'en', 'es')
    :param gender: The gender (Gender.MALE or Gender.FEMALE)
    :return: A dictionary with the fake user data
    """
    person = Person(locale)

    user_data = {
        "name": person.full_name(gender=gender),
        "height": person.height(),
        "phone": person.telephone(),
        "occupation": person.occupation(),
    }

    return user_data

if __name__ == "__main__":
    fake_user = generate_fake_user(locale="es", gender=Gender.MALE)
    print(fake_user)


πŸ“Œ Result:
{
  'name': 'Carlos Herrera',
  'height': '1.84',
  'phone': '912 475 289',
  'occupation': 'Arquitecto'
)


⚑️ Mimesis can:
πŸ–± Generate names, addresses, phone numbers, professions, etc. 
πŸ–± Work with different countries (πŸ‡·πŸ‡Ί ru, πŸ‡ΊπŸ‡Έ en, πŸ‡ͺπŸ‡Έ es, etc.) 
πŸ–± Suitable for tests, fake accounts, demo data in projects, and bots.

βš™οΈ GitHub/Instructions

Save it, it'll come in handy πŸ‘

#python #github #interview
Please open Telegram to view this post
VIEW IN TELEGRAM
❀5
✨ How to Integrate Local LLMs With Ollama and Python ✨

πŸ“– Learn how to integrate your Python projects with local models (LLMs) using Ollama for enhanced privacy and cost efficiency.

🏷️ #intermediate #ai #tools
❀1
✨ introspection | Python Glossary ✨

πŸ“– The ability of a program to examine the type or properties of an object at runtime.

🏷️ #Python
✨ local variable | Python Glossary ✨

πŸ“– A variable that you bind inside a function or method body.

🏷️ #Python
✨ Quiz: How to Integrate ChatGPT's API With Python Projects ✨

πŸ“– Test your knowledge of the ChatGPT API in Python. Practice sending prompts with openai and handling text and code responses in this quick quiz.

🏷️ #intermediate #ai #api
❀1
How to correctly terminate Python scripts

In production, it's important to clearly signal the result of the program's work. For this, sys.exit(<code>) is used:
β€’ 0 β€” success
β€’ a non-zero value β€” error

This approach helps CI/CD, Docker or cron to correctly respond to failures. It's mandatory for CLI utilities and automation, so that the execution is predictable

https://t.iss.one/DataScience4
❀5
✨ Anaconda Navigator | Python Tools ✨

πŸ“– A desktop graphical interface included with the Anaconda Distribution.

🏷️ #Python
❀2
✨ unpacking | Python Glossary ✨

πŸ“– Passing multiple values at once by expanding an iterable.

🏷️ #Python
✨ Quiz: How to Integrate Local LLMs With Ollama and Python ✨

πŸ“– Check your understanding of using Ollama with Python to run local LLMs, generate text, chat, and call tools for private, offline apps.

🏷️ #intermediate #ai #tools
πŸ™πŸ’Έ 500$ FOR THE FIRST 500 WHO JOIN THE CHANNEL! πŸ™πŸ’Έ

Join our channel today for free! Tomorrow it will cost 500$!

https://t.iss.one/+0-w7MQwkOs02MmJi

You can join at this link! πŸ‘†πŸ‘‡

https://t.iss.one/+0-w7MQwkOs02MmJi
❀2
Working with f-strings: more possibilities than it seems!

f-strings often replace .format() in everyday code, but their capabilities are not always fully utilized. They support formatting, function calls, working with data structures, and convenient debugging (from 3.8+).

f-strings are convenient for aligning columns without additional tools. This makes the output readable in the CLI and logs:
rows = [
    ("id", "name", "role"),
    (1, "Ivan", "admin"),
    (2, "Olga", "editor"),
]

for r in rows:
    print(f"{r[0]:<5} {r[1]:<10} {r[2]:<10}")


Debug expressions (Python 3.8+): {x=> displays the name and value of the variable, which speeds up debugging. Supports formatting of calculations:
x = 12
y = 7
print(f"{x=} {y=} {x*y=} x/y={x/y:.3f}")


Specifiers !r, !a: !r - repr(), !a - ascii() for unambiguous logs. Eliminates ambiguities in the output of objects:
path = "/var/data/config.yaml"
print(f"{path!r} {path!a}")  # repr and ascii()


Specifiers support width and padding, for example 08d for zeros. This is convenient for reports and IDs:
n = 42
print(f"{n:08d}")  # β†’ #00000042


You can access dictionaries and immediately calculate metrics, for example len():
data = {"user": "Ivan", "items": [1, 2, 3]}
print(f"{data['user&#39]}=Β», items={data['items&#39]}")
print(f"len(data['items&#39])={len(data['items&#39])}")


πŸ”₯ f-strings are a cool tool for formatting, logging, and debugging, if you apply them taking into account the version of Python and the context of the output.

πŸšͺ @DataScience4
Please open Telegram to view this post
VIEW IN TELEGRAM
❀3
Forwarded from PyData Careers
Python Clean Code: Stop Writing Bad Code β€” Lessons from Uncle Bob

Are you tired of writing messy and unorganized code that leads to frustration and bugs? You can transform your code from a confusing mess into something crystal clear with a few simple changes. In this article, we'll explore key principles from the book "Clean Code" by Robert C. Martin, also known as Uncle Bob, and apply them to Python. Whether you're a web developer, software engineer, data analyst, or data scientist, these principles will help you write clean, readable, and maintainable Python code.

Read: https://habr.com/en/articles/841820/

https://t.iss.one/CodeProgrammer 🧠
Please open Telegram to view this post
VIEW IN TELEGRAM
❀1
✨ relative import | Python Glossary ✨

πŸ“– Import modules from the same package or parent packages using leading dots.

🏷️ #Python
✨ GeoPandas Basics: Maps, Projections, and Spatial Joins ✨

πŸ“– Dive into GeoPandas with this tutorial covering data loading, mapping, CRS concepts, projections, and spatial joins for intuitive analysis.

🏷️ #intermediate #data-science
This channels is for Programmers, Coders, Software Engineers.

0️⃣ Python
1️⃣ Data Science
2️⃣ Machine Learning
3️⃣ Data Visualization
4️⃣ Artificial Intelligence
5️⃣ Data Analysis
6️⃣ Statistics
7️⃣ Deep Learning
8️⃣ programming Languages

βœ… https://t.iss.one/addlist/8_rRW2scgfRhOTc0

βœ… https://t.iss.one/Codeprogrammer
Please open Telegram to view this post
VIEW IN TELEGRAM
❀1
✨ transitive dependency | Python Glossary ✨

πŸ“– An indirect requirement of your project.

🏷️ #Python
✨ wildcard import | Python Glossary ✨

πŸ“– An import uses the star syntax to pull many names into your current namespace at once.

🏷️ #Python