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.

BPMN to Petri nets converter or any other tool for verification

25 April 2024 @ 11:17 pm

My goal is to transfer a BPMN model to any workflow tool that will allow me to verify it. I learned about Petri nets, so I want to be able to transform an XML file I obtained after creating a BPMN model into a Petri net. Is there a tool for doing this? I kept finding some scientific papers from The Netherlands but they are decades old and the websites for source code do not work. I'd appreciate any help.

Get the Entra (AzureAD) Login name from a WinForm Application

25 April 2024 @ 11:16 pm

I have written a Windows Task Tray Application using WinForms. This works fine. This application is a local agent for a SaaS offering. For licensing purposes, I want to be able to match the logged in user to the SaaS subscribers' users. This is where the trouble starts. Users log into their desktop Windows PC using their Entra ID, which is in the form of "[email protected]". In the Task tray application, I use the Environment.UserName and Environment.UserDomainName which give firstnamelastname and "AzureAD" respectively. Users are known in the SaaS by their Entra login "[email protected]", so I need to go from the local representation to the SaaS value for usage tracking. My task tray application agent does not require a separate login since the user is logged into Windows desktop and I want to keep it that way. The Task Tray authenticates to the SaaS using cert based authentication. I would prefer not

Django Static files Permission Issue on nginx

25 April 2024 @ 11:15 pm

