34
top 2 comments
sorted by: hot top controversial new old
[-] cy_narrator@discuss.tchncs.de 2 points 2 months ago* (last edited 2 months ago)
try:
    import pandas
except:
    print("You did not install pandas, let me do it for you")
    import os
    os.system("pip install pandas")

Here is some cursed error handling

[-] ExperimentalGuy@programming.dev 2 points 2 months ago

This is beautiful, but what would be even better is to have the program open a reverse shell so you can log into the computer to install pandas manually.

this post was submitted on 07 Oct 2024
34 points (94.7% liked)

Python

6478 readers
1 users here now

Welcome to the Python community on the programming.dev Lemmy instance!

📅 Events

PastNovember 2023

October 2023

July 2023

August 2023

September 2023

🐍 Python project:
💓 Python Community:
✨ Python Ecosystem:
🌌 Fediverse
Communities
Projects
Feeds

founded 2 years ago
MODERATORS