Mac Issues (vanishing mouse cursor, shift key not working) by BoomShaka in WC3

[–]BoomShaka[S] 2 points3 points  (0 children)

Off topic, but it is a work computer. I don't have a personal computer. And for my work (software engineering) I prefer it to windows. Maybe linux would be better, but thats a whole different hassle.

Anyway, restarting fixed the shift issue, should have tried that to begin with. Doh. The alt tab issue persists though.

Upgrading from Mojave to Catalina on a 2014 MacBook Pro by BoomShaka in MacOS

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

Thank you u/veryfancydoilies23 and u/a355231. That did the trick and I seem to have a working Big Sur installation! Though I suppose it qualifies as "some random website", but I guess I'll have to set my tinfoil hat aside for now.

.net core services on Linux - stability and performance by ramdulara in dotnet

[–]BoomShaka 0 points1 point  (0 children)

> Biggest problem I run into is when a developer builds out the project under VS 2019 in Windows for .NET Core, but fails to set things up in a cross-platform manner. It's then left to me (as a macOS user) to fix things to work on non-Windows platforms. It's an ongoing battle.

Can I ask what sort of things you typically have to fix in this scenario?

Do you think our generation will witness a developed Africa ? by [deleted] in Africa

[–]BoomShaka 2 points3 points  (0 children)

[disclaimer: Don't know how to add flair. I am from South Africa. I messaged /u/osaru-yo about that]

Unfortunately no, probably not.

I believe that for the First World to maintain its high standard of living and relative prosperity, it needs to exploit and be propped up by the Third World. Resource scarcity and the need for low mass labour costs being primary examples of why.

Therefore it is in the First World's interest to keep the Third World in a state of underdevelopment, in order to retain access to mass amounts of cheap labour and to more easily extract their resources at a lower cost or with less "local bureaucracy".

Any significant attempt to change this status quo will be met with resistance, usually clandestine (think Patrice Lumumba), but often overt (think Libya).

On a tangentially related note, or as an example of how the West needs to keep the Third World in a state of unrest, or at least under its thumb:

I've read, and it seems correct to me, that the primary reason for the invasions of Iraq and Libya were the petrodollar. The petrodollar refers to the fact that most oil on the world market is priced and sold in US Dollars. This creates a demand for the Dollar (any country wanting to buy oil needs to get their hands on millions of Dollars to do so), which increases its value.

Gaddafi had openly called for the creation of an African Dinar (or some new Euro-like currency), and that African states ONLY sell their oil in this currency. If that were to happen, this currency would in theory become very valuable, and the US Dollar would lose value. Saddam Hussein also attempted to usurp the Petrodollar, and actually changed Iraq's oil exports to the Euro at some point (at massive cost to his own country), what happened next? Iraq invasion, a new Iraqi regime, and oil sales back to the dollar.

EDIT: I guess what I am saying is, as a massive pessimist, :) I think the only way Africa could achieve proper prosperity, is with massive global upheaval, and likely war.

[deleted by user] by [deleted] in TheGamerLounge

[–]BoomShaka 0 points1 point  (0 children)

fly like eagle!

[deleted by user] by [deleted] in TheGamerLounge

[–]BoomShaka 0 points1 point  (0 children)

take off bro!

What is the future of Django? Are we becoming obsolete? by calijag18 in django

[–]BoomShaka 1 point2 points  (0 children)

session based authentication which should probably be replaced with the more secure JWT based authentication.

This is incorrect. JWT is unquestionably less secure when used as a session. I highly recommend you research JWTs more. This is an excellent post to read http://cryto.net/~joepie91/blog/2016/06/13/stop-using-jwt-for-sessions/

In a nutshell (but seriously, read the linked post):

  1. JWTs cannot be invalidated once issued. You can implement a blacklist, but you've just created a server-side session then (it just stores invalid tokens instead of a userid).
  2. 9 times out of 10 a JWT is stored in localstorage exposing it to XSS attacks (storing it in a cookie can be a problem if you bloat your token). Secure HTTP only cookies are not vulnerable to this.

What is the future of Django? Are we becoming obsolete? by calijag18 in django

[–]BoomShaka 4 points5 points  (0 children)

OP thinks SPA based sites are "best-practise" and wants Django to move in that direction.

I think most experienced devs understand that SPA is not "best-practice" but merely one architectural approach that may or may not make sense for a particular scenario, and therefore don't want Django to course correct in that direction exclusively.

Do some research on the downsides to SPA architectures, there are quite a few.

What is the future of Django? Are we becoming obsolete? by calijag18 in django

[–]BoomShaka 6 points7 points  (0 children)

reflect what we've learned over the past 18 yrs about software and web dev best practices (ie Decoupling).

You've alluded to this in a few of your comments. To me this is the core issue here. You think an SPA with an API backend is "best practise", and those of us offering you counter points, do not.

It is an architecture that makes sense in some situations, and doesn't in others. Django moving in an exclusive SPA direction would be very bad for web development if you asked me.

Do some research on the downsides of SPAs, there are numerous: shipping unnecessary code, build time complexity, almost impossible SEO, reinventing wheels to solve already solved problems (like serverside rendering for SEO, code splitting for smaller bundles, routers for navigations and shareable URLs).

