#development
1 messages ยท Page 56 of 1
it just sounds like you're using the wrong tools
python and java are very opinionated about what tools you should use
i like looking at C++ the same way people look at mikrotik stuff
C++ just has terrible dependency management, it's not a hidden secret
One of my ex-teammates (when I worked with C++ professionally) is in even a SIG for this reason...
okay, well. if you create crazy dependency hiercachies then you'll have a bad time
but if you just add simple restraints it becomes much easier
Do you work in a professional environment with C++? ๐
lol yes
I'm learning sql and need to find an address in a mock database that is associated with any ip address that has 100 in the beginning; I'm not sure if I can post code here, so I was hoping someone could redirect me to where I could inquire about this
How do you guys manage it?
it depends on the project
How do you guys distribute your C++ package updates? DPKG?
if it's not an accelerated workload we can just spin up a bunch of code-server instances and automate the depencies installation with terraform
if it requires bare metal access then we just spin up a local git repo that mirrors the dependencies. no wild git repos are allowed
if you're talking about how the application gets distributed, most of the time it's just a single binary
this is the appeal of go, right? you just shove a signle binary image in a docker image and deploy
now if you're asking in your context of how you deploy a C++ application with dynamic dependencies as a web service
heh yeah I guess that is part of the appeal
you just use docker
True, if you can create docker containers for your apps than I guess it's far easier
Does the git mirroring just mirror them to a custom directory, and then you have custom build tools that auto map?
we use a gitea instance to basically have a local github repo
Sure, but when you're linking how does your compiler find them?
most of the time they're header only libs
o.o your entire codebase is header only?
99% of it
wild
if a dynamic library is needed for a specific reason
Ok yeah that makes life far easier
the company I worked at is one of the few, big, tech companies that's been around for more than a few decades
simdjson is probably one of the few things that actually need to be compiled into a lib
packages were distributed using DPKG to baremetal, both linux and solaris systems
very little containerized workloads, for performance and reliability reasons
solaris makes everything complicated
packages had to be static, if not header only
yea honestly dynamic libs are cool
we're also one of the few tech companies that have our own version of STL
both, all custom
fun times
yeppp
nooooo
major contributor to the CPP standards, so we're ahead of the times sometimes
but other-times it's like... why does this not exist internally? And the response is "Well, we didn't agree with the committee on this, so we didn't make it internally"
so did yall make the leap to adopt some of the parallel stuff from khronos yet?
heh, not sure, I don't work with the C++ stuff atm ๐
there's a huge push to put general compute in the API layer now
like for agnostic OpenCL, Cuda etc
But if you ever come across polymorphic memory allocators, you can ~curse~ thank us for that
๐
Oh, well, you're welcome!
just make sure you don't orphan your object when you return it ๐
i've got sanitizer checks to yell at me
Still though, gotta say Java (what I mainly use now) does have far better dependency management though
if you try to wild wild west C++, it can end really badly
It's just so much easier uploading to artifactory and pull automatically
the same way if you copy paste routerOS configs from the internet into your deployment
that too will end badly
true
CI/CD with k8s is so fun
did you see the new Rancher 2.5 additions?
to make it even easier?
but as a dev, it's not worth my time fighting to deal with packaging and dependency stuff
and the setup time for java projects is just so much lower
it's just the familarity with the tooling
if you like java more
then you probably understand the tooling a lot more
the problem is C++ isn't opinionated at all
so when people look up tutorials
True, the C++ build tools do have a steep learning curve, but even being well versed with cmake, I can't say it holds a candle to Gradle
they get question marks flying over their heads
like the C++ modo is just defer until you can't anymore
Also, C++ does itself no favours with shit errors
Which thankfully I believe they've fixed now?
C++20 with concepts fixed that
specifically template errors
it's now about failing to meet a concept
instead of syntax failure
syntax failure errors are in fact garbage^garbage
I do have to catch up on C++20, we were still on C++11/14 when I last worked on it
(partially because... Solaris)
this is why you hate C++
LOL fair
wait until you find out what they're doing
like C++23 is basically going to have a contexpr JIT for compile time nonsense
also non-integral value types for C++ templates
gcc10 already has it for strings
I really want an update to C++ Programming Language
like if you want blah<"abcd"> my blah;
but Stroustrup seems to have no interest
lol bjarne?
yeah
do you mean his books?
Yessir
i mean if you've ever talked to him
he feels out of depth in C++
the community took it way to far lol
Ah
the books he published are and were for foundational knowledge
they are really good
Have any other recommendations for C++17/20?
i'm flipping through my personal library to see
honestly CppCon videos are a really good first start
True
heh, always fun to play with
https://www.youtube.com/user/lefticus1, he's legit a master at explaining C++
kate gregory usually maintains a list of educational materials
lol containers in FreeBSD
jails are the fastest way to find a noose
he has a video that explains pmr
I'll check it out ๐
if you have any questions feel free to ask
honestly most people ask for video tutorials and I learned by reading the actual standard props
i'll ask around about a good book
I prefer reading technical literature on stuff tbf
video tutorials drag on too much lol
Maybe I'll just read the standard docs
yea the standardization papers are well written, I agree the videos drag on lol
Driving myself insane trying to re-imagine security onion.
Nope, none of that. Building from source, not reverse engineering
just trying to debloat it into a sensor instead of a suite
Especially after the travesty that is Security onion 2
anyone here able to help me with a discord bot?
This is the GitHub repo im using
https://github.com/discordconsole-team/DiscordConsole
@rustic obsidian that's just to control a bot
ik
you made a bot with discord.js or something similar?
wdym, it's pretty dam easy
i just need to be able to send an embed to a channel that all nothing more
alright lets try this again
how do you make it so labels' text keeps centered with the window instead of doing this?
you use math
text-align-center 
sorry I don't know @astral bobcat
providing some info like language would be helpful
new to c# dev, how can i take a value from a json file and store it into a string variable?
Parse the json
^
^
^
my frend wants to start grafics disining enny tips
Did you mean to say graphic design, any tips?
@true salmon you need a library to parse json
^
I have to say, after getting used to TDD, its extremely painful to start to work on a project that has a low test coverage.
I feel like i cant fully trust my own code.
Yeah, but atleast the business logic stays intact.
LF some big brain js coder to help me with a simple quiz 
DM me ples
do your homework
What do you mean?
big brain js coders 
I've got 8 years of development experience, everytime I try to use node, I die inside slowly
mostly because the ecosystem of javascript is garbage
npm install is-odd
what even
The best part is the dependencies ๐
hmm how is javascript less of a language than any other language. If you write crap javascript, you will get crap javascript. Same as any other language.
Most problems i feel come when people try to write javascript like it was java or c#. Also problems start to arise when you use vanilla javascript to build huge applications without a well thought out design pattern in mind. That or some framework.
how do them packages get 50000+ downloads per week my god ๐
dependency hell is real
@left drum I'm trying to use typescript
and even that is full of weird problems
and a lot of traps to fall into
@warm sleet I havent subjected myself to that confustion yet, I always get issues on github repos about it and just say we dont support it so it would be good to look into
yeah but all these weblanguages are awful
default tools like npm are total crap
build structure and project lifecycle management requires you to write your own code
I have stuggled with the js eco system over anything else even with 5+ years of programming
and every project
has their own special sauce
everyone exposes their api differently
sometimes you end up with stupid callbacks, when you don't need one
which ends up making incredibly unreadable code
callbacks are hell dont get me started, i try to stick to async and await
typescript has that embedded in the language
its slightly less painful
I'm developing a framework right now for a headless CMS
when i have a free couple of hours i will have to have a look into it
using typescript, and graphql
cus graphql can do schema exports
something that previously was only possible with xml rest
so I can generate an MVC environment around express and hook into the cms
generate classes from it
I've written many frameworks in java
this is first time in js
and its killing me
graphql is really interesting to me, iv only used it when querying the github api
im coming from swift and js is definetly really different
graphql behaves like a graph lol
There's other platforms that have similair structures
alright this is going to sound like i dont know js and your right but can anyone help me with my discord bot i got it running but i want to add stuff to it but what im doing isn't working
I'm just dropping this news here
https://www.zdnet.com/article/riaa-blitz-takes-down-18-github-projects-used-for-downloading-youtube-videos/
youtube-dl
and yes the source is not available at the time I write this chat
https://github.com/ytdl-org/youtube-dl
I love the "open" internet
looks like backup is up
https://gitlab.com/ytdl-org/youtube-dl
This is a backup of https://github.com/ytdl-org/youtube-dl since it was taken down by the RIAA.
This is what happens when microsoft gets ahold of our precious github
It's not like gitlab isn't equally susceptible to dmca
I saw a bit from the dmca takedown which shows a test url in the source code that was a copyrighted vevo music video
so the take down was annoyingly probably legally valid
hopefully removing those test urls means it can be republished but who knows
For disclaimer I am not saying people should pirate
It's just making it harder to pirate out break the law, and that library was kinda illegal
My php app doesn;t get the data from my form any help? @ me
I requested named group for regex feature in vscode. If you are interested please upvote - https://github.com/microsoft/vscode/issues/106080
My php app doesn;t get the data from my form any help? @ me
@frozen pulsar great
Yea, great
it isnt working. I don;t think it;s great ๐คฃ @hollow basalt
it's not toxic
php is a very difficult language to maintain
we have much better answers in 2020
if you can't switch to another platform, that's okay
but keep in mind that a very small majority of people actually want to support php
Your input forms need to have a name attribute, that same name is the literal index for the $_POST or $_GET arrays.
@cinder kraken ye someone pointed out that I forgot to use a name in the button so it didn;t see when it was clicked
Bruh I have no clue why I get the same problem always!
When I refresh the page it re-enters the data in the table
Everytime I refresh it re-enters the data as a new entry. Is there a way to fix it?
but keep in mind that a very small majority of people actually want to support php
@nocturne crypt who cares about other people. I am me.... And by learning it I can put more languages on my CV....
I don;t know how to fix it.,....
ikr
imagine if people actually sent code snippets instead of us imaging things
๐ค
@ivory bear https://i.imgur.com/3qhUVxc.png
downloads are still up xD
see this is why opensource is great.
they can try and "DMCA" it, as if there's any copyright they can fall back onto
and if they take it down
forks will spawn
just like what happened with popcorntime
youtube-dl isn't illegal
They should've just removed the offending tests (given)
A tool isn't inherently illegal, it's up to the users
@hollow basalt even so, these RIAA people have got little to stand on
I can use youtube-dl to download my own content
and copyright, especially DMCA is a fucking joke
I've received DMCA takedowns before
and I promptly replied to it saying that US law does not apply here, and that they should suck a big one
The more DMCA I see, the more I get the urge to help these tools
it is counter intuitive for them

