Bash(python3 /tmp/claude/summarize-session2.py 2>&1) ⎿ Total: 0 human messages, 339 assistant messages Only assistant messages. The user messages might have a different format. Let me check the structure: [...] It’s “type”: “user” not “human”. 🤔 ...
Peter Blom’s Post
More Relevant Posts
-
Just shipped diskdump - fast, deduplicated raw disk capture over plain SSH. This is not a traditional backup tool - there are plenty of mature solutions for that. The use case here is different: 👉 You have multiple (often similar) machines 👉 You want to quickly grab full raw disks (/dev/sda) 👉 Store them efficiently 👉 Reuse, rehydrate, or analyze them locally (e.g. for forensics) That's where diskdump fits. Instead of repeatedly copying entire disks, it uses content-addressable deduplication across machines and time. How it works: • Ships a zero-dependency Python script over SCP • Streams the disk and hashes 128KB blocks • Checks what already exists locally • Transfers only new data (compressed over SSH) • Stores everything in a shared block store + lightweight manifests Why it matters: • Dump 10 similar servers → you don't store 10× the data • Repeated captures of the same host → near-zero transfer after the first run • Single-pass streaming → no temp files, minimal footprint on remote systems Example: Dump multiple machines in parallel diskdump dump server01:/dev/sda server02:/dev/sda Restore / rehydrate diskdump restore 2026/04/24/server01-sda.manifest | dd of=/dev/sda Or mount/analyze locally for investigations, diffing, or debugging. No agents. No daemon. Just SSH + Python. Dependencies: • Remote: Python 3 (stdlib only) • Local: Python 3 + lz4 Source: https://lnkd.in/dGHvWMQc #python #devops #forensics #incidentresponse #sysadmin #opensource
To view or add a comment, sign in
-
𝗗𝗮𝘆 𝟲𝟳/𝟳𝟱 | 𝗟𝗲𝗲𝘁𝗖𝗼𝗱𝗲 𝟳𝟱 𝗣𝗿𝗼𝗯𝗹𝗲𝗺: 338. Counting Bits 𝗗𝗶𝗳𝗳𝗶𝗰𝘂𝗹𝘁𝘆: Easy 𝗣𝗿𝗼𝗯𝗹𝗲𝗺 𝗦𝘂𝗺𝗺𝗮𝗿𝘆: Given an integer n, return an array where each index i (0 ≤ i ≤ n) contains the number of 1’s in the binary representation of i. 𝗠𝘆 𝗔𝗽𝗽𝗿𝗼𝗮𝗰𝗵: This problem is solved efficiently using Dynamic Programming with bit manipulation. Instead of converting each number to binary separately, we reuse previously computed results. • Key Observation: – Right shifting a number (i >> 1) removes the last bit – (i & 1) tells whether the last bit is 1 or 0 • Transition: – ans[i] = ans[i >> 1] + (i & 1) This means: Take the count of 1’s from i/2 and add 1 if the current number is odd. • Base Case: – ans[0] = 0 • Final answer: – Array ans of size n + 1 This avoids repeated binary conversions and builds the solution in a bottom-up manner. 𝗖𝗼𝗺𝗽𝗹𝗲𝘅𝗶𝘁𝘆 𝗔𝗻𝗮𝗹𝘆𝘀𝗶𝘀: • Time Complexity: O(n) • Space Complexity: O(n) 𝗞𝗲𝘆 𝗧𝗮𝗸𝗲𝗮𝘄𝗮𝘆: Problems involving binary representations often have patterns that can be reused. Bit manipulation + DP is a powerful combination for optimizing such computations. 𝗤𝘂𝗲𝘀𝘁𝗶𝗼𝗻 𝗟𝗶𝗻𝗸: https://lnkd.in/gydkB_rv #Day67of75 #LeetCode75 #DSA #Java #Python #DynamicProgramming #BitManipulation #MachineLearning #DataScience #ML #DataAnalyst #LearningInPublic #TechJourney #LeetCode
To view or add a comment, sign in
-
-
Day 6/30 Some concepts look basic… but they are the foundation of real-world systems. 🔹 Problem: Create a simple login system (check username & password) 🔹 What I focused on today: Understanding how validation and conditions work together 🔹 My Thinking Process: Store a predefined username and password Take input from user Compare input with stored values Display success or error message 👉 Small logic, but widely used in real applications 🔹 Inputs I used: Username Password 🔹 Code: Stored_username = "admin" Stored_password = "1234" username = input("Enter username: ") password = input("Enter password: ") if username == Stored_username and password == Stored_password: print("Login Successful!") else: print("Invalid Username or Password") 🔹 Example: Username = admin Password = 1234 Output → Login Successful 🔹 Key Takeaway: Even simple programs can represent real-world systems like authentication, which rely heavily on condition checking #Day6 #Python #30DaysOfCode #LearningInPublic #DataAnalytics #ProblemSolving
To view or add a comment, sign in
-
-
Day 30 of #100DaysOfPython 𝐔𝐩𝐠𝐫𝐚𝐝𝐞𝐝 𝐭𝐡𝐞 𝐏𝐚𝐬𝐬𝐰𝐨𝐫𝐝 𝐌𝐚𝐧𝐚𝐠𝐞𝐫 𝐀𝐩𝐩 𝐭𝐨𝐝𝐚𝐲. I moved from saving data in a text file to using JSON, which makes the data more structured and easier to manage. I also added a search feature to retrieve saved credentials. 𝐖𝐡𝐚𝐭 𝐈 𝐢𝐦𝐩𝐫𝐨𝐯𝐞𝐝: 𝑺𝒘𝒊𝒕𝒄𝒉𝒆𝒅 𝒕𝒐 𝑱𝑺𝑶𝑵 𝒇𝒐𝒓 𝒔𝒕𝒓𝒖𝒄𝒕𝒖𝒓𝒆𝒅 𝒅𝒂𝒕𝒂 𝒔𝒕𝒐𝒓𝒂𝒈𝒆 𝑰𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕𝒆𝒅 𝒔𝒆𝒂𝒓𝒄𝒉 𝒇𝒖𝒏𝒄𝒕𝒊𝒐𝒏𝒂𝒍𝒊𝒕𝒚 𝒇𝒐𝒓 𝒔𝒂𝒗𝒆𝒅 𝒑𝒂𝒔𝒔𝒘𝒐𝒓𝒅𝒔 𝑯𝒂𝒏𝒅𝒍𝒆𝒅 𝒆𝒓𝒓𝒐𝒓𝒔 𝒖𝒔𝒊𝒏𝒈 𝒕𝒓𝒚/𝒆𝒙𝒄𝒆𝒑𝒕 (𝒎𝒊𝒔𝒔𝒊𝒏𝒈 𝒇𝒊𝒍𝒆, 𝒎𝒊𝒔𝒔𝒊𝒏𝒈 𝒅𝒂𝒕𝒂, 𝒆𝒎𝒑𝒕𝒚 𝑱𝑺𝑶𝑵) 𝑰𝒎𝒑𝒓𝒐𝒗𝒆𝒅 𝒐𝒗𝒆𝒓𝒂𝒍𝒍 𝒖𝒔𝒆𝒓 𝒆𝒙𝒑𝒆𝒓𝒊𝒆𝒏𝒄𝒆 𝒊𝒏 𝒕𝒉𝒆 𝑮𝑼𝑰 This version feels much closer to a real application. Managing data properly and handling edge cases made a big difference. Also a good reminder that writing code is one thing, but making it robust and user-friendly is another level. #100DaysOfCode #100DaysOfPython #Python #Tkinter #PasswordManager #JSON #ErrorHandling #PythonProjects #LearningToCode #CodingJourney #BuildInPublic
To view or add a comment, sign in
-
Claude Opus 4.7 just dropped and I have to say I am disappointed. Poor Behaviors from today: - Asking questions in plan mode then completely ignoring the answers when generating the code. "I'm sorry I was exercising an abundance of caution when ignoring your answer" (note I asked it not to build an image on every single code commit) - Creating wildly elaborate and hacky solutions to simple problems. claude wanted to insert a bash script into cicd to manually traverse a node repo and hack in version.ts files to fix an issue where a module depending on another that hadn't been built yet. "You are right. That is an overly complicated solution and not appropriate for production builds" - Choosing to write elaborate python scripts and asking permission to execute for very simple plugin tasks like doing a code diff from a pr. "You are right, I should just use the gh plugin"
To view or add a comment, sign in
-
Manual status checking is a time sink. I recently built a small desktop tool to simplify how a client tracks application status from Excel. Instead of jumping between systems and doing repetitive checks, this tool: • Lets you upload an Excel file • Selects the relevant sheet • Processes and updates status in one go • Tracks progress in real-time The goal was simple: reduce manual effort to a few clicks. The challenging part wasn’t just the logic—it was making it usable: • Clean, minimal GUI (so anyone can use it) • Packaged into a standalone .exe (no Python setup needed) • Handles real-world messy data Sharing a quick look at the interface below 👇 Always interesting how small tools like this can save hours of repetitive work. #Python #webscraping #Automation #DesktopApp #Productivity #PyInstaller
To view or add a comment, sign in
-
-
𝗗𝗮𝘆 𝟲𝟱/𝟳𝟱 | 𝗟𝗲𝗲𝘁𝗖𝗼𝗱𝗲 𝟳𝟱 𝗣𝗿𝗼𝗯𝗹𝗲𝗺: 72. Edit Distance 𝗗𝗶𝗳𝗳𝗶𝗰𝘂𝗹𝘁𝘆: Medium 𝗣𝗿𝗼𝗯𝗹𝗲𝗺 𝗦𝘂𝗺𝗺𝗮𝗿𝘆: Given two strings word1 and word2, compute the minimum number of operations required to convert word1 into word2. Allowed operations: • Insert a character • Delete a character • Replace a character 𝗠𝘆 𝗔𝗽𝗽𝗿𝗼𝗮𝗰𝗵: This is a Dynamic Programming problem. • Define a 2D DP array where dp[i][j] represents the minimum operations needed to convert the first i characters of word1 to the first j characters of word2 • Initialization: – dp[i][0] = i → delete all characters – dp[0][j] = j → insert all characters • Transition: – If characters match: dp[i][j] = dp[i-1][j-1] – If characters differ: dp[i][j] = 1 + min( dp[i-1][j-1], // replace dp[i-1][j], // delete dp[i][j-1] // insert ) • Final answer: dp[m][n] This works because at each step, we choose the optimal operation among insert, delete, or replace based on previously computed subproblems. 𝗖𝗼𝗺𝗽𝗹𝗲𝘅𝗶𝘁𝘆 𝗔𝗻𝗮𝗹𝘆𝘀𝗶𝘀: • Time Complexity: O(m × n) • Space Complexity: O(m × n) 𝗞𝗲𝘆 𝗧𝗮𝗸𝗲𝗮𝘄𝗮𝘆: When transforming one string into another, think in terms of prefix transformations and build solutions bottom-up using DP. Problems involving string edits often reduce to comparing characters and choosing optimal operations. 𝗤𝘂𝗲𝘀𝘁𝗶𝗼𝗻 𝗟𝗶𝗻𝗸: https://lnkd.in/g8MzA3Rm #Day65of75 #LeetCode75 #DSA #Java #Python #DynamicProgramming #MachineLearning #DataScience #ML #DataAnalyst #LearningInPublic #TechJourney #LeetCode
To view or add a comment, sign in
-
-
A Python function that checks stationarity across multiple financial symbols—a critical step anyone serious about algorithmic trading should master. Why does it matter? Many profitable strategies (mean reversion, pairs trading, cointegration) assume stationary data. If your underlying series is non-stationary (trending), your strategy will fail spectacularly. The approach: I'm using dual statistical tests—ADF and KPSS—because relying on just one can be misleading. Both must agree for a true verdict. What it does: ✓ Downloads price data from any symbol ✓ Tests both raw prices and log returns ✓ Returns p-values + actionable verdict ✓ Works with local CSV files too This is table-stakes for quant work. Whether you're building mean-reversion bots or testing factor strategies, validating stationarity upfront saves months of debugging DOA strategies. github: Chinedum14/Quant-Dev Happy building! 📈 #QuantTrading #AlgorithmicTrading #DataScience #Python #TimeSeries #SoftwareEngineering #Developer
To view or add a comment, sign in
-
-
pyload, Insufficient Session Expiration, CVE-2023-0227 (Medium) Technical Analysis: How CVE-2023-0227 Works CVE-2023-0227 is an Insufficient Session Expiration vulnerability affecting pyload, an open-source download manager written in Python. The root cause is the application's failure to properly invalidate user sessions when permissions are changed or a user logs out. The Flaw in Session Management 1. Session Persistence After Logout: When a user logs out, their session token remains valid in the backend session store (e.g., filesystem cache)....
To view or add a comment, sign in
-
pyload, Insufficient Session Expiration, CVE-2023-0227 (Medium) Technical Analysis: How CVE-2023-0227 Works CVE-2023-0227 is an Insufficient Session Expiration vulnerability affecting pyload, an open-source download manager written in Python. The root cause is the application's failure to properly invalidate user sessions when permissions are changed or a user logs out. The Flaw in Session Management 1. Session Persistence After Logout: When a user logs out, their session token remains valid in the backend session store (e.g., filesystem cache)....
To view or add a comment, sign in
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development