|
NFX posted:Or the more exotic ones. I ran into this thing a few days ago at work: But I de-indented the else if statement so it'll go with the first if statement right? (although that is actually how it works in Python)
|
# ¿ Jul 17, 2013 00:30 |
|
|
# ¿ May 17, 2024 14:48 |
|
Wardende posted:That's fine because it means that a hacker would have to physically be at the machine which hosts the database to hack it. *takes a monster glue huff* wooooooooooooooooooooooooooooooh. Anyway, we use keycards, so we're covered. But then there's no reason to not have a password, right? So you may as well have one in case, heaven forbid, a hacker gets to the physical machine and has someone's keycard + pin?
|
# ¿ Jul 20, 2013 05:48 |
|
Wardende posted:Or downloads the database onto their local machine Nah don't worry guys, it's cool, we'll just put up some signs around the office saying "DO NOT STEAL OUR DATABASE" and we'll be covered
|
# ¿ Jul 20, 2013 20:34 |
|
seiken posted:I have a Python codebase where almost every class has a method like that except it's called either "SetUpX" or "SetupX" completely at random. It's even worse when you have something like this in MATLAB, where each function belongs to one file of the same name, and fixing all of the lovely discrepancies becomes a huge pain (on a Windows system with no scripting languages installed -- just having something like Python or even cygwin would have made it okay, but nooooooooo).
|
# ¿ Jul 25, 2013 19:36 |
|
Thermopyle posted:What kind of heathen doesn't have green comments? What kind of poo poo class requires physical printouts of code for homework submission? Classes in the early 90s, perhaps
|
# ¿ Jul 26, 2013 04:18 |
|
Thermopyle posted:Bleh, the whole attitude that makes people resistant to libraries sucks. Use a goddamn library, losers. In some lines of work, this can actually be problematic. If you're on an isolated network where installing a new library may be a 3 month process (for example, some government systems), and you just need one function out of that library, it can be easier to just code the function yourself and be done with it. If you have a library or easy access to a library, then you may as well just use it instead of reinventing the wheel over and over. This was the philosophy behind MIT's change from Scheme to PYthon in their intro programming course. Of course, if getting that library into your build process is actually a week-long project, then it may be better to reinvent the wheel.
|
# ¿ Aug 15, 2013 19:43 |
|
We're setting up a data processing system that will takes files on a NAS, make copies of them, do some basic processing on their contents, and then push a result into a database. The software engineer wants to write this system in Python. The program manager (who is sort of a software programmer who eventually clawed his way into management) is forcing him to use MATLAB
|
# ¿ Aug 17, 2013 19:33 |
|
EntranceJew posted:Can't somebody veto this terrible thing before it happens? Surely if you yell loudly enough at the right people you should be able to scare someone into putting a little more critical thought into it. Not happening; the project manager is actually from an outside company, they're a customer for the product. Ultimately they're purchasing whatever they tell us to make even if we recommend something else
|
# ¿ Aug 18, 2013 05:11 |
|
Plorkyeran posted:The only reason most things on Windows support spaces in paths is because Microsoft forced the issue by putting spaces in the name of a bunch of standard directories. A typical Linux install has zero directories with spaces in their names, so no one notices when they fail to properly quote paths. That's not a good excuse, especially for such a mainstream project like mingw
|
# ¿ Aug 24, 2013 07:46 |
|
ToxicFrog posted:Mingw consists mostly of windows ports of GNU utilities that they are not the maintainers for. So the excuse is more like "we don't have time to go through every one of the programs to find out exactly which ones can't be arsed to quote $0 properly and then convince upstream to fix them", which I think is perfectly reasonable. Instead of saying "we don't support spaces" it would be better to support spaces and then say "we support spaces, but other projects might not support spaces, in which case it's not our fault if your poo poo breaks". QuarkJets fucked around with this message at 03:08 on Aug 25, 2013 |
# ¿ Aug 25, 2013 03:06 |
|
Plorkyeran posted:I think you do not understand what mingw is or something. Maybe, I only use mingw for cross compiling Linux projects into Windows environments
|
# ¿ Aug 25, 2013 20:46 |
|
sklnd posted:The entropy reduction from alpha-numeric to strictly numeric characters is pretty upsetting, and the maximum password length is something like 12 characters. Good job, guys. Vanguard's maximum password length is ten My minimum password length at work is 22 characters. My password is a loving sentence, and I mostly write open source software (science stuff)
|
# ¿ Aug 30, 2013 05:46 |
|
evensevenone posted:Yeah, you don't want to end up like MATLAB where naming a variable "quit" means you can't close the IDE. MATLAB is a coding horror
|
# ¿ Sep 9, 2013 04:58 |
|
Innocent Bystander posted:MATLAB is the siren song of the scientific community. No; any language that can't even do basic arithmetic with 64-bit integers is not a real scientific language. gently caress MATLAB. People need to stop using this piece of garbage. MATLAB is the PHP of science and engineering; it just barely works once you figure out several dozen workarounds to make it do what you want it to do QuarkJets fucked around with this message at 12:20 on Sep 10, 2013 |
# ¿ Sep 10, 2013 12:18 |
|
quiggy posted:Unfortunately I don't know of any better alternatives except maybe R. I'd be more than happy to learn about others, though. Python, R, Octave, and a dozen others. Python combines the interactivity of MATLAB with the power of a real programming language and is generally a pleasure to use. R is pretty great, too. Most importantly, both accomplish the same tasks in less time and with less code written. Octave is basically MATLAB lite and isn't that good MATLAB needs to die, I don't know what the gently caress Mathworks does with all of their licensing money but it's definitely not "release good math/science software"
|
# ¿ Sep 10, 2013 18:51 |
|
quiggy posted:Ha ha ha ha Python as a Matlab replacement ha ha ha ha You're right, Python does it much better
|
# ¿ Sep 10, 2013 21:20 |
|
quiggy posted:I didn't know about scipy/numpy They're based on the same Fortran libraries as MATLAB, so it's remarkable how easy it is to switch from one system to the other. Python is row major whereas MATLAB is column major, but fundamentally they have the same capabilities. Python has advantages in that it's a well-designed language first and a scientific tool second. MATLAB is still great if you're just prototyping something small and already have a license and already know how to use it, but it's a dinosaur.
|
# ¿ Sep 10, 2013 22:30 |
|
Strong Sauce posted:Look at Julia http://julialang.org This looks interesting and easy to use. And those benchmarks are outstanding. How's the library support? If I need to use a bunch of one-liner Python/MATLAB functions, will Julia code be similar or will I probably have to roll my own for a lot of the less common features? e: I answered my own question by discovering that Julia can call Python and has a lot of cross-compatibility, so anything that Python has Julia also has. http://conference.scipy.org/scipy2013/presentation_detail.php?id=203 Julia with Python libraries for whatever Julia might not have yet sounds like an interesting combination, especially for those of us who must use some looping (such as when your data array would normally exceed your memory capacity) QuarkJets fucked around with this message at 21:19 on Sep 12, 2013 |
# ¿ Sep 12, 2013 21:04 |
|
Harvey Mudd is a pretty good engineering school, but they're small, so most people haven't heard of them
|
# ¿ Sep 13, 2013 06:35 |
|
SurgicalOntologist posted:E: yes, yes, Matlab is the real horror, I know. This can't be said often enough
|
# ¿ Oct 1, 2013 08:22 |
|
Java can be good, but for whatever reason a greater percentage of the good software than I see is written in Python and C++, whereas when I see a Java app it tends to suck. Java is easy enough for a novice to use, but it's not as easy and intuitive as Python, so you end up with a bunch of coding abominations written by "Java programmers" who just wanted to make Minecraft mods or whatever. The same novice in a Python environment would be able to get by and probably produce something that's pretty good with minimal effort because there's almost no learning curve by comparison. The same novice in a C++ environment will probably just give up before releasing anything.
|
# ¿ Oct 2, 2013 09:51 |
|
Soricidus posted:I seriously use Java to write client software today. Distributing Python and Java are pretty similar in that both require some sort of runtime environment. I don't see how it's reasonable to expect a user to have access to a JRE but not expect them to have access to a Python interpreter Or as Pollyanna said, if you're worried about it then create a binary
|
# ¿ Oct 3, 2013 05:40 |
|
I was able to successfully name an internal python project PIRATE. Everyone loved it and still does
|
# ¿ Dec 13, 2013 08:31 |
|
Seriously though, Java is rife with bullshit design choices and both is a coding horror and produces the greatest number of coding horrors. gently caress Java e: I take that back, MATLAB is worse
|
# ¿ Dec 16, 2013 06:02 |
|
Sagacity posted:Please, go on. Can you give a few examples of the extreme ideology? I think he's specifically referring to "EVERYTHING IS A CLASS, NO EXCEPTIONS" as extreme ideology
|
# ¿ Dec 16, 2013 19:26 |
|
I, too, did not base my "gently caress Java" statement on a hello world example. Java has plenty of important things to be concerned about without using "ease of writing hello world apps" as a metric
|
# ¿ Dec 17, 2013 00:12 |
|
tef posted:Yep, python has really strong typing Yeah, there's simply no way that True could be inheriting from int, seeing as how no language has ever allowed True and False to represent 1 and 0 QuarkJets fucked around with this message at 08:46 on Dec 17, 2013 |
# ¿ Dec 17, 2013 08:42 |
|
het posted:Well he wasn't necessarily saying it was absurd on the whole, just that it didn't represent what you would call strong typing. Also, coercing 1/0 to true/false seems more reasonable than the converse to me. I think that having False and True be represented by integers has become so ingrained in so many languages that if it suddenly wasn't the case then people would just be making GBS threads on Python for that instead, even though it's largely irrelevant trivia at this point e: Although I guess in Java false and true aren't representable by integers, so there's that QuarkJets fucked around with this message at 09:25 on Dec 17, 2013 |
# ¿ Dec 17, 2013 09:22 |
|
PleasingFungus posted:See, this kind of poo poo is why mathematicians write the worst code. If knowing how to use a Kronecker delta means that you write the worst code then I guess all scientists and engineers write the worst code (I'm not disagreeing) Deus Rex posted:I'm not sure exactly who or what you're replying to, but this compiles just fine in C++ and as C (with appropriate typedefs added to the structs). He's replying to the weak vs strong typing discussion by providing a great example of weak typing and suggesting that any language that can't do the same is not weakly typed. He's not saying that it's bad code or that it won't compile
|
# ¿ Dec 18, 2013 06:48 |
|
Yes, you can do weird-looking things when bool inherits from int. I don't see a problem with this; it's a feature that preserves an old convention of using integers to represent true/false, and if you're intentionally using bool's int features and screw them up then that's on you (just like every other feature in every other language)
|
# ¿ Dec 19, 2013 20:47 |
|
Dren posted:A list of examples of operators behaving in incongruous ways depending on their arguments is php-like. That's because you don't actually understand what 'and' does: Python.org posted:x and y: if x is false, then x, else y (2)
|
# ¿ Dec 20, 2013 09:55 |
|
ninjeff posted:the only logical date format is none at all because calendars and absolute time are puny human inventions It's too bad that most of us work for humans
|
# ¿ Dec 22, 2013 19:39 |
|
I still don't really understand git but even I regularly make commits. It's merges and branching and poo poo where I get all hosed (oh god so many obscure commands that do things oh gently caress)
|
# ¿ Dec 28, 2013 04:57 |
|
EAT THE EGGS RICOLA posted:I would probably go with "well yeah that's what 'reset --hard' does what did you expect it's right in the name, aren't you committing multiple times a day like you're supposed to?" Horatio is being a non-lovely empathetic human being. Giving him smarmy comments to make back at his coworkers isn't going to help him or his relationship with his coworker. You sound like an unpleasant person to work with Horatio, just apologize and tell your coworker that they should be committing much more often. e: Basically I agree with brosmike QuarkJets fucked around with this message at 19:26 on Dec 28, 2013 |
# ¿ Dec 28, 2013 19:24 |
|
EAT THE EGGS RICOLA posted:I was being mostly flippant, but this person hosed up, not Horatio. He should be helpful, but his coworker needs to learn how to do his job properly. I definitely agree with that. If you find a coworker who's committing weekly, talk to them about the importance of committing much more frequently than that.
|
# ¿ Dec 28, 2013 22:22 |
|
After a few months of very light git usage, I still have a lot of problems doing anything beyond simple committing, pulling, and merging, which I guess is 99% of what you should need to do anyway. But recently I found this cheat sheet: This is some help, but many of these commands I fear may be doing things other than what the cheat sheet suggests. For example, git reset --hard is under "resolve merge conflicts -- discard conflicting patch" and "return to the last committed state", but if you were naively trying to undo a merge and used this command with uncommitted changes then you'd also be losing those changes. But on the whole, this is a nice little guide to some basic git commands When when would you need git commit -a --amend? What does this do? This also doesn't tell you how to create a standalone git repository, which is really useful if you need to merge changes from one network to another and the networks aren't allowed to ever touch except via physical media. e: I guess that my problem with git is that all of the power is hidden behind an extremely obfuscated interface, which makes it hard to learn these commands without a very in-depth guide QuarkJets fucked around with this message at 19:47 on Dec 30, 2013 |
# ¿ Dec 30, 2013 19:45 |
|
Suspicious Dish posted:You mean the part where it says git init? No, I was trying to describe creating a repository without a working directory: git --bare init and git --bare clone QuarkJets fucked around with this message at 10:00 on Dec 31, 2013 |
# ¿ Dec 31, 2013 09:57 |
|
Suspicious Dish posted:Any specific reason? Bare repositories are useful for all sorts of things, such as transporting changes between networks that can't touch each other except via optical media (government work)
|
# ¿ Jan 1, 2014 19:49 |
|
ninjeff posted:Assuming we're still around in fifty thousand years, the interstellar humans of the future will look at this video and enjoy the laughable idea that there's a Time that applies across the whole of the human species at once, then send version-vector-stamped hypertweets to their friends about the dumbass third-millenium humans. An atomic clock in a universally agreed-upon inertial reference frame QuarkJets fucked around with this message at 19:55 on Jan 1, 2014 |
# ¿ Jan 1, 2014 19:53 |
|
|
# ¿ May 17, 2024 14:48 |
|
ninjeff posted:That's what we're using now, and it doesn't scale. Your terrestrial ideas have no place in Big Space. Why doesn't it scale? You travel with your own atomic clock that stays in your reference frame. From time to time your computer checks in with the space system's central atomic clock to see how far you're off by and making an adjustment accordingly. It's not going to be exact, but time-keeping between two non-inertial frames where you don't necessarily know your velocity relative to the central clock that well is going to be impossible. The atomic clock is basically like having a clock tower; each town (space system) gets its own and from time to time some people get together to make sure that all of the clocks are running about right. I don't see us being able to do much better than that with the technology that exists today, and it's a pretty good and realistic solution And I hardly see what's terrestrial about a system of atomic clocks orbiting stars so that spaceship pilots can have some reasonably accurate way of telling time, but okay
|
# ¿ Jan 2, 2014 13:53 |