thanks for brigning youtube-dl to the spotlight
Even if they clean up the source code to no longer "suggest" illegal actions, I wonder if they'll have to change the project name, since they're currently using the youtube brand name, which youtube may not be a fan of due to wanting to be on good terms with the music industry?
and I promptly replied to it saying that US law does not apply here, and that they should suck a big one
@warm sleet these US laws that think they own the world
Even if they clean up the source code to no longer "suggest" illegal actions, I wonder if they'll have to change the project name, since they're currently using the youtube brand name, which youtube may not be a fan of due to wanting to be on good terms with the music industry?
@vestal glen then it's google's mercy not the music industry
@vestal glen its not yt filing the takedown
its an agency on behalf of Sony, Warner and the likes
so the usual scum
@warm sleet yes, but what I'm saying is that the sony warner and the likes may go to yt and ask them to please stomp it. And yt just may since it's technically against their dev agreement too etc.
If google backs it up, somebody should summon the fair use 
youtube-dl is considered fair use.
sure
but doesnt fix their perceived problems
because their problems are laughable
some stupid pop song
Youtube-dl is only one of the multitude of tools
pop industry is just one of making money, and not one of artistic prowess
I agree it is their rights to the music, but youtube-dl isn't to blame
Idc who tf owns the music that's another topic, but leave youtube-dl alone

