Django mystery

so l am a computer engineering student who can build a basic application like accommodation app l always think a good programmer writes code from scratch l am learning Django it is about 2 years l just feel like l dont know anything even the python language i have been using for 3 years l usually do it when its urgent and l use gemini a lot to generate codes for my django application is it recommended? I have been putting a lot of effort but l m feeling like its not working is it my approach that is bad or l have to explore other ways like learning another framework maybe python is not stickng into my head or maybe l already know but l m thinking l could be better because in django l know creating models, creating forms rendering htmls urls, admin accounts and everything like that whats your recommendation l want to be best. I want to progress please l want someone who is willing to mentor me. I really want to be proficient and what amount of time should l put in my work.

if you use stuff like gemini or chatgpt “a lot”, no offence but … no wonder.

I don’t really know what to say about that apart from “beware generative AI hallucinations”. GAI can be a useful tool to get a snippet or two… but it will never replace putting in the long hours spent thinking about something.

Anyway, my 2 cents…

also, wall of text :slight_smile:

Okay thanks.May l ask how can l be better. Do y’all write code from scratch building a complex app or?

No one ever writes 100% from scratch. I think.
We are all guilty of copy and pasting stuff around. I think.

It’s strictly personal so to each their own. I have no idea how you are wired, what works with you, what doesn’t etc.

For example, the principle of reusability manifests itself along a large spectrum, going from risky/dangerous to clever:
. risky: mindless copy/paste
. clever: refactoring, but within reason, i.e., think about what you are doing and why. Does it make sense? How much time/brain power am I going to save by doing this? etc, etc.
. in between: what most of us probably do quite often.

There is no universal recipe. Do you enjoy what you do? Does it bring you a sense of accomplishement? Happiness? Does it allow you to make a living? A good one? What is a good living? Does it allow you to look into your own future and see good outcomes?

I’ll stop here. I knew that cookie had the taste of peyote :grin:

1 Like

Ooh okay thanks for that. Maybe l am giving myself a lot of pressure.

Just to add to @plopidou 's excellent responses, I’d like to comment on a couple of things.

First, make sure you select reliable sources for learning. Look at a reputable resource such as the “Education” section of the Awesome Django page to find material from which to learn. Don’t just randomly perform a Google search to find videos - there’s a lot of sub-standard information out there that will either simply be out-of-date, incorrect, or lead you in the wrong direction.

You’ll be a lot better off spending more time learning the right things, than quickly learning the wrong things.

And then -

This can be extremely dangerous, especially if you don’t understand the implications of the code being recommended. Anything being produced by an untrusted source needs to be examined carefully - and there are no generative AI solutions that I would trust.

I have now personally seen two situations where an AI-generated solution was not just wrong, but bad. In one case, a solution was generated to solve a coding issue related to a security mechanism, and the provided solution was to effectively disable the security. The other produced a mathematical formula that looked right, but produced incorrect (and invalid) results.

So, I’d say they’re ok as a starting point - something like that might be helpful in laying out a general pattern or an idea of an implementation. But if you don’t understand what the code is doing - or what effects it may have on the rest of your system, then I wouldn’t use it.

1 Like

Luke Skywalker: Is the dark side stronger?

Master Yoda: No, no. Quicker, easier, more seductive.

Well understood. Thank you for such an insightful responses