StackOverflow.com

VN:F [1.9.22_1171]
Rating: 9.4/10 (10 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

Swift 6 only Combine crash

11 July 2025 @ 1:30 am

@globalActor public struct TestGlobalActor { public actor ActorType { } public static let shared: ActorType = ActorType() } final class TestCrash: XCTestCase { let subject = CurrentValueSubject<Int, Never>(1) @TestGlobalActor func testCrash() async throws { let cancellable = subject.sink { value in print("\(value)") } performSelector(inBackground: #selector(triggerSubject), with: nil) // Crashes //perform(#selector(triggerSubject), with: nil) // Does not crash try await Task.sleep(nanoseconds: 1000000000) _ = cancellable } @objc func triggerSubject() { subject.send(2) } } The above code crashes in Swift 6, not Swift 5. Change @TestGlobalActor to @MainActor, it still crashes Basically in Swift 6, If a Combine signal is sent from a different actor context than where the subscription was created

HTML tutorial confusion

11 July 2025 @ 1:28 am

I was following this tutorial https://www.youtube.com/watch?v=MLOBVhEuXHs&t=295s but the website in my github pages does not look like the one in the tutorial. What part am I doing wrong? Below is the link to my github repo which contains my index.html and index.css files. Your help and input would be much appreciated. https://github.com/joshuahbanderson1/Restaurant This is my output enter image description here

How can I prevent form spam from hitting my AWS Lambda endpoint via API Gateway?

11 July 2025 @ 1:26 am

I am using an AWS Lambda function with an API Gateway to send myself an email via Nodemailer when someone submits an HTML form on my website. Someone fills out a form on the website The frontend sends a POST to my Lambda function which sends the data to my email Here is the frontend code snippet. const message = await fetch('my invoke url',{ method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(data), }); I need to know how to stop someone from spamming this. As it is, my invoke url is exposed on the front end and someone can make as many requests as they would like. I am trying to find the best way to prevent this. Initially, I attempted to set up an API Usage Plan but thought it was unnecessary. I am currently using rate limiting within the API Gateway but it doesn't seem to do much. I am fairly new to this so I just need some

Duplicate OrderID detected error in MongoDB

11 July 2025 @ 1:22 am

I am getting this error in my console and I use unique for the OrderID, I have tried using UUID, counter and MongoDB code, after I create a first receipt any other one that follows return this message in the console and display internal Server error “ Receipt created successfully: ORD00001 About to save receipt with ID: ORD00002 Duplicate orderId ORD00002 detected, retrying... About to save receipt with ID: ORD00003 Duplicate orderId ORD00003 detected, retrying... About to save receipt with ID: ORD00004 Duplicate orderId ORD00004 detected, retrying... About to save receipt with ID: ORD00005 Duplicate orderId ORD00005 detected, retrying... About to save receipt with ID: ORD00006 Duplicate orderId ORD00006 detected, retrying..."”

Best way to parse a bunch of excel files, extract information (not placed uniformally) and get it all into one file

11 July 2025 @ 1:19 am

Helllo! I am currently trying to take a bunch of differnet-formatted excel files with information (Names, Jobs, Phone #s, Emails, etc) and turn them all into one large master sheet with a uniform formatting. I tried using python to automate this/solve this issue but I am having a lot of trouble getting my code to recognize specific data entries as a specific data type (mistaking a country for a name or a phone # for an email, etc) I am not that experienced at coding practically like this, but I was wondering if anyones done this before or has tips on how to create a tool that could do this. Thank You! (P.S. I've attached what ChatGPT and Me (mostly chat lol) have come up with) #!/usr/bin/env python3 import os import re import sys import datetime import pandas as pd # ─── USAGE & INPUT PATH ───────────────────────────────────────────────────�

Google sheets setting columns range in app script

11 July 2025 @ 1:14 am

I have this worksheet that im working on: https://docs.google.com/spreadsheets/d/1u_CafEOKNLtthpWaXVo37BKiuRHQ2oGEC4liqkTmXuY/edit?usp=drivesdk and I have this script: function createWhatsAppHyperlink() { const sheetName = "FollowUp"; // Please set the sheet name. const sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName(sheetName); var lastRow = sheet.getLastRow(); var dataRange = sheet.getRange(3, 1, lastRow - 1, 2) var data = dataRange.getValues(); var whatsappLinks = []; for (var i = 0; i < data.length; i++) { var phoneNumber = data[i][1]; // * column B (index 1) let message = "Hey, let's workout!" ${data[i][0]}, var whatsappLink = "https://api.whatsapp.com/send?phone=" + phoneNumber + "&text=" + encodeURIComponent(message

PyCharm deduces type of overridden __floordiv__ as Union of actual return type and that of the superclass?

11 July 2025 @ 1:04 am

Given the following code: class A(int): def __floordiv__(self, *args, **kwargs) -> "A": return A(super().__floordiv__(*args, **kwargs)) def __mod__(self, *args, **kwargs): return A(super().__mod__(*args, **kwargs)) # results are the same whether we override this or not def __new__(cls, *args, **kwargs): return super().__new__(cls, *args, **kwargs) a = A(3) b = a // 2 why does hovering over b in PyCharm 2023.2.3 (Community Edition) display b: Union[A, int] = a // 2 when (to my understanding) the type of b should simply be A? (The type of a is correctly displayed as A btw) // can never call any other dunder, correct? And *args + **kwargs should override all signatures of __floordiv__ from int? Likely related, why is the -> "A" required? That is to ask, w

I already have VS Code installed and have been using it for weeks. Now this keeps popping up. I seem to be able to use it fine though

11 July 2025 @ 1:01 am

The error screenshot This is the issue im getting. From what I can find online, it mostly comes up when first installing VS Code, but like I said I've had it for weeks and it doesnt seem to be preventing or doing anything. But nevertheless, it's annoying flashing in my taskbar. I tried clicking Try Again and it doesnt work.

Unable to download Robot Framework using PIP

11 July 2025 @ 12:38 am

I am new in automation testing. I already installed python. I already checked the python and pip version. But I am unable to install robot framework using the command prompt. I am getting an error message, " pip is not recognized as internal or external command" Can anyone please help me enter image description here

I need to delete my Google Workspace Account is there any code we need to do or whatever we need to do? [closed]

10 July 2025 @ 11:42 pm

I need to delete my Google Workspace account however this is the prompt I am receiving Cancel subscriptions and delete Google Cloud resources, and Marketplace Apps (Required) You must complete the following before you can delete sq**********.com's account. Learn more about these steps error Delete Google Cloud resources sq*************.com has at least 1 Google Cloud resource. Learn how to delete Google Cloud resources I go to Google cloud, and I have this Google Cloud resources. Folder Name: sq*************.com ID: 894365078936 July 11, 2025 — — Folder Name: system-gsuite ID: 244986884542 July 11, 2025 I tried to delete system-gsuite and this prompted an error: Folder Service Folder cannot be deleted as it contains active resources. Only empty folders can be deleted. Request ID: 8190421869818546886 I accidentally created this by enabling the api that something I don't even know. The delete option is greyed out and the prompt is: M

jsfiddle.net

VN:F [1.9.22_1171]
Rating: 9.0/10 (2 votes cast)

A playground for web developers, use it as an online editor for snippets built from HTML, CSS and JavaScript. The code can then be shared with others, embedded on a blog, etc.

SmashingMagazine.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (6 votes cast)

Digital media magazine for designers and developers
Web design plus tips and tricks.

Unmasking The Magic: The Wizard Of Oz Method For UX Research

10 July 2025 @ 10:00 am

The Wizard of Oz method is a proven UX research tool that simulates real interactions to uncover authentic user behavior. Victor Yocco unpacks the core principles of the WOZ method, explores advanced real-world applications, and highlights its unique value, including its relevance in the emerging field of agentic AI.

Droip: The Modern Website Builder WordPress Needed

8 July 2025 @ 10:00 am

Traditional page builders have shaped how we build WordPress sites for years. Let’s take a closer look at [Droip](https://droip.com/), a modern, no-code visual builder, and explore how it redefines the experience with cleaner performance, full design freedom, and zero plugin dependency.

Design Guidelines For Better Notifications UX

7 July 2025 @ 1:00 pm

As always in design, timing matters, and so do timely notifications. Let’s explore how we might improve the notifications UX. More design patterns in our Smart Interface Design Patterns, a friendly video course on UX and design patterns by Vitaly — from complex data tables and nested filters to FAQs and error messages.

CSS Intelligence: Speculating On The Future Of A Smarter Language

2 July 2025 @ 1:00 pm

CSS has evolved from a purely presentational language into one with growing logical powers — thanks to features like container queries, relational pseudo-classes, and the `if()` function. Is it still just for styling, or is it becoming something more? Gabriel Shoyombo explores how smart CSS has become over the years, where it is heading, the challenges it addresses, whether it is becoming too complex, and how developers are reacting to this shift.

Turning User Research Into Real Organizational Change

1 July 2025 @ 10:00 am

Bridging the gap between user research insights and actual organizational action — with a clear roadmap for impact.

Never Stop Exploring (July 2025 Wallpapers Edition)

30 June 2025 @ 12:00 pm

July is just around the corner, and that means it’s time for a new collection of desktop wallpapers. Created with love by artists and designers from across the globe, they are bound to bring some good vibes to your screen. Enjoy!

Can Good UX Protect Older Users From Digital Scams?

25 June 2025 @ 12:00 pm

As online scams become more sophisticated, Carrie Webster explores whether good UX can serve as a frontline defense, particularly for non-tech-savvy older users navigating today’s digital world.

Decoding The SVG <code>path</code> Element: Curve And Arc Commands

23 June 2025 @ 10:00 am

On her quest to teach you how to code vectors by hand, Myriam Frisano’s second installment of a `path` deep dive explores the most complex aspects of SVG’s most powerful element. She’ll help you understand the underlying rules and function of how curves and arcs are constructed. By the end of it, your toolkit is ready to tackle all types of tasks required to draw with code — even if some of the lines twist and turn.

Meet Accessible UX Research, A Brand-New Smashing Book

20 June 2025 @ 4:00 pm

Meet “Accessible UX Research,” our upcoming book to make your UX research inclusive. Learn how to recruit, plan, and design with disabled participants in mind. Print shipping in August 2025. eBook available for download later this summer. Pre-order the book.

CSS Cascade Layers Vs. BEM Vs. Utility Classes: Specificity Control

19 June 2025 @ 3:00 pm

CSS can be unpredictable — and specificity is often the culprit. Victor Ayomipo breaks down how and why your styles might not behave as expected, and why understanding specificity is better than relying on `!important`.

stackblitz.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (2 votes cast)

Create, edit & deploy fullstack apps — in just one click. From Angular to React or even just HTML, JS and CSS.

firebase.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (2 votes cast)

An on-line real-time database for your apps.

#FirebaserFriday: Frank van Puffelen

18 March 2022 @ 3:58 pm

Paulette McCroskey Social Media Manager, Advanced Systems Group, LLC

How Firebase Performance Monitoring optimized app startup time

9 March 2022 @ 4:58 pm

Viswanathan Munisamy Software Engineer

Using Machine Learning to optimize mobile game experiences

15 February 2022 @ 4:58 pm

Sachin Kotwani Senior Product Manager Elvis Sun Software Engineer Mobile app and game developers can use on-device machine learning in their apps to increase user engagement and grow revenue. We worked with game developer HalfBrick to train and implement a custom model that personalized the user's in-game experience based on the player's skill level and session details, resulting in increased interactions with

Accept Payments with Cloud Firestore and Google Pay

11 February 2022 @ 8:00 pm

Stephen McDonald Developer Relations Engineer, Google Pay Back in 2019 we launched Firebase Extensions - pre-packaged solutions that save you time by providing extended functionality to your Firebase apps, without the need to research, write, or debug code on your own. Since then, a ton of extensions have been added to the platform covering a wide range of features, from email triggers and text messaging, to image resizing, translation, and much more. Google Pay Firebase Extension We're now

Everything you need to know about Remote Config’s latest personalization feature

26 January 2022 @ 6:22 pm

Jon Mensing Product Manager An important part of turning your app into a business is to optimize your user experience to drive the bottom line results you want. A popular way to do this is through manual experimentation, which involves setting up A/B tests for different components of your app and finding the top performing variant. Now, you can save time and effort - and still maximize the objectives you want - with Remote Config’s latest personalization feature. Personalization harnesses the power of machine learning to automatically find the optimal e

What’s new at Firebase Summit 2021

10 November 2021 @ 5:31 pm

Kristen Richards Group Product Manager

Automate your pre-release testing with the App Distribution REST API

8 November 2021 @ 5:59 pm

Liat Berry Product Manager

Improving the Google Analytics dashboard in Firebase

5 November 2021 @ 6:03 pm

Sumit Chandel Developer Advocate If you’ve visited the Firebase console’s Analytics section recently, you might have noticed something new… an updated Analytics dashboard, a new Realtime view and a few other UI enhancements.

How to get better insight into push notification delivery

27 October 2021 @ 3:45 pm

Charlotte Liang Charlotte Liang Software Engineer

Pinpointing API performance issues with Custom URL Patterns

20 October 2021 @ 3:45 pm

Ibrahim Ulukaya Ibrahim Ulukaya Developer Advocate

bitbucket.org

VN:F [1.9.22_1171]
Rating: 8.4/10 (5 votes cast)

The alternative to Github, private and open git repositories.