bored lawyers were bored
so they filed a DMCA during their lunch break
@hollow basalt have you ever seen the old static.thepiratebay.se/legal ?
didn't
they posted all the emails they received, on the net
cause I don't care
its full of jokes lol
that link isn;t working
like, Linotype (font company) sent a takedown request, and ordered them to pay 75k in fines
so thepiratebay sent a reply, with the same form, to pay for the hosting of their legal documents
but the kicker:
I only get to see the DMCA when google shows up these "link is remove cause DMCA sht"
lmfao
the guys behind tpb are legends
Bruh those guys are L E G E N D S
I would have died of laughter if I was the lawyer of that font company
@frozen pulsar the original documents are no longer on the net
but there's like two dozen companies that they did this to
The guy who made that document must have spent a day looking and downloading fonts ๐คฃ
downloading fonts
It's literally their servers lel
We also need to thank the hosting providers that doesn't answer to this
tpb never hosted any illegal content
@warm sleet wdymeeaaannn
@warm sleet wdymeeaaannn
@frozen pulsar it's torrent
its just lawyers who do not understand how the internet works
not a file server
torents are illegal
since when?
isn;t it illegal to download them?
https://www.comparitech.com/blog/vpn-privacy/is-torrenting-safe-illegal-will-you-be-caught/#:~:text=Torrenting itself isn't illegal,downloading unsanctioned copyrighted material is.&text=Your internet service provider (ISP,they%20catch%20you%20illegally%20torrenting.
if you torrent illegal material, sure, its illegal
but torrents themselves arent illegal.
With that logic, chrome and firefox is illegal cause you could download illegal materials
^
well yeah. If you download the whole The Walking Dead from TPB then it's illegal
yes
but these lawyers put the owners of the tpb in jail
and charged them for damages in the orders of multiple millions
even though, they never spread any illegal content.
So I can have a site like TPB and not go in jail? ๐ค
TPB is just an index
they actually went after them, for the tracker.
but now, the piratebay doesnt use a tracker anymore
With logic, they should jail google cause you could easily find pirate websites
they use DHT, which is completely decentralized
but now, the piratebay doesnt use a tracker anymore
all hail DHT
DHT?? :https://prnt.sc/v5w6lg
Yes
so they just try to attack the index
and the hash can be used to resolve the torrent peers from the network
no central server is needed.
so there's no head to cut off.
and piratebay was raided like 5-6x
and everytime
they were back up within 24h
and they still operate. today.
Piratebay isn't no longer the group of people behind it
yep
it is now the community that keeps each other afloat
they made it into a distributed cloud
so if any server is taken down, other instances take over.
lol
"What is it sir?"
"Its a takedown request"