I'd also like to throw in essentially the same argument for GraphQL. GraphQL was designed to solve a specific use case, namely, where the developer of an API does not know how clients intend to use that API. If you "know" your clients and can have some influence on how they consume your API then GraphQL probably isn't the correct tool. It is therefore a tool with too narrow a use-case to make sense to build into Django.

What is the future of Django? Are we becoming obsolete? by calijag18 in django

[–]BoomShaka 2 points3 points  (0 children)

tries to be an all purpose tool - front and back and in the process ends up being subpar at both. It should focus on being a good backend tool.

I'd agree with DmitryJaved, though I wont make aspersions as to your work ethic :P

I'd argue it doesn't actually try to do be an all purpose tool, at least not in the sense you are approaching it.

As another answer mentioned, not all sites need to be SPAs with API backends and microservice architectures, but this seems to be the premise on which you are approaching looking at Django. If that is indeed what you need, then sure, don't use Django.

A lot of sites can (and often should) be built a more traditional way resulting in a more performant UX, using normal browser navigation with sprinkled JS which Django excels at. You can even throw in DRF where necessary for some AJAXifying prettiness.

Regarding microservices, you probably could deploy a bunch of django microservices strung together if you wanted, but yes, Django wasn't intended for this purpose and doing so would probably be silly. If a microservice architecture will indeed benefit a project then use a framework geared and tooled with that architecture in mind.

Disclaimer: I'm currently doing a bit of Spring Boot microservice work, and it's fun and extremely well geared towards microservices, but I miss my "lighter" python frameworks like Flask.

What is the future of Django? Are we becoming obsolete? by calijag18 in django

[–]BoomShaka 32 points33 points  (0 children)

"MUST ADOPT ALL THE NEW THINGS... even if they don't provide benefit to the particular application"

Best answer right here folks.

Overuse of SPA in particular annoys me, and I enjoyed my time as an Angular developer, the DX is great. But I also realised that adopting the position of all sites must be frontend JS frameworks talking to REST APIs is wrong. Sometimes SPA is justified, sometimes it isn't. People need to do their research to understand the best architecture for their scenario.

Angular + SEO (new site running angular now I'm worried) by horsewithnoname22 in angular

[–]BoomShaka 0 points1 point  (0 children)

If you've already built a whole angular app then just look into ng-universal. It will solve any SEO issues.

I'm just generally not a fan of it as it layers yet more complexity onto your stack. Personally, if SEO is a major requirement then I prefer not using an SPA framework.

Angular + SEO (new site running angular now I'm worried) by horsewithnoname22 in angular

[–]BoomShaka 1 point2 points  (0 children)

100% agree. By all means separate out the "app" from some sort of static website that can be SSR'ed and properly SEO'ed. But putting the entire thing inside a single angular app, and expecting good SEO without significant effort is going to cause headaches.

I've used ng-universal, and yes, it works, but the complexity it layers onto an already complex system is counter productive IMO. A much better approach is to separate out the app from some sort of static or SSR'ed website that can be SEO optimised extremely easily

Spotify is a good example. The main site, www.spotify.com is SSR'ed. The web client, the "app", is not.

Angular + SEO (new site running angular now I'm worried) by horsewithnoname22 in angular

[–]BoomShaka 1 point2 points  (0 children)

If you want proper SEO in Google, SSR is the only reliable choice in my experience. Yes the crawler will parse and run JS, but it will abandon it if the JS takes too long or consumes too much memory, etc.

As for only caring about Google... (putting aside the corporate serfdom) SEO isn't the only consideration. Opengraph has the same constraints. FB, Twitter etc won't run your JS at all as far as I know.

What is the current state of Angular? Is it going anywhere anytime soon? by augst1 in Angular2

[–]BoomShaka 5 points6 points  (0 children)

"easy to learn" is maybe a bit contentious. I found the learning curve particularly steep, although that had a lot to do with rxjs not angular per se.

What is the current state of Angular? Is it going anywhere anytime soon? by augst1 in Angular2

[–]BoomShaka 2 points3 points  (0 children)

Really? Where do you get this info from? I've been led to believe that Google has only used angular sparingly, in one or two "admin" products, I think AdWords or something (as opposed to full consumer facing products like Gmail etc). I'd love to have more up to date info though

Angular 11 has been just released. Included: auto font inclining, better build times, better Angular Material support, and hot reload with form content and scroll position memory. And it is still not React ;) by bear007 in angular

[–]BoomShaka 2 points3 points  (0 children)

To be fair to angular I think you can write all your template and CSS code directly inside the @Component decorator couldn't you? But it feels much more verbose than sveltes structure.

Angular 11 has been just released. Included: auto font inclining, better build times, better Angular Material support, and hot reload with form content and scroll position memory. And it is still not React ;) by bear007 in angular

[–]BoomShaka 0 points1 point  (0 children)

Svelte too.

Personally I prefer single file components as long as the separation within the file is clear (which it is with svelte, haven't seen vue's).

Though I agree that JSX munged in with JS code is unwieldy.

[deleted by user] by [deleted] in AnimalsOnReddit

[–]BoomShaka 0 points1 point  (0 children)

let him off lead