Skip Navigation
No Stupid Questions (Developer Edition)

This is a place where you can ask any programming / topic related to the instance questions you want!

For a more general version of this concept check out [email protected]

Icon base by Lorc under CC BY 3.0 with modifications to add a gradient

Members
1,047
Posts
40
Active Today
1
Created
2 yr. ago
  • No Stupid Questions (Developer Edition) @programming.dev
    insomniac_lemon @lemmy.cafe

    Is there a simple way to get an unshaded-but-lit look?

    This is for models that use vertex colors. I want all faces with the max brightness of the object. So in daytime lighting it should look unshaded, but in a dark environment it should darken (like the thumbnail).

    What I've tried:

    • using vertex_lighting and then setting the normal directly (eg NORMAL = vec3(0.0, 1.0, 0.0);)
      • this works, but only if the lighting is perfectly overhead... a slightly wrong angle or even too far into the middle of an omnilight will create a shadow
    • attempting to save the original color value, change the normal, and then bring it the old brightness back via max() if the new value is dimmer
      • lots of moving parts/assumptions on my part here
    • other math stuff with NORMAL/VERTEX, abs() and normalize() etc
      • on top of the direction failure, there's also failure to keep consistent brightness (with a spinning animation), and darkening across a TextMesh

    I also know I could do this with unshaded and just multiply/mix it in the shader, but I don't r

  • No Stupid Questions (Developer Edition) @programming.dev
    edave @programming.dev

    Sharing AI-Aided Knowledge Beyond Corporate Platforms

    Seeking Direction: Sharing AI-Aided Knowledge Beyond Corporate Platforms

    As a Reddit (and RIF) refugee, I'm searching for a space to share various useful information where it can be easily found later. The challenge is that the definition of "useful" varies among individuals, and I suspect that Reddit and other "for -profit" moderators are overly influenced by corporate interests.

    In the past, I spent considerable time figuring out how to accomplish tasks unrelated to my primary goals—tasks I usually only needed to do once. Now, I tend to ask AI tools like ChatGPT, Perplexity, Deepseek, or other available models to assist with the task at hand. I've learned that by doing so, I can condense days or even weeks of effort into just a few hours, if not less.

    However, a significant issue is that these AIs don't currently learn from my questions, and the knowledge they provide isn't propagated beyond the AI itself, unlike traditional sources. The AI models offering this information are ess

  • No Stupid Questions (Developer Edition) @programming.dev
    3rr4tt1c @programming.dev

    Is it okay to leave tests in your code?

    Like if I'm using print statements to test my code. Is it okay to leave stuff like that in there when "publishing" the app/program?

    Edit: So I meant logging. Not "tests". Using console.log to see if the code is flowing properly. I'll study up on debugging. Also, based on what I managed to grasp from your very helpful comments, it is not okay to do, but the severity of how much of an issue it is depends on the context? Either that or it's completely avoidable in the first place if I just use "automated testing" or "loggers".

  • No Stupid Questions (Developer Edition) @programming.dev
    quickenparalysespunk @lemmy.dbzer0.com

    Graphene OS Devs or users, Play Integrity updates -> Aurora DOA? or just need a few more workarounds/alternatives?

    To what extent will these changes, and potential future changes along the same trajectory, affect the use of un-substitutable apps on Graphene OS?

    Play Integrity API - 2024 Dec

    The transition to the new verdicts will reduce the device signals that need to be collected and evaluated on Google servers by ~90% and our testing indicates verdict latency can improve by up to ~80%.

    the huge ratio of reduction suggests to me that the attestation is being offloaded from Google servers to on-device AI, but maybe i assume wrong. my instinct tells me Google would always make this impossible for 3rd party OS to implement anyway.

    Hypothetically, If implementing that AI in Graphene could allow most attestation-requiring apps to install and run normally, is that something the Graphene devs would do? i know it would have to be secure and private, so assuming there was a way...

    I'm not p

  • No Stupid Questions (Developer Edition) @programming.dev
    quickenparalysespunk @lemmy.dbzer0.com

    is there anything like an app/script for .tar files that automates configure-make-makeinstall into a single step for the end user? (after onetime manual config)

    In my understanding, the options need to be customized for each machine, as well as the fact that making packages for tons of distros can be a lot of work for solo or small team devs, and that's why some software is provided as .tar only.

    but it seems like the install process on the user side could be automated to a single command or drag-drop, as long as the script would throw informative alerts for any errors and the user is prepared to take over manually.

    does something like this exist in a standalone form that's not bundled like snaps or flatpaks?

    if not, is there a broadly-applicable reason (security, damaging OS, etc) that makes it a terrible idea? or simply that no one has gotten to it?

  • No Stupid Questions (Developer Edition) @programming.dev
    ALostInquirer @lemm.ee

    Is there a way to submit issues for software on Github without creating a Github account?

  • No Stupid Questions (Developer Edition) @programming.dev
    Ephraim @lemmy.dbzer0.com

    Good sources and examples to deploy a bittorrent tracker that depends on JSON as a database?

    The idea is making deployment so simple even a 13 year old could republish the website in cloudflare or github pages.

    Any other tactics are welcome

  • No Stupid Questions (Developer Edition) @programming.dev
    ertai @programming.dev

    Is a terminal with multiple cell sizes possible?

    To my understanding:

    Many terminals are capable of displaying multiple fonts at the same time, say latin unicode characters in font foo and japanese unicode characters in font baz. In urxvt at least, it is also possible to have one font in a certain size and the next font in another size. However, no font can have a size bigger than the base size, the size of a terminal cell.

    Why is it not possible to have multiple terminal cell sizes? For exampleso one line has terminal size 8 and the next line has terminal size 12.

  • No Stupid Questions (Developer Edition) @programming.dev
    onlinepersona @programming.dev

    What are algebraic data types and why are they named as such?

    The wikipedia articles are terribly written (for math loves or people who just need to refresh their knowledge).

    What is a "sum" of types? What is a product of types? Is it possible to Cat x Dog or Cat + Dog? What does that even mean?

  • No Stupid Questions (Developer Edition) @programming.dev
    ludrol @bookwormstory.social

    How to get a git clone --branch into an existing repository?

    So I want to build blender fork but it fails to build on Visual Studio 2022. There is already a patch and a open PR that fixes the issue.

    I have already git cloned the repository and I would want to only get the patch into my local repository. So I can build from that.

  • No Stupid Questions (Developer Edition) @programming.dev
    alexdeathway @programming.dev

    Limitation of using drag and drop Images in GitHub readme. md?

    Limitation of using drag and drop Images in readme.md?

    One I am aware of is the size limit that no image size should be >10 MB. Are there any other limitations when using this (for example: retention period, storage capacity, etc)? I want to link those images outside Github.

    I am aware of uploading images to the repository and linking by

     undefined
        
    [image](./path/to/image/image.png)
    
      
  • No Stupid Questions (Developer Edition) @programming.dev
    ALostInquirer @lemm.ee

    How do people make patches for closed source software from outside its software company/devs?

    You see this with some apps (I think ReVanced is a popular example?) and games occasionally, and I've never been clear on how they do it.

  • No Stupid Questions (Developer Edition) @programming.dev
    andnekon @programming.dev

    Is it safe to move unallocated partition past Windows Recovery Image?

    Hello. I have Windows - Ubuntu dual boot and I'm trying to move space from Windows to Ubuntu. I've already freed space from the Windows side

    I'm pretty sure that I've read online that it can be dangerous to move the unallocated partition, because next boot to windows can corrupt my Ubuntu system. Is it true? Also, when I'm trying to move the unallocated partition, there's no option to "move/resize", so I swap them with the next following partition one by one. Is it the right way to do it?

  • No Stupid Questions (Developer Edition) @programming.dev
    TempestTiger @programming.dev

    How do you secure your home network/pc?

    So I'm a baby dev, still in Uni and they don't allow internships in 4th year due to some issues with it so not even that exp wise.

    I don't know enough, and I'm trying to learn but there's so much! My Uni degree doesn't cover security at all. Which is shit, bc I think I want to work in that? Mostly I'm just spooked and want to understand everything I can 'cause I love the internet and want to feel safer wandering about it.

    I'm scared of clicking on links. Even ones here, like there was a post about a book list earlier and I was just there like "Cmoon.... someone please have posted the lissssst."

    Would anyone be willing to share what they do for their own security? Especially if it's ridiculously over the top. Included reasonings and details would be adored!

    Also, if anyone has any books or references that might be good for learning sec from a programmatic view rather than a IT view I'd really love that! Anything at all.

    Regardless, hope anyone reading this has an absolutely wo

  • No Stupid Questions (Developer Edition) @programming.dev
    alexdeathway @programming.dev

    How to fix GitHub actions error?

    Can't locally download 41 GB loaded image which is provided to replicate GitHub action locally but don't want to commit and check every time too, is there any third option?

  • No Stupid Questions (Developer Edition) @programming.dev
    ALostInquirer @lemm.ee

    Do containers only work on their relevant OS (i.e. Linux distro/MacOS/Windows) + container engine?

    I think from what I've read that this is the case, but I've read some other info that's made it less clear to me.

    On the second part of the question regarding container engines, I'm pretty sure that may also be correct, and it kinda makes me wonder a little about risks of engine lock-in, but that may be a little out of scope.

  • No Stupid Questions (Developer Edition) @programming.dev
    Cyno @programming.dev

    Is preloading/caching data before the actual method call an (anti)pattern?

    cross-posted from: https://programming.dev/post/6513133

    Short explanation of the title: imagine you have a legacy mudball codebase in which most service methods are usually querying the database (through EF), modifying some data and then saving it in at the end of the method.

    This code is hard to debug, impossible to write unit tests for and generally performs badly because developers often make unoptimized or redundant db hits in these methods.

    What I've started doing is to often make all the data loads before the method call, put it in a generic cache class (it's mostly dictionaries internally), and then use that as a parameter or a member variable for the method - everything in the method then gets or saves the data to that cache, its not allowed to do db hits on its own anymore.

    I can now also unit test this code as long as I manually fill the cache with test data beforehand. I just need to make sure that i actually preload everything in advance (which is not al

  • No Stupid Questions (Developer Edition) @programming.dev
    I Cast Fist @programming.dev

    Instagram equivalent to Nitter or Invidious (tool to browse it)?

    What are some alternatives to browsing instagram "outside" of the proper app?

    I put nitter.net and invidious as examples, as they allow you to browse Twitter and Youtube "outside" the official site/app and without being tracked. Instagram hates me trying to look at anything from the computer.

  • No Stupid Questions (Developer Edition) @programming.dev
    hahattpro @lemmy.world

    Looking for TypingMind alternative. Prefer free and open-source solution.

    I need an open-source AI front-end (use with openai api key) with following option:

    • Do web search
    • Chat with document as context
    • More Plugin

    Please suggest me some open-source project that work.

  • No Stupid Questions (Developer Edition) @programming.dev
    hahattpro @lemmy.world

    How to start on freelancer while also keeping a full-time job ?

    I have 5 years experience as full time job.

    However I never do freelancer job before.

    How do I start on finding freelancer job ?