"Schedule another missile test next tuesday"
That's just hilarious , the companies were probably got jebaited
they don't know how to handle .nk
you cant control the internet.
you try
but it always backfires
with new innovations
tor was invented by NSA
but that's created by us
I'd create a tor exit node
and other mirrors

I'll give back to the community
but right now all I can do is seed this
Im not running tor on my own network
I won't in my own network
it just makes you look suspicious
I'll do it in the public facing company
and I dont want cops to sniff my place
like a UNI
i'll tag it as "research"
come at me bro

attack my research facility
i'll call you research-hating close minded
Hey so i can tell that this chat is kinda dead but im trying to run the OpenVpn daemon to connect to my server with just a push of a single button but it isnt working of anyone would want to see my code itโs in C#
private void button2_Click(object sender, EventArgs e)
{
Process process = new Process();
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.WindowStyle = ProcessWindowStyle.Normal;
startInfo.FileName = @"C:\Program Files\OpenVPN\bin\openvpn.exe";
startInfo.Arguments = "--config == client.ovpn";
startInfo.Verb = "runasa";
process.StartInfo = startInfo;
process.Start();
MessageBox.Show("You've connected to server");
}
and it doesnt want to connect me using the config
shouldn't the argument be -config client.ovpn?
I will try that for sure
Nope sadly doesnt work
@hollow basalt Google was already fined with the comparable of 30 trillion dollars in damages
for their book scanning project
they made a compromise with all of the companies and made a deal instead of going bankrupt
Google at that exact moment was a bigger threat to anti-piracy movements then all of the torrenting websites and indices combined
than
does anyone remember the flying razer mouse from 5 years ago

