As was foretold, we've added advertisements to the forums! If you have questions, or if you encounter any bugs, please visit this thread: https://forums.penny-arcade.com/discussion/240191/forum-advertisement-faq-and-reports-thread/

[Programming] Thread: Fixed last bug in 5 month thread

1919294969799

Posts

  • bowenbowen How you doin'? Registered User regular
    Fuck those motherfuckers then.

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • urahonkyurahonky Registered User regular
    Nogs wrote: »
    if going with react, i would strongly suggest looking at flux to handle app state and data. ideally a framework like alt, fluxible or redux that has async isomorphic solutions already. trust me, you dont wanna be handling state purely through react. ideally you would have "stateless" components that just recieve new props from flux stores that hold state. i think this might be one of the issues @urahonky is having, but thats just speculation on my part.

    I'm just not sure how it's possible to have a stateless component if the user is actively interacting with it.

  • urahonkyurahonky Registered User regular
    Infidel wrote: »
    Not concerned very much about the React side of getting ramped up, I wanna figure out the stack asap though because the permanent dev hasn't been hired yet and I need to know what to look for there. :)

    Have been poking around at docs all last night and keep slicing things off until I reach something I like.

    React is a blast to use, personally. I used to be dead set against front-end development but I'm having more fun with React than I am with Python/Django.

  • NogsNogs Crap, crap, mega crap. Crap, crap, mega crap.Registered User regular
    urahonky wrote: »
    Nogs wrote: »
    if going with react, i would strongly suggest looking at flux to handle app state and data. ideally a framework like alt, fluxible or redux that has async isomorphic solutions already. trust me, you dont wanna be handling state purely through react. ideally you would have "stateless" components that just recieve new props from flux stores that hold state. i think this might be one of the issues @urahonky is having, but thats just speculation on my part.

    I'm just not sure how it's possible to have a stateless component if the user is actively interacting with it.

    by having state be handled by flux, using actions and the discpatcher to update flux stores which components listen to and recieve as props.

    rotate.jpg
    PARKER, YOU'RE FIRED! <-- My comic book podcast! Satan look here!
  • urahonkyurahonky Registered User regular
    Nogs wrote: »
    urahonky wrote: »
    Nogs wrote: »
    if going with react, i would strongly suggest looking at flux to handle app state and data. ideally a framework like alt, fluxible or redux that has async isomorphic solutions already. trust me, you dont wanna be handling state purely through react. ideally you would have "stateless" components that just recieve new props from flux stores that hold state. i think this might be one of the issues @urahonky is having, but thats just speculation on my part.

    I'm just not sure how it's possible to have a stateless component if the user is actively interacting with it.

    by having state be handled by flux, using actions and the discpatcher to update flux stores which components listen to and recieve as props.

    Yeah we started looking at reflux but I had to abandon it for now since I just didn't have the time to research and use it. :(

  • gavindelgavindel The reason all your software is brokenRegistered User regular
    I somehow managed to set up a unit test that takes 13 hours to complete.

    ...But it passes, so all good, right?

    Book - Royal road - Free! Seraphim === TTRPG - Wuxia - Free! Seln Alora
  • bowenbowen How you doin'? Registered User regular
    Holy fucking shit. What is that even?!

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • DelmainDelmain Registered User regular
    damn right I can

  • djmitchelladjmitchella Registered User regular
    There are two approaches to array indexing in programming languages:
    1. Those who start with an array index of 1, and
    1. Those who start with an array index of 0

    (via the ember slack channel, to give credit where it's due)

  • bowenbowen How you doin'? Registered User regular
    That took a few seconds. Funny though.

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • KakodaimonosKakodaimonos Code fondler Helping the 1% get richerRegistered User regular
    I have an old copy of Numerical Recipes in C where they have the unit offset array and vector handlers. So you don't have to worry about converting your old Fortran arrays to the new C style arrays that start at 0.

  • ecco the dolphinecco the dolphin Registered User regular
    Wow

    Frameworks are really really good nowadays.

    I was like "Urgh, need to add a new action to the controller, and tie it into the URL etc..."

    Turns out it was:
    1.) Add a public function to the controller class
    2.) PROFIT

    Well played, ASP.NET, well played.

    * Technically step 1b was also "register this action with the project's internal security/access framework", but the point still stands! =P

    Penny Arcade Developers at PADev.net.
  • ASimPersonASimPerson Cold... and hard.Registered User regular
    edited August 2015
    There are two approaches to array indexing in programming languages:
    1. Those who start with an array index of 1, and
    1. Those who start with an array index of 0

    (via the ember slack channel, to give credit where it's due)

    donald_knuth.png

    ASimPerson on
  • ecco the dolphinecco the dolphin Registered User regular
    Oh. So AngularJS automatically parses JSON results from $resource/$http, so that all you need to do is wait on its $promise.

    So damned convenient.

    Penny Arcade Developers at PADev.net.
  • DehumanizedDehumanized Registered User regular
    It's downright impressive how far along asp.net has come since they introduced asp mvc. Even working in webforms is almost pleasant now.

  • admanbadmanb unionize your workplace Seattle, WARegistered User regular
    I started doing web dev... just under 10 years ago now, and every time I pick up a new framework I'm amazed at how big an improvement it is over what I still think of as the status quo.

  • bowenbowen How you doin'? Registered User regular
    Welcome to the new world ecco.

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • urahonkyurahonky Registered User regular
    The word "errors" has officially lost all meaning to me.

  • bowenbowen How you doin'? Registered User regular
    Is there a software license that allows it to be public source, but limit it's use in commercial applications?

    IE, if I wanted to put some code in github but not really allow people to really take my shit and sell it to others? I don't care if someone uses it in their personal in house app or whatever.

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • zerzhulzerzhul Registered User, Moderator mod
    edited August 2015
    Could creative commons share-alike non-commercial work?

    http://creativecommons.org/licenses/by-nc-sa/4.0/

    edit: apparently it is suggested that CC licenses not be used for software, but they *could* be used for software.

    edit again: it seems like in the open source community, declaring non-commercial is frowned upon? I can't find any software-specific license that's in popular use that holds non-commercial.

    zerzhul on
  • urahonkyurahonky Registered User regular
    Sigh so if the other developer doesn't get portion of the code finished, pushed, and deployed by EOB tomorrow it looks like I'm going to have to start looking at doing it myself too.

  • bowenbowen How you doin'? Registered User regular
    edited August 2015
    zerzhul wrote: »
    Could creative commons share-alike non-commercial work?

    http://creativecommons.org/licenses/by-nc-sa/4.0/

    edit: apparently it is suggested that CC licenses not be used for software, but they *could* be used for software.

    edit again: it seems like in the open source community, declaring non-commercial is frowned upon? I can't find any software-specific license that's in popular use that holds non-commercial.

    Yeah, that was my finding too.

    That's why I'm using "public source."

    I just don't want someone to bundle my software with their own, or take my own and just sell it without royalties, like I said, I have no problem if someone wants to use it themselves, just have a problem with selling it.

    That's ultimately the big issue I have with FOSS, what I want isn't considered "open source" by definition.

    bowen on
    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • zeenyzeeny Registered User regular
    zerzhul wrote: »
    Could creative commons share-alike non-commercial work?

    http://creativecommons.org/licenses/by-nc-sa/4.0/

    edit: apparently it is suggested that CC licenses not be used for software, but they *could* be used for software.

    edit again: it seems like in the open source community, declaring non-commercial is frowned upon? I can't find any software-specific license that's in popular use that holds non-commercial.

    GPL is as non-commercial as it gets. Don't worry about it, if you release something under it odds are it won't be touched with a 10 feet pole.

  • bowenbowen How you doin'? Registered User regular
    GPL allows for people to package it up and sell it though, so long as they give the original source.

    I just don't like the idea that if I did decide to try and offer a service around it, that I'd have to compete with myself being sold by someone else.

    But, like I said, I'm okay with some guy or some company taking it and using it internally and never doing anything else with it.

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • RendRend Registered User regular
    bowen wrote: »
    GPL allows for people to package it up and sell it though, so long as they give the original source.

    I just don't like the idea that if I did decide to try and offer a service around it, that I'd have to compete with myself being sold by someone else.

    But, like I said, I'm okay with some guy or some company taking it and using it internally and never doing anything else with it.

    iirc, if you include something which is released under the GPL license, any code which incorporates it must ALSO be released under the GPL license. It's not impossible to get around, but if a company improperly uses GPL code, they could jeopardize every proprietary line of code in their whole code base, which is why on the whole, corporations don't touch it unless absolutely necessary.

    Again though, IIRC. I could be thinking of a different license, but I'm pretty sure at my company's open source training, the takeaway was "apache license is good, GPL license is unusable."

  • bowenbowen How you doin'? Registered User regular
    edited August 2015
    Rend wrote: »
    bowen wrote: »
    GPL allows for people to package it up and sell it though, so long as they give the original source.

    I just don't like the idea that if I did decide to try and offer a service around it, that I'd have to compete with myself being sold by someone else.

    But, like I said, I'm okay with some guy or some company taking it and using it internally and never doing anything else with it.

    iirc, if you include something which is released under the GPL license, any code which incorporates it must ALSO be released under the GPL license. It's not impossible to get around, but if a company improperly uses GPL code, they could jeopardize every proprietary line of code in their whole code base, which is why on the whole, corporations don't touch it unless absolutely necessary.

    Again though, IIRC. I could be thinking of a different license, but I'm pretty sure at my company's open source training, the takeaway was "apache license is good, GPL license is unusable."

    You're right, GPL is mostly copyleft.

    Still doesn't stop someone from taking "GPL Webserver FOSS" and selling it as "Bowen's Awesome Webserver" for $20 or selling a service based on installing it on people's computers.

    That's the kind of shit I want to stop.

    I think the CC BY-NC-SA is the one I'm looking for. Seems to fit exactly what I want it to do. I get the copyleft that GPL has, so improvements or changes could be incorporated back into the main source, and I "stop" people from using for a commercial stuff, and, potentially competing with me.

    I'm okay with not making a sale, I understand some people will download and work out how to use it on their own. I hate it when people take my stuff and take credit and make money off it though.

    bowen on
    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • djmitchelladjmitchella Registered User regular
    Rend wrote: »
    Again though, IIRC. I could be thinking of a different license, but I'm pretty sure at my company's open source training, the takeaway was "apache license is good, GPL license is unusable."

    That's how we do things here; BSD/MIT/etc is ideal, LGPL is possibly okay, but you have to be very sure you need that functionality enough to jump through the hoops to keep things legal; GPL = no way, no how.

  • bowenbowen How you doin'? Registered User regular
    @zerzhul thanks btw

    not a doctor, not a lawyer, examples I use may not be fully researched so don't take out of context plz, don't @ me
  • ecco the dolphinecco the dolphin Registered User regular
    admanb wrote: »
    I started doing web dev... just under 10 years ago now, and every time I pick up a new framework I'm amazed at how big an improvement it is over what I still think of as the status quo.

    It's like the frameworks want you to focus on the data that's being moved around, instead of ancillary details like resource management. :p
    urahonky wrote: »
    The word "errors" has officially lost all meaning to me.

    Was this because you repeated it 40 times really quickly?

    errorerrorerroreroerrooeroerororoeoreooorooooerrrrrerooooreoo

    Penny Arcade Developers at PADev.net.
  • NogsNogs Crap, crap, mega crap. Crap, crap, mega crap.Registered User regular
  • urahonkyurahonky Registered User regular
    Bookmarked, thanks @Nogs and yes @ecco the dolphin it's because I type stuff like "this.state.errors = errors;" about a hundreds times and always type "errrors" and "erorr". Ugh!

  • gavindelgavindel The reason all your software is brokenRegistered User regular
    Year end review was today. As I have been at my company only a month, my demands were a reasonable 30% bonus and a pony. Sadly, I was forced to settle for a second hand yacht. What is tech coming to these days?

    Book - Royal road - Free! Seraphim === TTRPG - Wuxia - Free! Seln Alora
  • crimsoncoyotecrimsoncoyote Registered User regular
    Oooh, we're doing a hackathon for a couple days next week at work. Looks like I get to dive into some angular

  • djmitchelladjmitchella Registered User regular
    ow, the "Build Log" page is making me sad

    Hm. How big _are_ the logs?
    teamcity wrote:
    u9sg4vydoyq7.png
    alright, I'll let you have this one.

    2,034,282 lines. Looking in there, an awful lot of it seems to be preprocessor warnings about boost headers, which are a:verbose, and b:seem to happen for every source file in some of the projects. (fake edit: I asked the guys on those projects, and they said "yeah, we looked into them, we've confirmed they're harmless, but they would be time-consuming to fix and management does not think build log size is a priority compared to new features / customer-facing bugfixes". Which is fair enough, I guess)

  • EtheaEthea Registered User regular
    ow, the "Build Log" page is making me sad

    Hm. How big _are_ the logs?
    teamcity wrote:
    u9sg4vydoyq7.png
    alright, I'll let you have this one.

    2,034,282 lines. Looking in there, an awful lot of it seems to be preprocessor warnings about boost headers, which are a:verbose, and b:seem to happen for every source file in some of the projects. (fake edit: I asked the guys on those projects, and they said "yeah, we looked into them, we've confirmed they're harmless, but they would be time-consuming to fix and management does not think build log size is a priority compared to new features / customer-facing bugfixes". Which is fair enough, I guess)

    Make boost be included as a system path and watch 90% of those go away

  • SeolSeol Registered User regular
    (fake edit: I asked the guys on those projects, and they said "yeah, we looked into them, we've confirmed they're harmless, but they would be time-consuming to fix and management does not think build log size is a priority compared to new features / customer-facing bugfixes". Which is fair enough, I guess)
    Which is fine until there's something new in the build log which isn't harmless, and you never spot because it's on line 1,300,000 of 2,000,000.

    I guess you could write a test that says every line in the log matches one of these patterns that we have decided are acceptable, if you need to protect against that...

  • SaerisSaeris Borb Enthusiast flapflapflapflapRegistered User regular
    Nogs wrote: »

    I haven't actually used Flux, but from reading examples of it, I always got the impression that the pattern has too much implementation overhead (the boilerplate mentioned in the first link) to scale to large apps. So it's appealing to see something like this that apparently understands the issue and seeks to solve it.

    I'm getting closer and closer to the conclusion that pure functions are the only sane way to do UI.

    borb_sig.png
  • InfidelInfidel Heretic Registered User regular
    So I had to fork and patch up formsy-react today to get it working with react 0.14 and ES6 class style.

    On the upside, I'm learning React really quick.

    OrokosPA.png
  • ecco the dolphinecco the dolphin Registered User regular
    I just learned about directives in AngularJS.

    I'm like

    "How did <div some-example-here></div> render into this really neat UI? FROM WHAT DARK MAGICK DID IT COME?"

    and directives are that answer.

    Penny Arcade Developers at PADev.net.
This discussion has been closed.