« first day (4009 days earlier)      last day (9 days later) » 

12:16 AM
REFRESH! There are 6229 unanswered questions (91.9710 answered)
 
 
5 hours later…
5:43 AM
0
Q: Display summary statistics about Discord messages

CareeeBuggerThis is just a program that displays summary statistics about discord messages sent to a certain user using a Discord data package. The CSV of messages to a user is "c{idOfChannel}\messages.csv". Its formatted as: ID,Timestamp,Contents,Attachments I'm semi-new to programming and have always been...

 
6:30 AM
Nobody is asking you to prostrate yourself. But Stack Overflow isn't a site where someone will debug a large program for you. You need to break it down into smaller pieces so you can isolate the actual problem, and ask about that as an MVE. A code review is off topic here; once your program is working you could ask for one on codereview.stackexchange.com. — amalloy 50 secs ago
 
6:49 AM
codereview.stackexchange.com looks like a better forum for these sorts of questions — Sam Mason 54 secs ago
 
7:03 AM
Please visit the help center, take the tour to see what and How to Ask. If you do not want to be voted down, DO AS IS ASKED. In this case, what is the question? If you are asking if your working code is a good idea, then it is for codereview and not stackoverflow. If you have an error, explain what the error is and what you tried to fix it. — mplungjan 48 secs ago
 
 
2 hours later…
8:57 AM
@Harith @Phroggie @SᴀᴍOnᴇᴌᴀ I would argue that github (and gitlab) workflows constitute code in the same way that makefiles do
And in the same way dockerfiles do, while we're at it
 
9:09 AM
@Vogel612 Makefile and Dockerfiles literally run shell scripts.
 
strictly speaking these workflow automations do the same. It's just that these scripts are abstracted into workflow actions (or steps or whatever the abstraction is)
 
@Vogel612 Where are the shell commands in the workflow? I can show you shell commands in a Dockerfile
FROM python:3 AS builder
WORKDIR /build

RUN python -m pip install virtualenv
RUN python -m virtualenv venv
COPY requirements.txt requirements.txt
RUN venv/bin/python -m pip install -r requirements.txt
# invalidates the cache
COPY . .
RUN venv/bin/python -m pip install .
 
 [...]
    steps:
  - name: Setup MSYS2
    uses: msys2/setup-msys2/@v2
    with:
      update: true
      install: >-
        git
        make
        gcc
  - name: Checkout
    uses: actions/checkout@v4
  - name: Build
    run: make CC=gcc
  - name: Test
    run: make CC=gcc test
the run: commands are shell
 
Ok, you've convinced me.
 
Wonderful, I am undeleting my question.
 
 
2 hours later…
11:02 AM
0
Q: Preferable c++ searching method or function for vector of structure

Vidhi TrivediI am trying to search the element of structure from vector of that structure which has size 1000 and it need to be searched frequently so suggest the best preferred method to find that element from large vector which is faster and optimized for (size_t i {0};i < vector.size() ; i++) { if ((firstE...

 
11:47 AM
0
Q: Is it good to have thread for each background task

Ankit TiwariI found following code from this horilla repository from threading import Thread class MailSendThread(Thread): """ MailSend """ def __init__(self, request, result_dict, ids): Thread.__init__(self) self.result_dict = result_dict self.ids = ids sel...

 
12:10 PM
1
Q: basic python rock papers scissors (first code)

Mah NehI'd just appreciate if anyone can suggest some incremental improvements that would help me to think better like a coder. Here is the very basic RPS (rock, paper, scissors.) One thing I may next add is some tests. import random import sys from enum import Enum welcome=''' Enter 1 for Rock, 2 for ...

 
12:51 PM
possible answer invalidation by toolic on question by Mah Neh: codereview.stackexchange.com/posts/291740/revisions
 
@Duga: just fixed code fence as usual
 
possible answer invalidation by toolic on question by Mah Neh: codereview.stackexchange.com/posts/291740/revisions
 
1:18 PM
0
Q: Fastest way of finding if current user has access to a folder with Powershell

Tanaka SaitoI have a Powershell script that selects a random file in a lab environment and then reads, writes, creates, and deletes files to simulate a live environment. This lab also includes folders that I don't have access to. When I perform these file actions I pick a folder at random, which can sometime...

 
1:41 PM
0
Q: Rust Observer/Subscriber design pattern

HarryI have written a sample Observer/Subscriber design pattern where, in my application there is a networ_receiver thread, mq_processor thread and 3 subscriber threads. Each of the subscriber will subscribe to multiple messages (distinguished by message ID). Upon reception of network data network_rec...

0
Q: Find minimum element plus index between 8 zmm registers

BalthasarI want to find the first minimal element and its index of a 64 element long array with the avx512 instuction set. The code works and is much faster than the equivalent C code (I have this code embedded with inline asm in cpp and tested against an equivalent written in pure C), however I feel this...

 
2:13 PM
Questions about code improvements belong on codereview.stackexchange.com0stone0 45 secs ago
 
2:26 PM
0
Q: How to apply another styles to reusable react component in mui

AndrianIn my case button is a reusable component. It can be green with white text or white with green text and border. Currently it works, but I'm looking for a better mui solution. Page: <MainButton title="Login" /> <MainButton title="Register" additionalStyles={{ backgroundColor:

 
3:11 PM
0
Q: How can I decouple my parsing logic from event handlers?

Josh HallowI have a console application which acts as a game server. The server has many events (incoming data basically) that need to be handled. Some events (most) have data associated. I want to know how I can decouple the parsing from the handlers and somehow have the data ready and parsed by the time i...

 
3:57 PM
0
Q: ES6 inner join equivalent

knot22Using the sample data from here I'm attempting to write JS code (to the ES6 standard) that is equivalent to a SQL inner join. The solution below works fine but it seems rather long. Is there a more concise approach? const employees = [ {name: 'Alice', department_id: 12}, {name: 'Bob...

 
Monking
 
5:05 PM
0
Q: A recursive_flatten Template Function Implementation in C++

JimmyHuThis is a follow-up question for A Summation Function For Boost.MultiArray in C++, A recursive_minmax Template Function Implementation in C++ and A recursive_reduce_all Template Function Implementation in C++. I am trying to implement a function which can make nested container be flattened and th...

 
5:35 PM
Monking
 
6:20 PM
maybe it would need more changes in code - but it would need to see full code. If code is working then eventually you could send it to similar portal for CodeReviewfuras 1 min ago
 
 
4 hours later…
10:01 PM
0
Q: multithreaded c++ code: thread safety and synchronization (data races)

Simon#include <iostream> #include <thread> #include <vector> #include <mutex> #include <stdexcept> struct Data { int x{0}; double y{0.0}; }; class MyClass { public: void run() { // do some work printData(); } void printData() const { std::cout << "x: " <<...

 

« first day (4009 days earlier)      last day (9 days later) »