#development
1 messages · Page 42 of 1
thanks for tagging me when I was expecting some help :(
Destruction 💯
@rich cedar
I remember a kid at school making a calendar with alarms only using nested if statements. Not even a single "else" in the entire program.
:|
Few months, and he had coded 5 years worth.
I walked over at that point, showed him how to do a 3d array, and he, I shit you not, crawled under the bench and cried.
Now my brother owns an internet café.
Wonderous world.
A friend of mine described a problem he had to solve, where he had to check that an ID was valid. He had a list of valid IDs, and was told to make the list easy to modify in the future. So he writes a Python script which generates a "minimal" switch tree, based on the valid IDs, which looked something like this:
switch (id[0]) {
case 'a': return false;
case 'b': return false;
case 'c': switch (id[1]) {
case 'a': return false;
case 'b': // ...
}
// ...
}
I introduced him to the concept of a binary search. He no longer speaks to me.
just load the IDs into an array, and search the array for a match.
@last ingot
Some people don't like moving from what they know.
I regularly come across new ideas and realise "oh hey that thing I made would have been much easier if I'd known how to do this".
Sometimes I'll refactor everything to do it the new way and just watch half the codebase drop off.
@inner wraith
The happiest I've ever been was when I found a 20 line snippet in a random pastebin that saved me literally 850 lines of code to do the same thing.
I did say I introduced him to a binary search, yes
probably wont get an answer again but Im gonna bump my question from above
if you scroll up a bit I have a noob question about how to use Graphics in a KeyListener in Java
@kind portal you can have a final variable in the method outside the listener, which you can then access inside the listener.
@kind portal a random image from internet with similar listener problem. If in that code he would make final Boolean flag, then he could access it from inside the listener
hope that helps
or another 😃
Thanks! will try later when Im home
https://en.wikipedia.org/wiki/Final_(Java)#Final_and_inner_classes relevant wikipedia article
In the Java programming language, the final keyword is used in several contexts to define an entity that can only be assigned once.
Once a final variable has been assigned, it always contains the same value. If a final variable holds a reference to an object, then the state ...
alternatively you could instead make an actual class for the Listener, which would have a constructor, to which you send the required objects in advance
Essentially, in a nutshell, what I want to do is call a method from a class that draws an oval when I press enter
What are constructors by the way? Could you ELI5 it?
And how would I send Graphics to it in advance?
once again. if you want to do it in one class, you do final Graphics g = ....; before the panel_Game.addKeyListener call, and then you can use the variable g inside the Listener
using a class is just an alternative, might be too complex for now ?
Yeah the class thing is a bit complex
But I understand what you mean now! Thank you very much!
in retrospect I dont really understand it now lmao
What do I put after final Graphics g = ?
wherever you were gettings the Graphics object from
are you drawing on swing panel for example ?
ye
then you do final Graphics g = panel.getGraphics();
OOOOOOH
i guess at least
i haven't touched Swing for a decade
might be a problem
ok then 😃
no problem
i would recommend learning about classes, inner classes and visibility next
Oh nevermind
Eclipse doesnt complain
but whenever I do run the app and press enter I get a fuck ton of exceptions
Ill just ask my teacher next week
ok
But its at least one step closer
Can I do final Graphics gx = panel.getGraphics(); in a different class?
that doesnt have the panel
as i said, i haven't touched Swing for over a decade, read the manuals/API documentation
Getting back into C for the first time in a while, anyone got any recommendations for projects?
Something you will use
@rich cedar
Make a prettier, better version of this.
https://discordapp.com/channels/375436620578684930/380527803604664324/569033024159744017
@feral tide That script confuses me on so many levels
In the printX functions, why do you pass a string in ByVal, modify it, and return it? Why does that parameter exist at all? Why do those functions exist at all? Why not just pass the string directly? Why is there a Sleep instead of any actual work? Why are all your colons preceded by spaces? Why do you have that If File.Exists when File.AppendText creates the file if it doesn't already exist? Where does chatclient come from? Why do you String.Concat with a single parameter? Why does GetIpAddress use globals instead of just returning a value? Why do you return the 2nd IP address in the list you get from the DNS instead of the 1st? Why do you overcomplicate New TcpListener(portNo) by doing that whole roundabout with limiting it to listening for connection attempts against specific IP addresses, rather than just anything hitting that port, when it's supposed to be a port bug? Why do you try to autoguess the IP address to limit by?
It's fractal confusion! You did "doing "doing things weird" weird" weird!
@feral tide I need answers
I'd love to answer them, but.. I really can't.
All I can do is provide more source code for chatclient at a later time. (Omw to work)
8 years, and significant coding advancement (including changing language a few times)
oh thank Christ that's old code
Found a project, by which I mean I had an idea: https://docs.google.com/document/d/1egLfpc1cfQkYcFVdU3S9I_FPLXO8sFgV8IY7SCyOFbA/edit
Just to know, you can't push anyone to give you answers. Not everyone has time to help out and if they do, respect that
What are some project ideas to learn cross compiling between windows and linux?
Anything that uses linux / nt kernels
^
Windows 10 will have lnx kernel soon so better halt that type of ideas and wait for this to come alive.
lol
Would anyone be willing to take a look at this? https://stackoverflow.com/q/56106313/5871303
@nocturne galleon Build a CLI using only standard (hosted) C/C++, then use a VM to test if you cross-compiled correctly.
@winter salmon Er, no. The Windows Subsystem for Linux will soon emulate a full kernel. Windows itself will still be built on the Windows kernel.
ok
@fallen vigil The WebSocket-Code looks okay to me, but I think there's a problem with your way creating the video output. Maybe each Zero takes a different time loading the video from the sd-card, because they all have a different bandwidth. I don't have very much experience on omxplayer but I think there is a solution. You could try to start omxplayer paused (maybe cmd argument "--start-paused" works) and then send after a constant delay (after final loading) either an media button or other keys ("p" or "space" can be used) with an node.js library. Good luck! 😂
@odd cypress thanks for the reply. All the Pis are running the same SD card and the same power cord/supply so there should be no hardware difference. They’re also all running the exact same OS image and package versions. I’ll try your suggestion later tonight when I have time to work on them again
np ;)
@fallen vigil
If they're networked, broadcast a stream and get them to view it?
@feral tide Well actually, they’re all playing different videos of PowerPoints used for digital signage. So each video is the same length with each slide being displayed for the same amount of time. The players being synced ensure that the transitions all happen at the same time and the videos loop at the same time.
Let me know if that explanation didn’t make sense
For testing purposes, all of the players are using the same video clip, I’ll be implementing the different videos in the code later
@odd cypress It doesn’t look like that’s an option https://elinux.org/Omxplayer#Usage. Omxplayer was built for Raspberry Pi so I used it, but I’m not glued to it or anything. Do you have a different suggestion?
There’s also mplayer, I don’t know much about it though
@fallen vigil stream per slideshow, bash script to start and stop at request?
Hey how do I install the Edge channel of Docker Desktop on Windows?
jesus Christ is it just me or is Unreal Engine really fuckin unstable
@rich cedar
You know what I don't like?
Companies that develop things like the unreal engine, then buy out smaller companies who are developing next gen engines, and literally liquidate the staff, and destroy virtually all the work and references once the purchase happens.
I don't like when I go to save a file and my IDE crashes
I don't like when I open a dialog and my engine crashes
I don't like when hover-text popping up crashes my engine
I don't like when I'm doing something and the engine just decides fuck it, time to crash
I don't like that Epic made a bazillion dollars off Fortnite but apparently they can't be arsed to put any of that money into UE4
@rich cedar
I don't like how the Euclideon engine isn't public Access.
@open otter I work with Java on daily bases. What's your problem?
where is the file in your workspace?
and first and probably easiest way to fix such problem is using the absolute path instead of relative.
interesting....
i will look at code in about 10 minutes properly as soon as i am at university bit there ain't any obvious mistakes i noticed
but general thing.
But the file reader into a bufferedReader
mhh, okay. i will look soon and come back to ya
nah, no problem. I like to help and java is sometimes really bitchy about small things. (( like all languages actually))
another thing about the code. The step of first getting the file is not actually needed.
But yeah, ehm soon there and then it should take about 5 minutes to resolve the problem. Just try to rest a little bit. Late night coding is stressful
I just now arrived and just opened my ide.^^
Nah, no problem. I need to wait anyways about 30 minutes till my first lesson for this day starts. ((actually it is a test about R as a language which I will solve without any problemss.... so yeah I have time))
nah, needed just to switch workspaces away... Some of my workspaces are a bit... ehm automated which makes things stressful for new not integrated code 😄
first your writer never gets closed in createMonsteFile which can become problematic
I would advise also to user the PrintWriter
File monsterFile = new File("./monster_table.txt");
PrintWriter writer;
try {
writer = new PrintWriter(new FileWriter(monsterFile));
writer.println("MonsterName HitPoints HitDamage");
writer.println("Hydra 50 6");
//and so on
writer.flush();
writer.close();
System.out.println("Monster table successfully loaded.\n");
} catch (IOException e) {
System.out.println("That's a pretty dank error mate.\nSeems as if you can't write your monster table.\n\nOuch.\n" + e);
}
}```
like this
makes the string more readable and println instead of \n works on every system 😄
yep it is in io
import java.io.*;
import java.util.*;
import java.util.concurrent.ThreadLocalRandom;
public class Main {
private final static String FILE_PATH = "monster_table.txt";
public static void main(String[] args) throws IOException {
File file = new File(FILE_PATH);
if(!file.exists())
createMonsterFile();
BufferedReader reader = new BufferedReader(new FileReader(FILE_PATH));
if(reader.readLine()!=null) {
System.out.println("Was found");
}
}
private static void createMonsterFile() {
PrintWriter writer;
try {
writer = new PrintWriter(new FileWriter(FILE_PATH));
writer.println("MonsterName HitPoints HitDamage");
writer.println("Hydra 50 6");
//and so on
writer.flush();
writer.close();
System.out.println("Monster table successfully loaded.\n");
} catch (IOException e) {
System.out.println("That's a pretty dank error mate.\nSeems as if you can't write your monster table.\n\nOuch.\n" + e);
}
}
}
I just took the "problem" part of the program
It works like this perfectly
one thing I noticed was that you looked for monster_table with file while your FileWriter created monster_table.txt
And another thing to know. The relative path usually starts outside of src.^^ ((I say usually cause there are werid systems.))
take ya time
Interesting
can ya send me the exception message and line?
mhhh, that would mean that the monster is not initialized anymore
well yep seems like that could be it^^
Yep, good luck.^^
I soon need to leave for about 4 hours because test and presentation but afterwards I should be able to help if there are any problems.^^
And it is a fun little program you created for yourself... Pen and Papers are fun :D
I did similar stuff or still do similar stuff from time to time.
((okay, this makes me sound way older than I am but pshhhtt.. ))
2 hour of R test and then a presentation about a program written in "REACT" which is a javascript package.
nah, i hate javascript and webDev is like the least interesting thing for me. At work I work at a complicated Product Information System with about 5k files... and in private usually with AI and weird microsystems... which makes that soo boooorrrriiiing...for me at least because I have a different field of interest
#oldbutgood
the description of this channel insults me
yeah, it should be puts("talk about deving here")
@rich cedar std::cout << "talk about stuff you found on stack overflow here" << std::endl;
lmfao
@proper gale Was that supposed to be C++? There's not enough template metaprogramming.
dont worry, i have plenty of that in my actual code
what is the longest line you have generated from a single macro?
my record is just over 11k characters.
does anyone else here develop for the homebrew 3ds team
for macros ive written ofc.
just a little CTRL+C CTRL+V action
i basically implemented reflection in C++, with templates.
pfft, good luck m8
oh, its already done
see here https://hastebin.com/eleduvujov.m
the normal types was the easy part
also works for arbituary types, and vectors, and vectors of vectors of vectors of vectors.
i love working with those vectors of vectors of vectors
why did you develop this?
for personal use?
mhmm
yes
which do you think is more flexable
depends
without libs
C++
yeah python doesnt have too much to offer by itself
here is teh whole header, that section is by far the messiest https://hastebin.com/bipubazibu.m
is this for a bowling game?
just a scoring system
for a bowling game
woah
where you, in person, pick up a ball, and throw it at pins.
yeah that going outside stuff doesnt exactly suite me
pros: money
cons: need to get out of chair.
im making my own system, and plan to sell it.
this is overkill for what i actually need, by a lot
dont you think you could develop something more useful, something that everybody would use everyday?
how much demand is there for bowling systems
centers pay a lot for their systems
demand quanity is low
but, because of that, price is super high
average center spends $600,000 to $1,000,000 on a system every 20-25 years.
just for the initial purchase, depending on center size.
so its a get rich quick scheme eh?
yeah i see that
you need to provide support for that time, and, only get that sale every 20-25 years.
so you gonna develop this for 20 years?
could be.
i mean, money
just doesnt seeem right
also, physics
do you own a nintendo 3ds?
nope
Switch?
nope
PC master Race?
1000000%
wanna know how people make sidecash
develop some homebrew for any console that can be jailbroken, and add an adfly link to it
side cash is great and all, how about center cash?
invest what you can
long term, short term
10,000 can turn to 400,000 in just 20 years
right, but i need to get that 10,000 in the first place
and, i need to live now aswell
what are you trying to get at?
investment is good
im aware
and there are alot of smart ways to do it
some in come in the form of free phone apps
im trying to sell a product that i can make relatively easily, get a relative lot of money for, with long term minimal work.
the app rounds every purchase you make upto a the nearest dollar, and invests what it used to round up
i would need to sell it to on average one center every 2-3 years and i will be making plenty enough money.
based on average center size.
so 3.59 round up to 4 thats 41 cents invested
or pents
or rupels
or whatever
i gtg
anyways try to have fun once in a while!
@proper gale I wrote a (very inefficient and not-full-featured, natch) compile-time regex parser with C++20's template features. I estimated that a simple Regex<"[Hh]ello,? [Ww]orld!{,2}"> "expanded" to the equivalent of about 7k of code, including whitespace.
still 4k short
lol
lemme finish
Regex<...>.match("hello world"), on the other hand, expanded to about 20k.
again, metaphorical, etc., since there's no easy way to really "expand" template stuff -- I basically just guesstimated how much code it'd take to manually unroll the templates.
I was talking about template metaprogramming in the first place ¯_(ツ)_/¯
That's the kind of nonsense I meant
Where it just gets wildly out of control and you feel like some part of this has to be illegal somehow
fun fact, btw, my implementation of +/* made it basically unusable, because of the strategy I used to match variable-length sequences. In retrospect, generating out every possible path it could follow down the NFA was a bad idea...
.*
If I were doing it today I'm pretty sure all the code would be cleaner and faster to compile, if not much faster to run
in reality, regex is best done at runtime
I mean, it can be useful to run it at compile-time. And if you give me a couple hours, I'm sure I could even come up with some extremely contrived examples of when.
but yeah it was mostly just for fun.
yea, this is for production use.
or, at least, its indended for that
not just fucking around, i have an end goal in mind, and i want to sell it.
see above convo
Neat
I'm making a game which I plan to sell
and I've already published a bunch of open-source packages, not that there's been much interest in them lol
I'm not excited for the stage where I have to start polishing that game. I've found plenty of assets that'll work fine for testing, but I think I'll have to hire an artist or something, and I really don't want to spend money on a personal project lol
luckily, i can sell this before i do the graphical part
well, the primary graphical part
I mean, with luck I'll be able to get my school to invest in this just based off the proof of concept
i can do the secondary/backup graphics, and that is enough to sell it.
Which will be ugly, but show the gameplay
then i can get someone to do fancy graphics.
and then they'll basically pay for the artist for me
Ooh wait I'm onto something hold up
🤔
Uhh... That's concerning for multiple reasons.
Number one, that dev's family needs to stage an intervention to get them off whatever drug they're on. Or manager, as appropriate.
@rich cedar its a joke
Anyone working with DotNet Core on Linux and have some suggestions for UI design libraries?
Really missing WinForms for bashing out quick utilities.
Please make my day and tell me there is a (at least somewhat similar) alternative. Thanks in advance.
Forgot to add I'm looking for other alternatives than using Mono.
The more I look, MonoDevelop seems to be the go-to. (I'm looking into it now)
@proper gale Considering I had a colleague who genuinely tried to convince me to implement that into a product used by millions of people to handle personal financial data...
@winged obsidian If you want to use C# on Linux, Mono is basically your only option. It does have a bunch of GUI toolkits -- I think it supports WinForms? https://www.mono-project.com/docs/gui/winforms/
looks like it's even source-compatible with the actual Microsoft WinForms, but I'm just reading their marketing copy
@rich cedar thanks man, any advice helps. Dot Net Core is great for console apps and any non-WinForms/WPF solutions it seems. (When outside of Windows at least)
Hopefully they release an implementation for it in version 4 or 5
Rebranded .NET 5 has been announced without this (I believe)
Until then I guess I'm sticking with Mono
I'm not sure they ever will? I'm fairly certain .NET Core is targeting a different niche than Mono
.NET Core seems mostly targeted towards serverside stuff, so unless they change that I don't see them adding any GUI libraries
@winged obsidian There's also https://github.com/dotnet/winforms it looks like
@rich cedar Thanks for the info
I'm really hoping they add GPU support to the Linux kernel running in Windows 10, that way I can just ditch this dual boot and have a single workflow.
That will solve all of my problems. Until then Mono should suffice and it looks like you are right that they are leaning this way.
Anyone working with Ubuntu (I'm on 18.04) and know a way I can force gnome-shell to limit it's VRAM usage or disable hardware acceleration specifically for gnome-shell only?
I need just a tiny bit more VRAM on my GPU to push data through this network the the ideal size. (I'm talking like 100-200MB more)
I'm only running:
Xorg <- 196MiB
gnome-shell <- 460MiB
firefox <- only 11 MiB and mandatory as it is the front end for now
Again, thanks in advance for any info or suggestions.
@winged obsidian
Should change to 18.10.
Gnome-shell uses JavaScript for random things, and 18.04 is known to have a few memory leaks in gnome-shell.
@winged obsidian I honestly suggest moving away from Gnome.
Is there an explicit requirement for it?
Like- do you need anything bar Firefox?
So, for a variety of reasons, I strongly dislike Unity. It's... fine, honestly, for prototyping, but it's missing a lot of the features I've gotten used to from Unreal.
Then I saw this job ad in my email
Now, I still strongly dislike Unity, but I'm also really fascinated by this. Why does Northrop Grumman want game programmers? Why Unity? How does C++ play into it at all?
I think I'm gonna submit my resume just so I can get more information...
simulator?
That's my assumption
Given NG's stuff, I'm assuming a flight sim of some kind
Ohh, then the C++ would be building a Unity plugin to correctly interpret the joystick/button input, and tilt the sim's cockpit, probably
or interfacing with their plane systems simulation or similar
Unity probably for flight sims yea.
Hi guys, I have a slight issue
This entire time Ive been making my app in Eclipse on my MacBook (Java)
I decided to write a bit on my main workstation at home too (Win10)
So I installed Eclipse and installed the same JDK (1.8). I imported the GitHub repo of the app and ran it to see if it works
It runs right, but when I try to do anything the visuals just break down
This is how it is supposed to look. It looks right when I run it
And this happens when I do anything: use arrow keys, press the button, etc.
These issues do not happen on my MacBook, what can this be?
@kind portal better question, why are you using swing and not JFX?
in reality, check your item registration code, looks like you have something being registered twice
use the debugger, it will help you find it
Im using Swing because thats the only thing I know and Ive been instructed to use for the assignment
Item registration code?
so, when you get the JFrame and register the buttons, and ellipsed, and text boxes, etc.
check that code, its probably being run multiple times.
Im not quite sure if I get what you mean, sorry :(
I have this line when the panel code runs
But it runs twice when I start the app
hmm
and thats going to be where the problem origionates.
the OS windowing libraries can have different behavior, where the swing library can have things be implementation defined
so, chances are, that showing or not showing up, is implementation defined behavior.
probably, havent used swing in a few years, and the last time i did, i had the code for it generated for me (praize UI tools)
same here
My code is generated by WindowBuilder
Im just not going to bother and code on the mac
I posted this in one of the other chats but this seems more likely to get ideas from people doing coding also
Im going into my Final year of University after summer, and doing an Honours project and Dissertation etc
So i kind of suck at coming up with ideas for projects etc, dont ask how ive got this far, but yh thought id ask in here for some ideas
Im doing Software Development at Uni so, Computing Related, topics obviously so it would be a project of building an application of some sort and researching the topic too, any suggestions would be appreciated, Im familiar with Web Dev in PHP etc, Java, Android, C#, id happily look at new languages too, if thats necessary with any ideas etc :)
My own topics in my head to develop an idea around are to do with some actual interests of mine, Football/Soccer 😄 (least likely) Security aspect of computing, Animal Welfare and Environmental shit, Areas i feel id have a proper interest in doing the research and putting alot of focus into completing very well in all aspects etc but any other ideas just to get my brain going would be appreciated :)
I also know that they likely give a list of ideas but most likely its Data management systems, and id like to find something ill have a strong interest in doing
Can tell me to get lost if you want xD 😂
How can I have 16% CPU usage fairly consistently and no load average?
When the CPU usage is caused by rendering frames to the monitor, and it just so happens to use 16% of the CPU during the small monitor window that the Task Manager Samples the CPU usage at. Short bursts.
Real CPU usage will be displayed in the load averages.
@inner wraith what 16% that its showing in the list, is 16% of one core, so for my CPU thats 1% usage.
Two ffmpeg entries.
what about them?
Read about halfway down, 8% each :P
what CPU is that running on?
how many threads?
like, on my computer, ive got a 1700x, so when it shows 100%, i know thats 100% of one core.
Load averages generally indicate how much time is spent using or waiting to use a core by threads.
A load average of 1 means that the CPU averaged one thread needing CPU during that time period. So an average of 1 from consistent load on a single-core system would generally mean it was being maxed out and >1 means there were at least some periods where stuff had to wait, with 0.7 per core usually being the target.
So that makes this screenshot interesting. It should be at least CPU usage percentage or more.
@sturdy scaffold I reckon you might not be far off, though this is a music bot. ffmpeg feeds Discord a frame per connection every 20ms.
Considering that windows task manager on its fastest setting only update about every 250ms, there is a lot of room for error, especially since the task manager has to take up less than 1% of the CPU in an optimal configuration.
@last ingot That's not a C++ thing, that's just a code thing
You'll discover the same thing if you try to read bad code, or code in any language you don't know
how come there are 2 websites for w3schools?
there's https://www.w3schools.com/ and https://www.w3schools.in/
are they the same organisation and one is for more advanced concepts? because if so, why are their logos very different
Looks totally unrelated to me
But given that W3Schools already stole their name from the W3C they're not affiliated with, I find it hard to pity them
So which of those two would you consider ‘reliable’ in terms of the information they give in their tutorials
@nocturne galleon my college used w3schools.com to help teach me HTML and CSS.
@rich cedar look again
I actually learned HTML, CSS & JS from w3schools lol
learning html and css by trying something and just having someone that tells you a keyword to make it better but not more,thats how i learned it
@nocturne galleon The W3C literally invented the HTML/JS/CSS standards and is their maintaining group, so, uh, them?
W3Schools is notorious for constantly being bad, either by not mentioning important things or by just being wrong about stuff
So would I be ok to trust the information I get from either website?
@last ingot Whatever you say, murderer. It's fine for me to call you that, right? After all, even if you're not one, it's just human nature being wrong. Forget that I'm claiming something is true despite probably mounds of evidence to the contrary and literally no evidence for it. I'm just gonna say it's true, and if I'm wrong... Oops. ¯_(ツ)_/¯
Except with W3Schools, they pretend to be affiliated with the standards body W3C, so it's actually more like I called you a murderer as a cop. And because until very recently W3Schools refused to correct any of its misinformation, let's extend the analogy by me refusing to ever admit I'm wrong and starting a public shaming campaign to ruin your life over it, as will happen to you if you blindly trust W3Schools to be right
MDN is far more accurate and some of the people who work on it are part of the W3C, in contrast to W3Schools.
And, when they're wrong, they actually correct it.
👀
@last ingot C++ specific thing, you will need to watch for different object styles.
stack objects
heap objects
and stack object that hide heap objects.
i do that last one.
the main think is how acting on the objects does or doesnt change the state of other objects.
C++ doesnt have dictionaries
oh, ok.
@novel spear while aware that exists, i completely forgot that the stdlib has that. everyone will be stupid every now and then
and, last i tried to use it, compiler gave me the finger for something something hash, not exactly sure
GCC is not
sense you are here, i dont need to ping you,
Mrmetech, i also know python, so im very aware of what a dictionary is.
oh, wait, i actually didnt know std::map was a thing, i was thinking of std::unordered_map, which does require a hashing function, and is still being a dick.
its gives you a horribly cryptic error message comapred to Clang
Clang is a drop in GCC replacement, for the most part
they help, but Clang gives much much better ones
from /usr/include/c++/7.1.1/bits/stl_tree.h:72,
from /usr/include/c++/7.1.1/map:60,
from gcc_variant_bug.cpp:4:
/usr/include/c++/7.1.1/tuple: In instantiation of 'constexpr const size_t std::tuple_size_v<long unsigned int>':
/usr/include/c++/7.1.1/tuple:1670:44: required from 'constexpr decltype(auto) std::apply(_Fn&&, _Tuple&&) [with _Fn = const std::vector<int>&; _Tuple = long unsigned int]'
gcc_variant_bug.cpp:14:14: required from 'main()::<lambda(const auto:1&)> [with auto:1 = std::vector<int>]'
/usr/include/c++/7.1.1/variant:1236:44: required from 'constexpr decltype(auto) std::visit(_Visitor&&, _Variants&& ...) [with _Visitor = main()::<lambda(const auto:1&)>; _Variants = {std::variant<std::vector<int, std::allocator<int> >, std::vector<short int, std::allocator<short int> > >&}]'
gcc_variant_bug.cpp:15:13: required from here
/usr/include/c++/7.1.1/tuple:1271:29: error: incomplete type 'std::tuple_size<long unsigned int>' used in nested name specifier
inline constexpr size_t tuple_size_v = tuple_size<_Tp>::value;
^~~~~~~~~~~~```
vs gcc_variant_bug.cpp:14:9: note: in instantiation of function template specialization 'std::__1::apply<const std::__1::vector<int, std::__1::allocator<int> > &, unsigned long>' requested here apply(v, 0ul); ^
same code
you can look at a bunch of examples here, https://gcc.gnu.org/wiki/ClangDiagnosticsComparison
and, for me, CLion uses clang for static anaylsis, so its helpful to use the same compiler.
clang and GCC are written in completely different ways, they cant just switch like that
clang is an LLVM module, while GCC is a lot less separated.
ive had no problems with CLion clising windows.
also, you know it has remote development, right?
under toolchains, to the right of the name, dropdown, remote host.
thats how i write code for my raspberry pi
yea, this will do fily synch with sftp
Too bad CLion's Vim plugin is garbage
using Vim
Hello , iam looking for Phyton/C++ developer(php and other are welcome too) ideally someone who have experience in windows developing or made plugins for Windows and MacOs based software.
It would be good if the person can also work on website backend.
Its not that complicated project, if there is interest i can write up what its for.
VS code's python intellicode thingy takes 1:30 min to setup 😠... plus it used 1.5 to 2 gig ram
I am better off with Visual studio which also has intellicode (little worse) but uses less than 600mb ram
dissapointed 😕 and confused at the same time
Well, i need plugin for software (cinema4d) in Phyton/c++ and onther app on server for receiving and showing data from that plugin on website and android/ios app @last ingot
@silent eagle How much are you paying and what's the project?
wait what Python IntelliCode are you setting up @vernal marsh? In my experience, IntelliCode just works on VS Code
@rich cedar paymant is per project not per month. so i would like to get calculation for price based on more info what i would provide to interested people
as iam not programmer, i cant price such task 100%. but i have some number in mind since its realy single task( realy simple) program
so then what's the project
Although I'll admit I'm pleasantly surprised that you'd pay. You have no idea how many people demand free work.
i always try to pay as much as i can. give me sec. i will write whats the plugin will do.
I mean, yeah, you're doing it right, as far as I can tell. It's other people I'm complaining about, who think that just because I'm a programmer, I'll want to get into the ground level of their Facebook knockoff for "exposure"
iam designer so i have experience in that exposure payment industry 😄
So
Iam working on Cinema 4D plugin.
This plug simply need to read value from render engine ( time,frames etc.) and send it to server where its displayed in online app ( also showed in mobile app. what woud probably just show site )
Extra for later version is frame grabber. what would load last rendered frame from folder.
@rich cedar
the hard part for the person is to study ( well documented) documents from Maxon
to find the way to load it 😄 thankfully Maxon made lot of documents how things work plus they have support team for devs
anyone who would be interested in working with me, feel free to PM me. looking for longer term colab. on multiple projects
ah so you're basically trying to make a remote progress tracker?
you could say that
it is to track progress of rendering yes
with alarm maybe when its done
or well if its stops
build in guarddog
Sounds neat!
it does 😄 but iam lacking menpower 😄
Honestly it sounds like a good excuse to learn C++
i cant learn programing for shit
😄
i only do art
i would like to do all that myself 😄 but until i would learn C++ and Phyton i would be 80 😄
i have too many stuff on my hands having that on my mind would be too much
so i just want to find someone to work with
well web/app designs, and 3D, but in general i can do anything
@silent eagle single task( realy simple) program never make this assumption, it is never correct.
anyway, i know python and C++ both, but everyone wants to get paid, soooo, do you have any idea what you woudl be paying?
@modern pivot it's the Microsoft one... In visual studio... It's available for both vs and vs code
Huh, never had a problem with that one
Really... How much ram does it use in your pc... VS code
With intellicode enabled
And python extension
@modern pivot
~200 MB
Not daily, no
OOO... It seems like its analysing 4000 numpy and tensorflow files for autocomplete and type definition
Sounds like a configuration issue, maybe you shouldn’t scan all the files?
@proper gale hi if you wanna talk i send you pm
no, its not.
but, if someone wants soemthing done, and will pay enough for it, i will take their money.
Thats called a job
Anyone has any Idea why is this throwing me this exception
I am not really sure what it means by incorrect format
I have the dll in place
Otherwise the ide must have given me some exception about it.. plus intellisense works 😕
#include "cuda_runtime.h"
#include "device_launch_parameters.h"
#define _USE_MATH_DEFINES
#include <math.h>
__global__ void kernel(unsigned char* src) {
__shared__ float temp[16][16];
int x = threadIdx.x + blockIdx.x * blockDim.x;
int y = threadIdx.y + blockIdx.y * blockDim.y;
int offset = x + y * blockDim.x * gridDim.x;
const float period = 128.0;
temp[threadIdx.x][threadIdx.y] = 255 *
(sinf(x * 2.0f * M_PI / period) + 1.0f) *
(sinf(y * 2.0f * M_PI / period) + 1.0f) / 4.0f;
src[offset * 4] = 0;
src[offset * 4 + 1] = temp[15 - threadIdx.x][15 - threadIdx.y];
src[offset * 4 + 2] = 0;
src[offset * 4 + 3] = 255;
}
extern "C" __declspec(dllexport) void GenerateBitmap
(unsigned char* dst, int dimension)
{
int size = dimension * dimension * 4;
//allocate
unsigned char* src;
cudaMalloc(&src, size);
dim3 blocks(dimension / 16, dimension / 16);
dim3 threads(16, 16);
kernel<< < blocks, threads >> > (src);
cudaMemcpy(dst, src, size, cudaMemcpyDeviceToHost);
cudaFree(src);
}```
that's my kernel which I am compiling as dll ^
Pretty straight forward
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Drawing.Imaging;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace BitmapProcessingCS
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
int dim = 512;
var bmp = new Bitmap(dim, dim);
var data = bmp.LockBits(new Rectangle(0, 0, dim, dim), ImageLockMode.ReadWrite, bmp.PixelFormat);
NativeMethods.GenerateBitmap(data.Scan0, dim);
bmp.UnlockBits(data);
}
private void PictureBox1_Click(object sender, EventArgs e)
{
}
}
}
That's forms1.cs
using System;
using System.Runtime.InteropServices;
namespace BitmapProcessingCS
{
public static class NativeMethods
{
[DllImport("BitmapProcessingCPP.dll", CallingConvention = CallingConvention.Cdecl)]
public static extern void GenerateBitmap(IntPtr src, int dimension);
}
}
and NativeMethods.cs ^
jUST tag me if anyone gets a solution to this thing 😇... I will work on other things till that time
@vernal marsh 0x8007000B is bad format DLL, make sure you're compiling the DLL correctly
Make sure you're building for the right architecture (x86 vs x64)
I think this is good... I have tried different combinations.. but doesn't seem to work out @modern pivot
Have you looked through all the potential causes here: https://docs.microsoft.com/en-us/dotnet/api/system.badimageformatexception?view=netframework-4.8
@vernal marsh A traceback of what happens during compilation would be helpful
sure.. first let me just go through all causes, and tweak things, I did a little before but I definitely didn't reach the end of the article
THAT one specifically
@modern pivot would you like to take a look at my code at kernel.cu ... I can turn on live session
I doubt it's a problem with the CUDA kernel
that being said, I'm not super familiar with DLL compilation, so I'm not sure I'll be much help on that part
I still can't relate any problem given in that article with my issue... I also think that its just compilation issue... but like what? I have also never compiled a cuda type for c#.. pure c++ ones just
@modern pivot got it... it was just a tick mark stating... prefer 32bit (x86) 😡
lol
for the CS side.. no problem on cpp side
I spent 4 hours figuring this out ... turns out smashing buttong is best chance lol
Please help. I'm working on an HTML/CSS/JS project and my page keeps making my paragraph element invisible every time it makes the table invisible even though the paragraph element is outside the table and I don't understand why
Here is my HTML code:
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/css/bootstrap.min.css">
<link rel="stylesheet" href="style.css">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>iamthebull's Pizza Program</title>
</head>
<body>
<div id="menuDiv">
<span id="menu"><strong>Menu</strong></span><span id="menuListSpan" class="glyphicon glyphicon-chevron-down">
<tr>
<table id="menuTable">
<td>Pizza</td>
</tr>
<tr>
<td>Wings</td>
</tr>
<tr>
<td>Sides</td>
</tr>
<tr>
<td>Pasta</td>
</tr>
<tr>
<td>Desserts</td>
</tr>
<tr>
<td>Drinks</td>
</tr>
</table>
</span>
</div>
<p id="pDeals"><strong>Deals</strong></p>
<script type="text/javascript" src="script.js"></script>
<!-- Latest compiled JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/js/bootstrap.min.js"></script>
</body>
</html>
@carmine hawk https://validator.w3.org/nu/#textarea
Or, if you're lazy, here's a hint: What's in the <table>?
@rich cedar Or, if you want to be helpful, tell me what is wrong.
@carmine hawk Learning how to spot typos like this will help you far more in the long run.
And unless you're paying me, I see no particular reason to handhold you to the solution.
For being entitled, you can get the special rate. $150 an hour, 3 hour minimum.
If you're reffering to the misplaced <tr> that doesn't seem to be the problem. I fixed it but didn't find it necessary to repost a whole screen of code just for a one line change
Try running your code through the validator.
Seems like the issue isn't in the HTML, then
I'd assumed you'd already narrowed it down to that, since that's the part you posted
And I assumed that people wouldn't like it if I posted 3 screens of code just to cover my HTML, CSS, and JS
Okay, serious tip: https://gist.github.com/
You can post multiple files with their own names, download the lot as a bunch, makes it easy to share code around
Fair point, people -- aka me -- probably wouldn't appreciate you dumping the whole chunk of code
Equally serious tip: https://stackoverflow.com/help/minimal-reproducible-example
Whenever you want to ask for help, start by making one of those. It's a pain in the *ss at first, but eventually you'll either find the bug on your own, or isolate a code snippet that represents the key thing you're actually getting wrong, which will help you recognize the pattern in the future.
And as you get better at actually making MCVEs, you'll start to be able to do it "in your head", and isolate where the bug is coming from basically by examining the code. Makes bugfixing way easier if you can point to line 384 and ask, "Is this fopen not creating the logfile?" as opposed to "Is something in this massive chunk of code not creating the logfile?"
Apologies for being short with you earlier; I regularly forget that no one teaches this shit
Thank you so much! I think I fixed it! One of the most helpful lines I read from one of your links was, "The problem might not be in the code that you think it is in."
Eyyy glad it turned out to be a teachable moment
Sorry if I sounded dumb, I took one HTML/CSS class about 2.5 years ago and did terrible at the CSS, which has caused me to be spooked by CSS since.

Learning chatterbot, nice
quick poll: How do y'all pronounce "*" (e.g. when reading out a command line like rm *.o)
quick followup poll: how do y'all pronounce *nix
on its own I call it asterisk, in smth like the rm example I call it a wildcard, and just nix
star - and yeah, just nix
I'm the same as freak, I call it "star" unless someone doesn't know what I mean by that, and just "nix"
but someone recently said "star-nix" in conversation with me and that sounds way cooler
I have never felt the need to say either "rm *.o" or "*nix" IRL
if I needed to describe them over voice, they would probably be "rm all .o" and "Unix-like"
I was thinking more if you were spelling the command out for someone to write
@rich cedar asterisk and Unix, yes i straight up just say unix even if its not exactly unix.
A friend of mine is a pentester at a pretty big company. He just sent around a phishing scam to make sure people can spot them, and his boss failed.
Friend: You need to be more careful about what you click on!
Boss: But it came from your email account. Why wouldn't I trust it?
Friend: Because my account might have been compromised, and even if it wasn't, they can still fake which account it looks like it came from. You need to look at the email itself.
Boss: But it turned out fine this time, right? So what's the big deal?
Is your friend the Nigerian prince?
nah, just the IT security guy
does anione know how to modify the login screen on a nextcloud (snap installation)
Just started at my new company and relearned the joys of onboarding
@rich cedar always a fun process :P
@rich cedar what do you do?
im happy, i wrote a thing specifically to be faster than my other thing, ended up about 5 times faster, doc time: 187578492 conf time: 1037710193 doc speedup: 850131701
@rich cedar "anything"
@junior dew Go into the source and change it however you want.
make a backup first so you can roll back when it breaks.
@bleak summit yeah, i usually do a snapshot, Thanks!!
@rich cedar no shit, any more details?
for real tho, no
Mmk
If I talked about what I'm coding I'd get fired, and possibly arrested for treason
I was more asking about what position level it is
Oh, internship
Ie, systems level c/c++, Java something, web js, etc
yeah no can't say that
Sense you mentioned treason, I'm guessing it's at a company like Northrop Grumman
Something like that
@rich cedar What kind of stuff do you work with / specialize in outside of work?
oh boy lots of stuff
I've been poking at a game -- a kinda depressing FPS where you fight as part of a guerilla resistance, which I'm trying to make realistic while keeping it fun
Right now it's mostly at the "figure out what I want this game to be" stage, with some mild prototyping to teach myself Unreal Engine 4
I'm also seeing if I can use my cheap SDR and RPi to build a stereo
At first it's just gonna be play/seek forward/seek backward, but I'm building it so I can pretty easily add remembering stations, playing from USB, maybe even ~fancy stuff~ like connecting to WiFi and playing from the internet
@gloomy tinsel professional drivers on a closed course, do not attempt.
Driving in russia be like
In case anyone hasn't already been introduced to the awesome Captain Disillusion.
https://www.youtube.com/watch?v=S_doxRtYd8o
Something is a bit off... as Captain Disillusion and Mr. Flare host a morning show and explore the visual effects secrets behind the "Rush Hour" viral video....
He is a blender dude right?...
yes
I think I watched one of his videos before when I started learning blender 😅... Nice
why does microsoft call QWORDs DWORD64
Does anyone know of an open-source GNTP server/receiver for Node.js?
@round dome Because they took DWORD, then needed a 64-bit version
a DWORD is 32 bits a QWORD is 64
guess they also have QWORD, I don't understand why they would have the need for DWORD64 https://docs.microsoft.com/en-us/windows/desktop/winprog/windows-data-types
ngl I love my job but I kinda hate that I can't talk about it
The onboarding, aside from a meh first day, has been great, and the team is just genuinely fun to be part of
But I can't even say what type of coding I'm doing or what languages I'm working in
I literally can't even give a fake example of something I can't say because that would reveal too much
For not being able to talk about it. You sure talk about it a lot. opsec my dude. There are now however many people in here who now know that you are most likely a juicy target working with some kind of security-clearance-required DOD or other sensitive work.
These people would not have known this if you hadn't done all of this blabbing.
smh
@rich cedar
Do you have a security clearance? It is not a violation for someone with a security clearance to say "I have a security clearance"
Security clearances just don't play into it
Based on what you have said. You are either lying or have a security clearance.
You mentioned that if you talked about the stuff. You could possibly be charged with treason.
There isn't a single thing in this context that could land you with treason charges without having a security clearance
...it was a joke
So, sure, call it a lie if you want lol
Clearly a bad joke, if it didn't even come off as one
I have a hard time believing it's a joke given the other things you were saying about the high level of secrecy of the work
point is. You are leaking info. You won't admit it to me but you do see it.
stop talking
this is srs
we will drop it here.
Yeah, see how bad this got lol
insofar as it's a "leak" to say what I'm allowed to say about my job
Which is that it's very hush-hush, I do code stuff
@rich cedar you are allowed to tell people you have security clearance, security clearance is common and does not give you access to information it just lets you access the stuff you need to access for your job on a need to know basis
that being said, often people who work at places such as three letter agencies will not go telling people they work there lest they become a blackmail target
but the same applies to like, people working R&D jobs
nobody wants the prototype iphone stolen
anyone used trfl? I cannot get any starting up guides on it upon a quick google search
nvm found it... there is a link in the bottom of the readme
@novel spear I'm aware. I've also said everything I'm going to say: that I develop software, that I enjoy it, and that I can't talk more about it. I was venting here because it's frustrating to me to have fun at a job and not be able to talk about it.
Meant to tag em not you
Can someone help me: https://github.com/GameMaster2030/TokoRadioMenu/blob/master/client/client.lua
Trying to create a plugin for fivem utilizing the NativeUILua-Reloaded and TokoVoip API.
But the menu doesn't work like expected, the error lowest in the file is the most important one atm.
Mention me if you can help me
Nvm
@rich cedar To be honest you should just not talk about it at all. It's much safer for you that way.
I'm done talking about it anyway
I'm tired of people who know literally nothing about it telling me what they assume is correct
Despite, obviously, having no idea
I'm not assuming anything, I just think it's a better idea that you don't talk about it.
I mean I wasn't talking about you
I get it
You aren't flatly stating that I'm not allowed to say things I've explicitly been told are okay to say.
I agree, not talking about it would be safer, but I'd rather vent vaguely than accidentally let something slip because I'm frustrated
@rich cedar yeah..sucks....go to a place that supposedly will have people that understand.....and just find more frustration and stress from the unexperienced/non-learned
wish u well
anyone having this problem in vs code... its been, there for weeks now??
Logo looks great though..
NOT just vs code but also "Hyper" and other electron thingies that I have used... Thinking it might be my system issue.. but its not making any sense to me
Also, atom
include that ^ in the list of not working 😅
I mean just terminal based...
have you tried "not insiders" version ?
also you might try https://code.visualstudio.com/docs/editor/integrated-terminal#_changing-how-the-terminal-is-rendered
@cloud knot Seem like all the things I just told are insiders/beta bugs.... 😅
anyone know anything about installing klasa for discord bot creation?
everytime i go to install, regardless of where it is, i get these errors
https://gyazo.com/79f20bccb6ab2dfbba2b1f8af7f39103
klasa documentation says nothing about where to install, so i assume it doesnt matter
nor does it say anything else about installing other than run the command
‘Undefined’ plus git arguments usually indicates git isn’t installed in PATH
I’d check your git install.
@nocturne galleon thank you, that was the issue
idk why but it mustnt have installed properly the first time, a reinstall fixed it
same with running it on pycharm (which I downloaded just to see if VS is little mad)
by results I mean visible output
What do you guys think about flutter? Should I give it a go? And is dart enough for API handling and stuff?
@ionic hull flutter is a very dangerous problem that aircraft manufactures need to work hard to ensure doesn't happen when in normal operating parameter. what is there to think about it?
||yes i know thats not what you meant, but its the first thing that came into my mind when i read it, so i send this message anyway.||
I've gone trough the flutter and dart docs and it looks promising, I just wanted to know how does dart handle heavy tasks and such
yea the event driven nature of languages based around js usually means they are pretty good at processing requests
like compared to a forking server
Thanks guys
anyone had experience creating discord bots?
if someone knows how to mention everyone using the bot, it would be appreciated, i cant seem to get it to work
@rancid wren you litearlly have the bot write out @everyone and it should work.
@proper gale thanks, i figured out what it was, theres a variable that gets passed through disableEveryone, it was set to true
👀 I can Discord bots 
@ionic hull coming from go, it's basically always going to be your connection, or maybe OS that becomes the limiting factor when dealing with a lot of http traffic
Heya, could anyone help me with .htaccess file on Apache?
to forbid access to a specific directory
everything from google didn't help
@last ingot also can't access root directory and change any settings there
@tepid zephyr can you describe your situation a bit, sounds fairly unsafe
@tepid perch basically one of the tasks for a final web app project is to disable /private directory inside project directory with .htaccess and .htpasswd, but no matter how i configure the file it just doesn't pop-up the login promopt
Dear God do not use that
it's literally a requirement in a project lmao
requirement in the project ouch. I hate the stupid, out-of-touch crap I've seen in assignments over the years.
I remember doing software design and development in high school. Visual Basic and "standardised pseudocode", because that makes sense.
Oh yes. We had to do IEEE 754 by hand in the final exam.
As one does as a programmer.
Basically. It stops being pseudocode at that point.
By hand in an exam? High-school level?
Also bubble+insertion sort.
The curriculum for that subject was mostly written 16-odd years ago at a minimum.
Teaching it in the form it was written and targeting students who are new to programming is just a bit BS. Nothing like what any programmer would be expected to do in the field.
I'm totally fine with this kind of content in a software-oriented uni course as long as they updated it so they didn't mandate VS 2008.
Not first year, maybe 2nd or 3rd.
I'm just a boring old IT networking student, YMMV. Intro to Python/NodeJS, basic database stuff, a bit of project management and communications (the between-people kind)? Then dig into algorithms, some useful maths and the like.
Practical stuff is good.
You don't need to have an advanced understanding of algorithms to be a reasonably effective programmer. I think that getting them into the habit of writing good, clean code in something, getting them to communicate with their peers better, and showing them how to manage a project is if anything more useful of a start.
Then you go off into the more advanced stuff.
That way even if they drop out they can use what they have learned to make something of themselves.
Had a startup interview me and a bunch of software dev uni students accross Australia. Apparently I was the only one to know what Git or any other version/source control software was.
That's absurd.
Git or something like it should be day one if possible.
I'd say that an intro to Linux course wouldn't be a terrible idea in a software dev degree either.
I had to sit through an intro to Windows 10 in second year, but the content covered features from 98 and even some that were removed.
Most uni students I know have never touched anything bar Windows.
GPLv2 doesn't really hurt deployment of Linux much on devices, it's v3 that makes deployment harder.
Plus support and getting some kind of GUI up is much easier, and the shell and utils are mostly identical.
GPLv2 from a Linux perspective covers changes to Linux itself made by you. Not your own stuff shipped alongside it.
Not anything that deals with the kernel, though you have a point.
I've torn down a lot of devices and haven't seen anything bar embedded Linux so far, BSD-only anti-GPLv2 environments strike me as rare.
Apple, yes.
Not a ton of other current scenarios or participating companies rise to mind.
TBF the China specials' just violate the GPL and don't care, so Linux is of no consequence to them.
Same for most big companies.
Switch is FreeBSD apparently. Fair.
Also on BSD networking being superior. There's exciting new stuff going on there for both sides with DPDK, but Linux driver support is better.
PF itself has upsides and downsides, most of which I do not pretend to know.
Anyways, it's late and I must be off. Nice chat.
@dapper laurel "here's a language and how to write hello world, now you're on your own - use the documentation, we've got actual shit to learn" this is fine if they already know another language, but terrible if you dont already have at least one that you can use.
no, but you will already have something to build on in the real world
also, just because it was small intro then newton's method doesnt mean that the teacher didn't design what things you were doing specificly so that you get the same things just, you learn them by doing not by lecture.
so did i, doesnt mean that i recommend jumping in the deep end.
@inner wraith yeah and it seems it's their side that they fked up, as i can't access to root directory and change some settings for it to work. so i'm basically losing points on final project at uni because they're inacpable.
not to mention our database presentations were from '97. i mean 1NF, 2NF, 3NF and theory stuff like that doesn't change but it's just goes to show how any means of classical education can't teach you to write modern code.
@fierce quest just for a sake of mind, how much of floatplane's backend is written in php?
PHloatPlane
even php is so widely used i don't see much of future potential
I know it's not needed. Just wondering what's mostly used in modern web apps.
Found a registry key named startupsound or something while adjusting a few settings in a fresh Windows 10 install. Enabled it and rebooted. The Windows 10 startup sound is STILL the Windows 7 bootup sound! 
The key is in Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Authentication\LogonUI\BootAnimation and it's named DisableStartupSound. Set it to 0, then reboot for Windows 7 throwbacks 😉
Lol Nice... But isn't it changeable in control panel? @tropic grail
Setting was written as _"startup sound" _
I think
Is the a registry key to stop updates until I want to actually restart my computer
@vernal marsh doesn't work on newer installs.
@alpine talon there's a policy for not installing until you approve the update, but not sure of the key. Set your inactive hours to like 2-8am or something.
Hmm ok
Anyone experience with Laravel deployments using ansistrano and gitlab ci/cd?
To stop windows updates install Linux
@timber anchor i actually did that
🤔 very nice
you get used to linux pretty quickly.
Is 16GB a good amount of ram for a programming orientated laptop?
@native shoal Which IDE are you using and how big are your projects?
@proper gale @odd cypress It's for a friend but I think he mentioned maybe some Java and visual studio for intro projects. Nothing major right now
He's starting college
I'm completely satisfied with 8 GB on my laptop and I'm using VS and VSCode too, so 16 GB should be totally enough.
Most of the time my IDE only consumes 2-3 GB.
Oh good. He was eyeing an XPS 15 that had 8GB
And if he finds out one day, 8GB are not enough, he can (probably) easily upgrade the ram.
@native shoal 16GB suits me well enough, but it'd depend absolutely on the OS, IDE/s, workloads...
Definitely go for a machine that can grow a bit if you need it to (more RAM, more disk, yada yada).
8GB's a bit low IMO for Windows + VS.
Alright. thanks for the insight
If I'm a C++/Python developer, should I get a Macbook just because Macbooks are what a lot of developers use, or should I go with Windows/Linux?
@carmine hawk I say Linux.
less so modernly
steve ballmer left
and suddenly notepad has unix linebreak support and windows knows what ssh is
@last ingot use linux for most things, reboot to windows when you want to game.
check out the new linux on-windows stuff
or GPU passthrough VM that shit.
you get all your tools and stuff
just no wayland
but for like compilers and shit its all there
and the new vs code remote stuff I think is meant to make it easier to run tools here but the IDE there
but I havnt tried it
oh, there is xming, so you could use that.
and most environments run on windows now outside of the command line
like gtk and qt and such
yeah of corse
Linux has come a very long way. Desktop is super easy to use and you can learn commands at your own pace
Howdy Anyone got any ideas where to find a memory editing program for editing flash memory Looking for something to edit a bios chip with i already have the aligator clip with the board for editing the memory of the chip
Just looking for a good flash memory editing program
Previous owner of this board i got for 2 dollars flashed the bios wrong and im gonna reflash it to factory default with the memory editor
If it's a winbond chip, it might be as simple as popping it into an identical working board while it's booted and flashing it while the system is online. Otherwise enjoy looking for an RPi or arduino flash encoder.
The other option is to check and see if the board has a fix-if-corrupt option for the bios. Some boards do.
I already have the flash encoder with an aligator clip just was looking for a program for editing the flash memory with
lmao I have heavily underestimated how long this would take me. for our CS class we have to draw a story board to show what each window and tab will look like in our program and it has taken waaay longer than I thought, im already behind and it got graded already so my grade average got oofed
unfortunately we have to draw the story board for two alternative designs of the software we are creating then run them against criteria that we create, then program the one we decide is the best
whoops, I just realised that sounded aggressive, sorry about that
Just an advice for whoever is working with CUDA lib using cuda C... USE THRUST LIB Instead of running and gunning with Runtime API or Driver API, saves a ton of time 😇
I believe it's even included in CUDA dev toolkit
do you guys think it's possible to learn angularjs and nodejs in 2 days? 🤔
im a fast learner buuut i think its going to be not enough time 👀
I'll see how far i get with exercises and nodejs that weekend 👀
because i really really need nodejs 🤔
if you already know js its very easy to learn those two in two days in terms of enough to make something quickly
but there are likely best practices and design and special features and tooling in the api which will be missed
only if you are good at reading api docs, inferring a lot of stuff, and guessing
assuming you already know js, and are familiar with event driven design on the node side and data binding and good frontend dev practices already on the angular side
and are okay with making a pile of code which technically works but is not maintainable (be ready to code the whole thing again in 2 weeks when it blows up)
and html
like if I used the phrase "dependency injection" would you know what that means
i did pretty much everything in js until now, but i messed my weekend up by sleeping until noon 🤔
@nocturne galleon still need help?
Hello 👋
Anyone in here willing to help me with docker-compose?
Basically the situation is;
I have a few containers: apiserver, appserver, mongodb, mongopanel.
We can ignore mongodb and mongopanel.
I have two docker-compose files (setups) - development and production version.
When in dev, both containers have mounted volumes from host OS;
- appserver has the
./appmounted to/var/server - apiserver has the
./apimounted to/var/server
'till here everything works just fine.
But the production setup... ...this one doesn't have any extra volumes.
Everything sounds about right... until I start the containers and apparently both containers (apiserver and appserver) run the same commands (script from package.json file) even though the actual files in ./app/package.json and ./api/package.json files are totally different (one for frontend and other one for backend).
Basically - the problem is that for some reason, files that should be copied from ./app to appserver and also copied to apiserver (and reverse)
The file scrtucture is something like this:
api/
\_ src/
\_ package.json
\_ yarn.lock
\_ dockerfile
app/
\_ src/
\_ package.json
\_ yarn.lock
\_ dockerfile
docker-compose.dev.yml
docker-compose.prod.yml
Please tag me if you reply.
@nocturne galleon what's the issue you're having with the catch-all entry?
@hearty shadow docker is notoriously insecure lately.
Also your dockerfile would be the one telling it where to copy from. If that same dockerfile sets both up, there's your culprit. Use separate dockerfiles.
thanks for taking your time.
That's why I am so confused - I am using two separate files, each in itown directory, etc... I can not find the reason why it would not work as it's supposed to :/
Do you specifically specify ./app/dockerfile and ./api/dockerfile? Check for typos.
The dockerfiles are correctly read.
Because the package.json and yarn.lock are correctly copied and modules are correctly installed.
The issue occures later on when the containers are started up
As mentioned above (even though very briefly) - when in development mode, everything loads up just right. Well better said when volumes are mounted from the host OS' filesystem.
but when the setup is running in production mode (no volumes mounted) the startup is somehow messed up and both containers start from the same image or something...
I don't know man - I'm giving up on this shit to be honest. I'll probably just remake the whole thing tomorrow.
(not the app. The "wrapper" layer - docker setup, etc..)
^ I actually managed to fix this mess. 👌
hey, i need someone to teach me how to create a catchall aswell with AWS
Probably not gonna happen here. Not a teaching server.
got my Radeon VII in an x16 slot, ROCm installed properly, and its beating a P100 (DGX-1) pretty handily (about 25% lead) on Resnet50 batch size 32
any prestashop devs?
@stable ivy what do you need?
working with userChrome.css
used '-webkit-transform: perspective(100px) rotateX(30deg) !important;' is there a way to add antialiasing to make the lines look smoother?
o.O -webkit-transform? Why not just transform?
but uh, iirc the best way to get slanted sides is to use an svg (you can data: URI it)
;-; well, im still new to css n all ^^
"-webkit" is a so called vendor prefix, it's an older practice where browser makers would prefix the features that weren't standardized yet with their own prefix.
these days you should rarely need to use a vendor prefix, especially not a webkit one in gecko/moz specific code...
either way, I wouldn't be surprised if you can't get good AA on tabs using transforms, due to how and where they're drawn.
The old "rounded" tabs used svgs, too
ah i see, maybe i should look into modern css programming like websites n all before i jump the gun into trying to redesign my browser 0.o
well, firefox's UI is also its own esoteric version of how you use css
(XUL and not HTML, which uses different layout rules, even though it uses CSS...)
so you'll need a different "css knowledge" either way
true, my only knowlege so far was trying to use xmal n that ended horribly ;-;
in terms of design stand point of course
css is lovely
some people hate it
i love it
i could spend years at styling and won't get bired of it
ok so im reading a old html book to teach myself im stuck on understanding what <code></code> does at what its used for
By default <code> uses a monospace font (https://developer.mozilla.org/en-US/docs/Web/HTML/Element/code) , and semantically indicates that the contents represents a code snippet. For example, if Discord is being compliant then stuff in single backticks will be wrapped in a <code> tag
there are many elements in modern html you will find are mostly semantic. The semantic usage of html elements allows for easier themeing, easier processing for search engines or reformatting, and much better screen reader functionality
ok thank you
Just realized the manager role is a trippy shade of purple, lol.
if Discord is being compliant then stuff in single backticks will be wrapped in a <code class="inline"><code></code> tag
@ember kiln Seems so.
hey anyone got something interesting to read in terms of ml (something with math would be better).. I am taking a break from trying to implement a RNN to recognize a single stream audio.. with just 2 words 😑
FUCK YOU GITHUB https://dooleylabs.com/kaitya.png
Like why tf won't you let me PR my shit. This is why GitLab is superior you sellout shills.
@vernal marsh no I'm trying to make a PR to something related to the bot, but GitHub apparently has a new bug that it won't push.
🤔 I think something is wrong can someone help me design a bit better
@nocturne galleon use text sizes changes to indicate a change in importance or context rather tahn willy nilly
same with text color changes
you have a heading thats blue then you have a number thats blue
be consistent
also you might have a better time by putting the avatar circle stuff in the top left or right or very bototm, not middle
also if account settings is a button, make it look different from "xtreme ultimate"
I would also try to equal height yoru dashboards
thats all the advice I have for now
oh and for how unimportant it is the avatar dashboard square is really big
its the biggest one
if you want it to be big maybe avatar as one column, then the three at the top stack those as a second column, then the rest as a third column
Good idea ty
i hate ui programming
WTF
now python is giving me an error for code i commented out
How did you comment it
Did you use quotes or did you use number sign
Quotes still parse. Number signs do not
Otherwise did you execute a file different from the one you are editing and not notice
why does PyQt5 not show my window icon? it's in the same path and everything but when I tell the program to use it it just uses the default window icon
give it the full path, use setWindowIcon, wrap it in a QIcon
so like setWindowIcon(QIcon(fullPath))
full path being like C:\
you can use the python libraries to convert a relative path to a full path
does anyone know how to make a table in PyQt5 the minimum size it needs to be? as you can see this table takes up basically the whole window when it doesn't need to
With all due respect, have you tried looking at documentation? I find that reading documentation helps a lot.
Be sure you understand what layouts are
Check the docs
Also its possible your icon is just a format that doesnt work for window icons
Again check the docs to be sure. Check the qt docs rather than pyqt itself they are basically the same one just wraps the other
But rather well documented
quick question in terms of programming; to get gud habit of programming in an industry standard is it okay to write big one line codes? when u could have split it up?
example:
ListBox2.Items.Add(TextBox1.Text & CheckedListBox1.CheckedItems(i).ToString.Remove(0, CheckedListBox1.CheckedItems(i).ToString.LastIndexOf("/") + 1) & " -- (" & (CheckedListBox1.CheckedItems(i).ToString.Substring(CheckedListBox1.CheckedItems(i).ToString.LastIndexOf("/") + 1) & TextBox1.Text & CheckedListBox1.CheckedItems(i).ToString.Remove(0, CheckedListBox1.CheckedItems(i).ToString.LastIndexOf("/"))) & ")")
I a code review i would say the following things
Use a variable for checklistbox1.checkeditems(i)
And
Use a string format statement for readability with the individual substrings broken into named variables
But the length isnt the issue the issue is the readability and maintainability
Named variables are easier to read and repetitive access to the checkeditems(i) is a maintainability and readability issue
because like even TextBox1.Text & checkedItem.Remove(0, checkedItem.LastIndexOf("/") + 1) & " -- (" & (checkedItem.Substring(checkedItem.LastIndexOf("/") + 1) & TextBox1.Text & checkedItem.Remove(0, checkedItem.LastIndexOf("/"))) & ")"
is unreadable, I have no idea what that is doing
I would also suggest that there should not be so much manipulation happening inside the gui code. Like thats the kind of thing that should happen outside your gui code
like I think maybe thats path manipulation?
something like "{command} {fullpath} {filename}" is way more readable you know?
yeh i see what u mean, if i was using alot more different objects id have renamed them
but because its only 3, internally i know what im on about,
if it was a group project or some sort i know in the industry its best to always* name what each thing is
so as said, someone who has no idea and has never seen the code understands whats goin on
hmm for second part i guess ill rework the code to grab the file name with a function when u drag the file into the program, make it tad easier and cleaner,
the docs are a bit hard to understand because i use python and it looks like they use c++ in examples
@nocturne galleon considering that qt is a c++ library, I would expect that.
Church for pyqt docs specifically
I can still somewhat follow it, but if I can find docs on pyqt that are actually helpful I use them
bruh
TypeError: addWidget(self, QWidget): first argument of unbound method must have type 'QStackedWidget'
Be sure you dont call a function on a class call it on an instance.
It looks like you did QStackedWidget.addWidget
Pyqt assumes you understand qt so you should read both docs.
@nocturne galleon you may think that but wait until you step away from code for a month or years then come back to it
So I have this EJS file, but the document.write part isn't working correctly. Any idea why?
https://hastebin.com/akokoxifir.js
Ping me if you know what the issue is
are there any errors in the console
I assume its because you used "let" which is not globally scloped
scoped
let icons = []</script> I think makes icons go out of scope
but your console should have an error, if not make it console.log(icons) and check if its just undefined
@sacred shuttle I will note its a very unusual pattern to use templating for the html along with repeating scripts rather than just templating some initial seed data for a script to consume
but thats not why its broken
welp need help, so this line of code as highlighted has an issue that says date does not exist in context. not sure what to add into the code
Also I need to have these script tags since in every ejs thing it needs a own script block
@cloud jay well, you aren't assigning anything to date or time.
And I would not use string interpolation for that. Use parameters: https://docs.microsoft.com/en-us/dotnet/api/system.data.sqlclient.sqlcommand.parameters?view=netframework-4.8
yeah but I want to figure out what to put after date =
@cloud jay What is it you are trying to do here?
Because it seems to me that you can cut out all the select and iterate through the results stuff and just run a delete command.
Sorry, I have Windows only. Best to write apps so they're cross platform compatible.
@limpid reef sometimes apple ecosystem users give all them monies
Yup, sadly, this is too true, but it's also the reason I'll never be able to use apps like Notability because it's not cross platform compatible... which kind of defeats the purpose for some types of apps.
@nocturne galleon don't post shady things k thx.
@tropic grail ok
@limpid reef i write some stuff linux specific, but not because im trying to not support windows, but because it doesnt need to, and im too lazy to support it with something that will never be run on windows.
in general though, cross platform FTFW!
Totally understandable - I mean, technically if you're really just trying to do one thing for a niche project or smaller community, writing for the OS you use makes total sense.
Any linux heads around?
I'm getting so annoyed :/
I'm working on a cron job, to check and recover ark files if required. I need to get the biggest filesize of .ark files and if .TheIsland.ark file is smaller it'll auto backup and copy over the biggest size. Now while I have this working out side of crontab one part of the script fails. Which is: actualmap=$(find $PWD -type f -printf '%p\n' -name "*.ark"| sort -nr | head -1)
If I remove the \n it actually works but then it cant sort between them as it's not in seperate lines.
Any ideas on a workaround.
The output I get on cron job with \n is:/srv/daemon-data/da4aaa1b-0ce9-46d2-bd60-5f599cc089ae/ShooterGame/Saved/recovery.sh (which is the recovery script)
The same line of code ran in terminal produces the correct output of: /srv/daemon-data/da4aaa1b-0ce9-46d2-bd60-5f599cc089ae/ShooterGame/Saved/SavedArks/TheIsland_NewLaunchBackup.bak
Without \n using crontab I get: /srv/daemon-data/da4aaa1b-0ce9-46d2-bd60-5f599cc089ae/ShooterGame/Saved/SavedArks/TheIsland_27.06.2019_21.46.20.ark/srv/daemon-data/da4aaa1b-0ce9-46d2-bd60-5f599cc089ae/ShooterGame/Saved/SavedArks/TheIsland_28.06.2019_15.15.34.ark
Please help I'm tearing my hair out.
i would use a python script myself
you also would want to use most recently modified not largest for a backup, as it could get smaller.
I would but ark has a habit of over writing the file which would make it the most recently modified throwing that idea out the window
you could look at creation then, should be logged too
fuuuck
my youtube downloader doesnt work anymore for some stupid reason
Gee, totally not because YouTube's EULA disallows the use of downloader tools 
hasn't it always been that way?
Downloaders are illegal according to YT's EULA. YT works daily to break downloaders to enforce this rule.
ffs
youtube-dl totally doesn't exist btw 👀
I know nothing about youtube-dl.... mind you, technically streaming the video through the YouTube HTML5 web player makes a copy on your PC, so you're still downloading it. They just don't want people actually transcoding or transferring it to anything NOT contained within their platform or web player.
@limpid reef there's no need for that
yt-dl can be used for streaming, and caching is different than downloading.
Righto, actually I always forget you can pipe youtube-dls output directly to VLC or any other media player capable of opening a network stream.
Almost every Discord bot/music bot uses yt-dl or FFMPEG (or both) to stream audio directly into an audio endpoint without caching whatsoever.
never knew that downloading youtube vids was illegal tbh
im starting to learn swift code:
import UIKit
class ViewController: UIViewController {
@IBOutlet weak var myWebView: UIWebView!
override func viewDidLoad() {
super.viewDidLoad()
let url = URL(string: "https://www.google.com")
myWebView.loadRequest(URLRequest(url: URL!))
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
}
}
@brave jungle common sense.
We don't need the full explanation of how you can claim ignorance to the EULA though 👀 By using a site, you agree to their EULA, privacy policy, etc., which almost all major sites have because GDPR forces it.
Well, i used to be 12 a year ago, and i watched Youtube 
@tropic grail i dont understand why its common sense, i dont download music videos or copyrighted content, just normal ltt videos or something
Still under those same rules, but in the case of LMG, so long as the videos are for personal use and not reuploaded, you're fine there, as far as I am aware.
Nope. Once you agree to these agreements, you also agree to a non-arbitration clause, which means you couldn't even get it that far.
I opted out of that shit with discord.
what is the difference between QStackedLayout and QStackedWidget, according to the internet they are both "provide a stack of widgets where only one widget is visible at a time"
im using PyQt5
im still confused
they seem to be the exact same thing
anyone on here wanna help
im trying to make an http request that will be redirected by a 302 status code preserve its post method thru the redirect
as in
i send a post request
it gets redirected by a 302 status code (i have no control over this server)
and then i want to also make a post to the new url
and i cant do it thru two separate requests
like i cant just store the new url and then send a post to there
it has to be the same request
language javascript + node.js + electron
im using electron clientrequests
cuz i need to use their interceptors
im also not entirely sure how to add a body to an electron request
@last ingot 😩
:pepehands:
thx anyway
have you looked at the followRedirects method ?
https://electronjs.org/docs/api/client-request#requestfollowredirect
Make HTTP/HTTPS requests.
Anyone here know which version of TensorFlow supports CUDA v9?
I think the latest version of TF that supports CUDA 9 is 1.12 @grizzled panther
Thanks!
Tailwind or Bootstrap?
ItemsSource="{Binding Source={x:Static core:RGBSurface.Instance}, Path=Devices}" worked fine in my WPF code
how would i make that work in UWP?
this is the whole code block
<ItemsControl.ItemTemplate>
<DataTemplate>
<TextBlock Style="{StaticResource StyleTextBlockForm}">
<Run Text="{Binding DeviceInfo.Manufacturer}"></Run>
<Run Text="{Binding DeviceInfo.Model}"></Run>
<Run Text="{Binding DeviceInfo.DeviceType}"></Run>
</TextBlock>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>```
the problem is, x:Static doesnt exist for UWP apps
whats my best option for a workaround
dont use static access
make a view model and make that access whatever you need then bind to that
the bonus of that is you can unit test the view model too
how can i securely make an application remember user credentials so they don't need to login every time they open it?
A cookie with a RSA public key that expires after a set amount of uses or time, that must come from a specific IP, and have the signature of your application in the user-agent, for starters.
hey guys
i need some help with admob and android studio
please @me if you have some background with that
and, how again is that a software issue?
@nocturne galleon if you dont wanna mess with pki you can just hmac it