i want to deploy my Django project on linux vps but i have a problem and the problem is my nginx denies the permission for opening the static files i found this error in error.log file: open() "/home/sam/testdjango/static/admin/js/nav_sidebar.js" failed (13: Permission denied>) this is my nginx.conf file: user www-data; worker_processes auto; pid /run/nginx.pid; include /etc/nginx/modules-enabled/*.conf; events { worker_connections 768; # multi_accept on; } http { ## # Basic Settings ## sendfile on; tcp_nopush on; types_hash_max_size 2048; # server_tokens off; # server_names_hash_bucket_size 64; # server_name_in_redirect off; include /etc/nginx/mime.types; default_type application/octet-stream; ## # SSL Settings ## ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref:

Flutter, selecting int and double values via a selector wheel and Parsing them from one page to another

25 April 2024 @ 11:14 pm

I'm trying to select a height (int) and weight (double) value on one page using a selector wheel widget and then sending it to another page to display and eventually use the values in calculations. I tried parsing the variables via the constructors but they stay stuck at 0 or 0.0 no matter what. I'm not sure if the issue come from the selector wheel not saving my choice or the parsing setting the value to 0 at some point Here are the different pages involved, they're separated in multiple .dart files: main.dart: import 'package:appli_teeshirt/pages/profile.dart'; import 'package:appli_teeshirt/pages/bt_connect.dart'; import 'package:appli_teeshirt/pages/historique.dart'; import 'package:appli_teeshirt/pages/page_accueil.dart'; import 'package:flutter/material.dart'; final GlobalKey<_MyappState> myAppKey = GlobalKey<_MyappState>(); void main() { runApp(Myapp(key: myAppKey)); } class Myapp extends StatefulWidget { const Myapp({Key

Pandas how to Identify strings in my dataframe

25 April 2024 @ 11:13 pm

Let's say I have a dataframe like this: import pandas as pd import numpy as np df = pd.DataFrame([[1, np.nan, 2], [2, 3, 'I'], [3, 4, 'II']], columns=['A', 'B', 'C']) df how do I identify all the strings exclude null values and if it's a roman number, convert it into the integer correspond to this roman number? I tried res = np.argwhere(df_pre.values.astype('str')) to locate the coordination of string but it includes the null values.

OAuth2 with Trino REST API

25 April 2024 @ 11:13 pm

For JDBC or Trino Cli, we can use the externalAuthentication flag to trigger authentication. How would this work for Trino REST API? Is there such option available as query parameter or request header?

docker laravel mysql permission denied

25 April 2024 @ 11:13 pm

I am dockerizing my laravel application but I am getting this error SQLSTATE[HY000] [1045] Access denied for user 'root'@'172.18.0.3' (using password: YES) (SQL: select * from information_schema.tables where table_schema = testdb and table_name = migrations and table_type = 'BASE TABLE') docker-compose.yml version: "3.8" services: # PHP Service php: build: context: . target: php args: - APP_ENV="${APP_ENV}" environment: - APP_ENV="${APP_ENV}" - CONTAINER_ROLE=app working_dir: /var/www volumes: - ./:/var/www ports: - 8000:8000 depends_on: - database database: image: mysql:8.2 ports: - 3306:3306 environment: - MYSQL_DATABASE=${DB_DATABASE} - MYSQL_USER=${DB_USERNAME} - MYSQL_PASSWORD=${DB_PASSWORD} - MYSQL_ROOT_PASSWORD=${DB_PASSWORD} volumes:

EJS, Node.js: Trying to submit a patch request from a form doesn't reach routing function

25 April 2024 @ 11:12 pm

I'm trying to submit a form from an EJS module using the method "patch", but I'm not getting expected results. I'm using a Postgres database, but I don't know if that matters because of the feedback I'm getting. Here is a simplified version of my problem: EJS <form action="/edit/<%= book.isbn %>" method="patch"> <label for="rating">Rating: </label ><input type="number" id="rating" name="rating" value="<%= book.rating %>" required /> <button type="submit">Submit</button> </form> index.js import express from 'express'; import bodyParser from 'body-parser'; import pg from 'pg'; const app = express(); const port = 3000; const db = new pg.Client({ user: 'postgres', host: 'localhost', database: '

Delete parent when child is deleted joint inheritance mapping strategy

25 April 2024 @ 11:12 pm

Can anyone help with this issue. It's my first time using spring boot, I'm trying to implement inheritance using Joined inheritance strategy. I've created an entity called AuditTrackable which is a superclass and User which is a subclass. Its all working well but when I delete a user, the row is deleted from the user table but when I check in the audittrackable table, the corresponding row referenced by the user_id is still is still appearing. I've a lot of deleted users whose ids are still appearing in the parent table(audittrackable). I would want the delete operation on the user entity to cascade to the parent entity so that a user is completely deleted. Any assistance will greatly be appreciated. @Data @AllArgsConstructor @NoArgsConstructor @Inheritance(strategy=InheritanceType.JOINED) public class AuditTrackable { @Id @GeneratedValue(strategy = GenerationType.AUTO) private Long id; private String status; @Column(updatable=false) @CreationTimestamp

Spring boot : is it possible to include auto configurations in Test classes?

25 April 2024 @ 11:11 pm

I'm writing some Spring boot tests. When using @SpringBootTest, it works fine, I got all auto configurations classes from spring jars. But I don't want to load the whole application context from @SpringBootApplication For example I'm testing spring batch layer. I would like to benefit from all spring batch autoconfiguration. Here's my test class : @ContextConfiguration(classes = BankBatchApplicationTests.TestConfig.class) @SpringBatchTest @EnableAutoConfiguration class BankBatchApplicationTests { @ComponentScan("com.example") static class TestConfig { } But it seems my test class isn't picking up auto configuration from spring-batch. Obviously when I use @SpringBootTest it works fine Another solution would be to use @SpringBootTest, picking up my main @SpringBootApplication Application class. But I don't want to include other configurations classes scanned

odysee.com

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

Less censorship more entertainment. Alternative YouTube.

mewe.com

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

Social networks without the ads and invasion of privacy, alternative to Facebook.

Hopefully it will stay this way.

who-called.co.uk

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

Who called me, check with others to see if you have a scam caller.

freedomcells.org

VN:F [1.9.22_1171]
Rating: 9.0/10 (1 vote cast)

Freedom Cells are peer to peer groups organising themselves in a decentralised manner with the collective goal of asserting the sovereignty of group members through peaceful resistance and the creation of alternative institutions.

rumble.com

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

Another alternative to the censorship of YouTube.

en.whotwi.com

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

Graphical twitter user statistics

Flickr.com

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

Almost certainly the best online photo management and sharing application in the world

Show Line

12 April 2024 @ 12:16 am

Leg in a Cast Toes Out

28 March 2024 @ 4:35 pm

Leg in a Cast Toes Out

28 March 2024 @ 4:35 pm

Leg in a Cast Toes Out

28 March 2024 @ 4:35 pm

LOTDĀ·# 902 FAR WEST...

14 March 2024 @ 11:59 am

WTBO [02]

9 February 2024 @ 11:39 pm

Vera

21 January 2024 @ 10:09 am

R3__5030

9 January 2024 @ 12:22 pm

Fire

6 January 2024 @ 12:07 am

230528161018_MG_4671

27 December 2023 @ 8:36 am

halfbakery.com

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

Half baked ideas going way back.

bitchute.com

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

Video sharing that may not be allowed (censored) on youtube.