though, if you plan on doing this
you should start spawn the program seperately, and just track its process ID
@nocturne galleon
using System.Diagnostics;
using System.Windows.Forms;
namespace test {
class Program {
static void Main(string[] args) {
var process = new Process {StartInfo = new ProcessStartInfo {FileName = "notepad"}};
process.Start();
MessageBox.Show($"Started process {process.Id}");
}
}
}
Ugh, I wanna talk to people about this DLL injection I'm doing but I can't talk about it in the game's server because I'll be banned D: Even if it's not for malicious intent.
So I'll just talk here instead
Instead of just adding each mod to the gameobject manually, I'm just loading the classes within the namespace and ensuring they're of the custom Mod type and loading them in that way 
And it works. I just tested with a Mod type class and a random class. Yeet.
Is there any way to run swift code on an android device
@last ingot Iโm just using the code from a GitHub but am trying to edit on android
how can i have to items adjust the right/left margins to not leave a blank space in the right
in html/css
Anyone know about how long it usually is between linking your Epic Games/Unreal Engine account to your Github account and actually getting the invite to the private repo to clone it?
Anyone know about how long it usually is between linking your Epic Games/Unreal Engine account to your Github account and actually getting the invite to the private repo to clone it?
@worn stump instant
@worn stump instant
@fringe matrix
Thatโs what I thought but I havenโt received anything and got fobbed off by support
I do understand that you would like to know how long does it usually take between connecting GitHub accounts and receiving the invite to view the Unreal Engine repository. It will be pleasure to assist you with!
We want to make sure you get assistance with your Unreal Engine issue! Unreal Engine support is handled by a different team and you will be able to get the best assistance by visiting their support site here:
https://www.unrealengine.com/support
If you have any other question or request please get in contact with us. We will be more than glad to help you at any time!
๐คฆโโ๏ธ
The contact page for which leads me back to the form where I submitted basically the same question I asked in here earlier almost verbatim:
How long does it usually take between connecting Github accounts and receiving the invite to view the Unreal Engine repository?



imagine comparing things to java
I compare to java quite often
It couldnโt have said unlike every other programming language
@icy wagon Lua does this too
Yea but lua is lua
matlab is for mathematicians who suck at coding
those who grow a clue, tend to drift towards python
But only python?

which are very commonly used by people who run compute
I see
scipy's library implementation is natively optimized
so even though your logic is in python, the calculations themselves are with library functions, and thus run well optmized
I've used numpy https://numpy.org/
Why NumPy? Powerful n-dimensional arrays. Numerical computing tools. Interoperable. Performant. Open source.
for importing and processing data from CSV
and matplotlib to render graphs with it
I still donโt understand the point of dynamic typing
You mean ducktyping languages like Python, Lua and PHP ?
Sure
Less boilerplate
Python is really powerful
It's like matlab
But sane
That's why Jupytwr notebook is soaring
Python has well established standards of "how we do things"
it delivers out of the box libraries to build webapplications, desktop applications, as well as data systems and multimedia
Python is the embodiment of DRY principle
@icy wagon for simple systems, the hastle is having to define types and structures for everything
in languages like java, you need a lot of glue code to make two things work together
patterns like 'adapter' are not needed in python
since adapters are typical in contexts where type safety is a requirement
@hollow basalt I actually prefer statically typed, for many many reasons
the primary being: less mistakes
What
Then use python with static typing
Typing int String long is more work?
C# has var for variables you define & instantiate
var foo = "a String";
java however, does not have this
kotlin if you really wanted
var in c# is so damn handy
I guess it doesnโt matter in small projects
If I am developing for the JVM, kotlin is too much hastle
I might as well just write java straight up
But in large projects it seems really annoying
If I am developing for JVM, I should be questioning myself
Kotlin is great for android
Kotlin is only viable for intellij ide
Because kotlin has features that are unavailable in java 7
things like lambdas and string interpolation are built into kotlin
Why use java 7
because android uses java 7
Bruh
Its just the language version, not all of java
Didn't they upgraded the java runtime
Java7 is dalvik
Didn't they upgraded it when they moved to art
Not all of the java 8 features made it into android studio
@hollow basalt ART still runs dalvik
its just that the JIT compilation is done ahead of time
Large projects with dynamic typing seem like a hassle I should say
@icy wagon even dynamically typed languages support some form of type awareness
I mean yea dalvik, but I consider it anew
like in PHP, IDEs can look at the comments above the method call
Well just for keeping things organized and readable
yep
imagine comparing things to java
@hollow basalt The reason is it's comparing to java is that it's from a slide from a course for math majors at my school. The math students have to take 2 intro to CS courses wich up untill this year was taught in java.
What do they teach now
The intro courses are now in python though.
Oh
my school taught me how to write broken PHP
Honestly they should start with c++

