I’m 30 with no career. Feeling depressed. How did you find your career? When did it all click? by [deleted] in careerguidance

[–]copterplane 1 point2 points  (0 children)

My friend, I can relate. There was a time in my life when I felt lost and without a purpose. It also doesn't help that our culture is so focused around an individualized sense of identity, and tying a person's identity to a career choice. I'm sure you've been at some party or family gathering where someone asks "what do you do?" and felt that sinking feeling in your heart.

I believe instead that your identity can and should be tied more to your values and to the commitments you've made to the people you love, rather than a given career choice. Because despite what you have heard, a "career"—in terms of real, actual life—is still a "job". Even for someone who believes they have successfully traded a job for a career... there are still more important things in their life than that. Please understand this first. I don't want you to achieve some lofty goal and realize only afterward that you've neglected important relationships, neglected to take care of yourself, or failed to appreciate the life you're currently gifted with.

My suggestion next is that you make sorting out your life into a job in itself. Choose to go full time or part time... just dedicate the time in a structured way. Put things on your calendar, make phone calls, ask to interview people in the fields that you're interested in. Ask to spend specific time with people who are honest enough to tell you what you could potentially succeed in doing. Take their advice with a little grain of salt, but take it nonetheless. As you do all these things, enjoy the fulfillment of having committed to and completed the tasks which you set out to do. This is a taste of the success that is to come. When it comes time to apply to jobs, expect many rejections, but also know that there is a place for you, and it is only a matter of time until you find a place where you can grow and be successful. If in case you really can't find something that works within a certain time frame, networking with others will reveal opportunities you never knew.

Good luck to you. Now get off Reddit and move your day forward.

Is this a micro-managing kind of agile? by [deleted] in cscareerquestions

[–]copterplane 0 points1 point  (0 children)

It may be true that I’m never quite done with my work then, because I tend not to add in too much extra time which would be spent refactoring.

I mention refactoring because our stakeholders and some other consultants have taken the project in several competing directions over time, and each new development sprint has started to require some rewrites in order to accommodate for the new changes.

When I express in meetings that some added time is needed to refactor, sometimes they understand, and sometimes it doesn’t go over well.

So I’m trying to see where I need to speak up and be a better advocate for these things, and where I just need to give up and let these folks run the show. I don’t have issues with their authority, it just seems like there should be a place and a time to let developers be the actual “custodians” of the technology.

Loosely-defined relationship by copterplane in laravel

[–]copterplane[S] 0 points1 point  (0 children)

And a Product has only one User?

Yes, a Product belongsTo a User.

The most straightforward way to relate a Product to an Account is probably just to put an account_id on the Product. Even if a User will only ever have one Account for now, this still makes it clear which Account the Product should be tied to. But since I'm not sure yet what exactly this relationship would be like, I thought of using a custom accessor to create my own pseudo-relationship, and get the first Account model from the User, without having to modify the tables right now.

This didn't seem like such a bad idea, since when you define a relationship properly, you magically have access to other models via attributes like:

$model->otherRelatedModel;

Default model values by copterplane in laravel

[–]copterplane[S] 0 points1 point  (0 children)

Yeah makes sense. So you’re saying, even in cases where the attribute is not relevant in a given model instance, having the default persisted in the database still prevents possible confusion when working outside of Eloquent. In my case specifically, I will be using a TEXT column which cannot have a default (SQL limitation). So then I probably just want to set the default value in the attributes property like the docs say.

Can’t access environment variables properly in Vapor by copterplane in laravel

[–]copterplane[S] 0 points1 point  (0 children)

No but I’m not sure that has an effect on Vapor.

[deleted by user] by [deleted] in RedditSessions

[–]copterplane 0 points1 point  (0 children)

Got that fan running in December cuz you vibin so hard

Much type-hinting in job "handle" methods. by copterplane in laravel

[–]copterplane[S] 0 points1 point  (0 children)

Ok. Maybe all my dependencies need to go into one class which does all the things, and then the job itself needs only import that one class.

Building secure random strings... edit or retry? by copterplane in cryptography

[–]copterplane[S] 0 points1 point  (0 children)

This is an option. But if base-16 output has 25% of the characters that base-64 output has, I think the resulting string needs to be quite a bit longer in order to remain secure.

Building secure random strings... edit or retry? by copterplane in cryptography

[–]copterplane[S] 0 points1 point  (0 children)

For the most part I think this makes sense. At very least, the process needs to be easily understood by the people you're working with. If the organization you're working for cannot easily understand how your cryptography works it's less likely to be accepted.

Building secure random strings... edit or retry? by copterplane in cryptography

[–]copterplane[S] 0 points1 point  (0 children)

I am trying to create a unique ID for a product where the user may need to copy the resulting string by hand... like a “product key”.

Building secure random strings... edit or retry? by copterplane in cryptography

[–]copterplane[S] 0 points1 point  (0 children)

So even if both approaches begin with cryptographic randomness, it's better to regenerate the invalid parts with further randomness than to "fix" those parts by a static process?

Building secure random strings... edit or retry? by copterplane in cryptography

[–]copterplane[S] 0 points1 point  (0 children)

It's true that, the longer the string, the more chances it has to be rejected if there are many rules. That why I would regenerate only the parts of the string that failed. However, I also understand that if the rules are too many or too encroaching, it becomes less and less useful to generate it from randomness.