my school taught me how to write broken PHP
@warm sleet That's our webdev course.
yes
Ah
they should start with pure C
@warm sleet That's os with this man
but in the sense that you might think
C got updated, it's called c++
C allows you to really understand what the computer is doing
Yea
this teaches you structured programming
the stack, the heap, method calls, variables
references vs values
The step up after structured programming
could be OO concepts
Going from js or python to c sounds like it would be hard
Java is much cleaner when it comes to learning OO
@warm sleet I agree
honestly, touch of C and Java
helps people self develop C++ if they ever need it
plus, these are languages you may actually be able to use yourself
C is great for learning how to do stuff on arduino
I think what my school is doing first year python, second and on java for the main courses. And other languages if it's better for the specific course(ex c for os)
and Java can help you develop something alongside, on a PC
make an os
That's just the kernel
Donโt have to worry about people targeting you if itโs your own os
@hollow basalt Linus Torvalds made linux after looking at the pricing for UNIX
Creating an os is fun
Look, when people say "OS"
That's the only thing I applied assembly
I only think: kernel
on windows thats NT
macOS is XNU (or Darwin depending who you ask)
I'm the one that says darwin
everything else around the kernel, is just programs.
That's the very thing Richard stallman preaches. Linux isn't an os
It should be gnu+linux
well
kernel is only small part of your entire OS
but if you wanted just an environment to run your code
you don't even need GNU
They should be considered exclusive
On the subject of typing I prefer when my ide can figure out what type the variable is. Cause I don't have to be constantly looking at the online docs since I get the functions and their parameters in the ide.
yup
^
@vital blaze not only that
if you are at a given location in code
and you open autocomplete
it can filter nonrelevant things
IntelliJ does this to great lengths
This is why notepad is powerful
Does anyone here use eclipse?
Eclipse is sack of shit
Hell no
IntelliJ all the way
What do you use vim for?
Mobile developpement
Sometimes it's nice to work in a regular ide
latest verison of IntelliJ is unstable for some reason
multiple times now, its crashed on me
Iโm running on like a 2018 build lmfao
It's still ide
I got latest on here
Forget autoconpletion
@hollow basalt You can get autocomplete in vim.
What changes between updates
Did I say you can't?
lol IntelliJ startup be like: https://i.imgur.com/2FornJP.png
I thought you where saying forget autocomplete and use vim. My bad
What changes in newer builds
The version number
I noticed a big change when going from like 2017 to 2018
Why I love IntelliJ
Language Injection, Web services support, and you can configure run configurations for pretty much everything
Cause you use java?
if I hit start, it builds the software, spawns a proxy server if there isnt one running
then it spawns a minecraft server
and loads my code, as well as load the binaries from the server into my IDE
so I can debug while its running
Yep
initially I got into minecraft development, to build a synchronization module for bungee
made a system where, players can move from one server to another through using portals
when you moved to a different world, you'd be connected to another server, using bungeecord
but my code, also makes it so your profile is transferred
as well as providing multichannel chat across servers
and discord integration, cus that is 'cool' to have
three plugins, one proxy plugin, one backend java service, MySQL datase and a redis database
we've had people try to steal our code
but i always say: good luck using any of it
Steal 
cus you need a whole bunch of setup alongside to get it to work
its running on 8 server instances
the database is like 4GB now lol
Bruh
minecraft inventories so big
@icy wagon https://api.knockturnmc.com/standings
That should show you total amount of players we have
Its a harry potter roleplay server
Not my idea, I dont particularly care
but I like programming
and they needed a skilled coder
in 2014 xD
@hollow basalt
package com.knockturnmc.core.database;
import com.knockturnmc.api.database.BlockingCodeException;
import org.bukkit.Bukkit;
public aspect BlockingCode {
pointcut preventBlocking(): execution(@PreventBlockingCode * *(..));
before(): preventBlocking() {
if (Bukkit.isPrimaryThread())
throw new BlockingCodeException(Thread.currentThread());
}
}
I'm leaving for dinner, when I come back, I hope you figured out what this is
xD
Prevent a deadlock?
Well now that a) I'm done with class for the day and b) I've gotten some sleep after my earlier messages, anyone know how I can contact Epic/Unreal re: github repo access? (The support rep basically fobbed me off and the Twitter DM I sent to the Epic Games Help acct hasn't been replied to)
Apparently you can overclock an ESP8266 to 346 MHz which is just simply insane considering the base clock of 80 MHz.
Hey oall
I have a Google Nest Mini and some Led lights with Controller i bought from a friend
my Question: can i throw some codeing (not my strong suit going to start learning it soon throw school) connect those two so i use "Hey Google Turn of all lights", Yes or no
Probably
I have never done it myself
I saw people on yt do it with alexa
okay thank u
made this in rust today and I'm in love https://github.com/Twister915/viz-rs
nice
Here's what will make any C project faster: find a commonly used header file and add the following:
#define true rand()

would somone be able to help me with this code, it is saying that root = tk() is not defined
from tkinter import *
root = tk()
label1 = Label(root, text="hellow world")
label1.pack()
root.mainloop()
i think this should help
root = tk.Tk()
#or maybe this should also work just fine, if u don't do import as tk
root = Tk()
Blech. Anyone have a contact email for the Unreal Engine team? I still haven't received an invite to the UE4 Github repo despite linking my GH account to my Epic one on Sunday (and AFAIUI it's done automatically/programatically)
so does anyone know how i randomize the background colors of the numbers without javascript? im using php html and css and maybe i roll the dice that it uses the dice to create a black border around the correct number?
if you want all the connections to go back to the server sure
you're now running into the logical fallacy of why and how PHP is difficult to use
php is all server-side
yes but if you understand how the client server relationship works
@nocturne crypt I can't do web without a pattern like MVC
you understand they can work together
javascript is your best option for something like this probably
SPAs are pure magic to me
like the reason why axios and jquery are so popular
is because they make this relationship less annoying
some guy on $internet said jQuery is dying
SPAs just require you to twist your head a little bit
jQuery is aging yes
using React with axios is apparently the new norm
i'm reigning it in with C++
i have a JIT compiler from my fully native C++ application
that will take C++ objects
and emit HTML5/css/js
at work they use Mithril (with typescript) to develop SPAs
because this has gotten to out of control
I'm currently working on a library toolkit, for node, that runs on both server & client
So you can develop SPAs, using definitions from a CMS
i'm just embracing the different libraries
and providing front end capability based on whatever the library can do
I hate node, I just... cannot find a reason why one would want to use it
its so easy to write the worst code ever in it
it is
the dependency and project lifecycle management is unrefined, garbage.
also all of my storage magic
is written in C++
and i'm like i'm not doing this in javascript
I have a tendency to develop API first applications
design interfaces, based on the user stories
@nocturne crypt Thats what I am using :D
The CMS I am using, is a SaaS, and its configured document types (its database) can export the schema
over GQL
i'm figuring out how to do GraphQL is compile time reflection
Using this to develop a toolkit for typescript with code gen
so you just give the object to the GraphQL engine
and it automagically generates the correct thing
mh
I've never implemented a gql server
only ever queried it
REST, I've got a good handle on
the C++ stuff for GraphQL is super tenious at best
but really GraphQL is just json replies
and understanding what the client asked for
Yeah the client to that CMS, is a combination of Rest & GQL
Definitions in GQL are the same types that the REST interface returns
less endpoints = less requried security
@nocturne crypt oh these APIs don't have auth xD
i'm thinking long term secuirty though
like if you drop a domain
and then people query the domain
and some malicious person buys the domain
like there's a million microsoft sub domains
well, not my problem lol. these people use a SaaS
because of rest
i can't wait to see how this explodes with ipv6
quintillions of restful endpoints
http://[2001::]/
or something
@nocturne crypt https://i.imgur.com/IP6JGJY.png
This is the way it is laid out
You query gql for the content, it has text & refs
i mean yea
refs are just urls to resources like images
i just like the fact that because it's one endpoint
you can ask and perform actions with one URL
so like HA is less complicated
uptime is less complicated
there's also action clauses in GraphQL
which i've never really gotten to yet
I've criticised GraphQL in my research
because if you use it to get all content for a page, and the database changes
it will not raise compile time warnings
but the code generator I use, does have support for generating definitions for defined queries
i mean
this is why i use AOTC languages
so the compiler can correctly tell i'm wrong
and that i should sit in the corner
with mandatory exhaustive pattern matching for dealing with runtime errors
exceptions are so stupid
Idk, in java, exceptions feel quite easy to use
never really had much of an issue with them
the problem is forwarding exceptions
like if you want a Promise or something
and an exception is thrown in another thread
Promises are a curse.
because of exceptions
promises and channels are simpler if you just don't allow exceptions
Promises ruin your entire threading model
use a message pipeline if you want to decouple that
promises and channels are just eager forms of parallelsm
the way promises are implemented in my version of GCD
is a message pipeline
you just call a function, it returns a promise
the function gets thrown into a lock free multithread safe queue
and gets popped in a threadpool somewhere
in C++ Promises basically use whatever exeuctor model you give them by the standard's rules
so you an do async now which is probably what you're thinking of
typescript hides this
if you make an async function
it just makes it return a Promise<T>
you can ask it to execute on a threadpool
or you can ask it to execute on a strand
Linux, Windows, and macOS all have a global threadpool you can access in C++ land
less software trickery with those?
muh, in Java, when you create rest services, every request is its own thread
yea typescript probably just eagerly uses async and spawns a pthread like a dumby
the global threadpools just act like normal queues
it uses whatever node does underwater
most of them use lock free thread safe threadpools
windows 10 is infamous for having terribly scheduling
so if you care about the actual scheduling in your threadpool, you can just use your own or ask for an executor from a third party library
like Apple's GCD or Intel's TBB (an OS agnostic threading library for C++)
Apple's Grand Central Dispatch became so famous that it actually has a port on LInux and Windows
I think java has ExecutorService
for that
it can hold a pool of threads
you can submit jobs to
jobs in the form of Runnable
the manual way of doing it
Java lets you do to many cool concurrency things
is by doing new Thread(() -> System.out.println("hello world"));
and people let it ruin their parallel workloads
that's probably some interpretation of std::channel
which is basically a thread safe message queue
oof
here you go
private Profile getProfile(String uuid) throws InterruptedException, ExecutionException {
ExecutorService pool = Executors.newFixedThreadPool(4);
Future<Player> player = pool.submit(() -> getPlayer(uuid));
Future<Highscore> highscore = pool.submit(() -> highscoreService.getHighscore(uuid));
Future<List<Spell>> spells = pool.submit(() -> spellService.getSpells(uuid));
Future<Boolean> online = pool.submit(() ->
livePlayerDao.getOnlinePlayers()
.stream().anyMatch(p -> p.getUuid().equals(parseUUID(uuid))));
Profile profile = new Profile(player.get(), highscore.get(), spells.get(), online.get(),
familyService.getFamily(player.get().getFamily()));
pool.shutdown();
return profile;
}
calling many services at once
compile the result, and return
This is a crude form of paralellism
this is the funnies
where you have a set of calls, that each do stuff over network/database
This was a 'fix'
to an API call that took 350ms
and after this change, only 35ms
there's probably some sorcery in those functions
it also connects to like 8 different machines
with RMI
to request data from the gameservers directly
heresy!
it was either RMI, or setting up a webserver on every instance
RMI was less configuration
and easy to implement RPC with
going for a distributed db
until oracle happened.
and exposing over one of the boxes
and RMI is now ded.
like i'm basically using S3 Buckets as a distributed datastore
you can do coolio stuff like that
interesting solution though
only use pre-fabbed tools
I set out to develop an alternative using the tools we already have
I mean i basically cheat and use my OP tools
wrote a PoC for implementing RPC with pubsub redis
I am saddened by the slow removal of traditional java tools
like, the JXC tool was removed from the JDK
You could use that to generate xsd from your JAX-B annotated types
honestly java is a security nightmare
how so?
the JVM is a magical box
this is why container people are so afraid of ipv6
they're like containers, direct exposure
you mean all of java apps and python flask apps
have to be secure now
and i mean it's fine if you understand the required firewall rules
I mean, none of my Java applications are directly connected to the net
but in reality most people don't, because they cling to NAT
The webserver I use in java, does not have any fancyness to it
Jetty is quite barebones
I use NGINX as a reverse proxy in almost every scenario
then it's not directly connected to the internet now is it
Only real risks with java
is like with any other language
injection.
Shellshock, sqli
etc
nginx has some sweet stuffings
yeah but you cannot manipulate the stack in the same sense
like i have applications that don't actually depend on the standard library
abusing a buffer overflow to rewrite stacks
doesnt work in java.
because code does not have permissions to do this
nor, is there any API to do so
if you do C++20 stuff, abusing the stack doesn't work either
so C++ is like that moment when Ichigo is learning bankai
and Zangetsu is like you must understand
wat
@nocturne crypt ever used Sentry?
I love deploying this in software contexts that are very agile
and early in development
It basically hooks itself to your logger
what does it do?
and any exceptions you generate
it stores context information as an "event"
and pushes it to sentry
so you can see exceptions, categorized and grouped (if duplicate)
you can add markers
to add things like API parameters
so you can recreate the bug
let it crash?
all runtime errors are handled with pattern matching



๐คฆโโ๏ธ
