9,867 karma · joined Aug 20, 2015 (11y ago) · 5,528 submissions
comment 10y ago · link · parent
- no classes (so people end up emulating them: Backbone has methods to emulate class declaration and class inheritance)
- no type hinting. You cannot specify function argument type or return type. It makes code harder to read and to maintain.
- too forgiving. You can divide by zero or mistype a property name and get no error. You can add arrays to strings. It makes bugs harder to find.
- no coding standard. Everyone uses whatever style they like
- no single modules standard
- no syntax for asynchronous operations
- difficult to install XML library on Windows (you need to setup a Visual Studio to compile binary modules)
> Heroku + Ruby on Rails gets close[1], but it took them nearly 10 years to catch up.
You have to learn Linux and command line to use Ruby. No wonder it is more difficult for a newbie. Deploying and running an application is more complicated in Ruby. Also with long-living applications it is easy to get a memory leak.
But recently PHP started to depend more on CLI tools too (installing and using composer might be not easy for people who got used to GUI and don't understand concepts like "working directory").
comment 10y ago · link · parent
This approach works well only with tiny applications written by a single person. Once the app grows larger it will get hard to support.
ORM have their disadvantages but you have to learn them thoroughly including how they are made internally. They are not some magic tools that "just work". But in a large application you have to use objects and therefore ORM.
ORMs usually have some form of SQL-like syntax, for example Doctrine has DQL.
comment 10y ago · link · parent
It looks like a casino where you are allowed only to lose, not a free market where you can trade however you like. Once you find a profitable scheme you go to jail.
comment 10y ago · link · parent
In MySQL there is no templates and you can change the encoding of a table at any time using ALTER TABLE statement.
And in cloud IDEs like c9.io you cannot use unicode collations in Postgres because they need to be installed separately and they are not installed.
comment 10y ago · link · parent
That is not clear at all and pretty useless. What does it mean? I should not accept any user input at all?
> strip everything that is not needed
That does not always work. What if I have a comment form that should accept any characters?
comment 10y ago · link · parent
Luckily I used a separate email account for registration so I just redirected all emails from facebook to a spam folder.
comment 10y ago · link · parent
- they can be stored in a version control system
- your coworkers can run them at their dev environment
- they can be used for automatic deployment
- you can test it in a dev environment before running at a production server. With GUI tools you have to remember and repeat exact steps you did before
- You can review the script or ask someone to look at it
I think GUI tools might be good for browsing and exploring database but not for making changes.
comment 10y ago · link · parent
Assignment is interpreted as add-to-the-list operator.
comment 10y ago · link · parent
But I might be wrong. For example this 2008 year document [1] says it uses same IP and MAC address as OS and filters packets by port number.
[1] http://web.archive.org/web/20080219044745/http://softwarecom...
comment 10y ago · link · parent
comment 10y ago · link · parent
- many mistakes are silently ignored. If you mistype object field name, divide a number by zero, add number to a string, access missing array element, no error is raised
- no proper OOP and classes
- no type hints for variables, function arguments or return values (well, there is TypeScript but it is another language)
- package manager (npm) loves to create deep hierarchies of folders
comment 10y ago · link · parent
- using case of a first letter of identifier as a public/private flag. You end up with half names starting in a lowercase letter, half in an uppercase (the code looks inconsistent) and forgetting how to spell them. And having to rename the function everywhere when you decide to change it from private to public.
- no official package manager. Unclear how to add external libraries to your project and how to set specific version you need. I ended up adding necessary files into a separate folder in my project.
- Go manual suggests you have single directory for all projects and libraries. That was inconvinient because I develop on Windows and use Linux only to test and run code in /tmp directory, I do not keep the code there. And why would I want to keep unrelated projects inside the same directory anyway?
- no rules how to split contants, types and functions into files and folders. For example in PHP there are certain rules: each class goes to its own file and you always know that class Some\Name is stored at src/Some/Name.php. Easy to remember. And in Go you never know what goes where. Large projects probably look like a mess of functions scattered around randomly
- no default values for struct members, no constructors
- no proper OOP with classes
- standard library is poor
- open source libraries you can find on github are not always good. I looked for library to handle config files and command line arguments and didn't like any.
- standard testing library doesn't have asserts
- easy to forget that you need to pass structures by pointer (in OOP objects are passed by reference by default). And generally use of pointers makes the code harder to read and to write.
- weird syntax for structure methods. They are declared separately from the structure.
- go has 2 assignment operators (= and :=) and it is easy to use the wrong one
- having to check and pass error value through function calls instead of using an exception. So most of functions in your code will have two return values - result and error
- no collections library
- simple things like reading a file by lines are not so simple to implement without mistakes
- static typing is good but sometimes you cannot use it. For example I wanted to have the options in a configuration file mapped to the fields of a structure. I had to use reflection and every mistake lead to runtime panic. And you cannot use complex types like "pointer to any structure" or "pointer to a reflect.Value containg structure" or "list of anything" or "bool, string or int".
Of course Go has also many good parts that might outweight its disadvantages but I am not writing about them. For example I have not used goroutines but they look like a simple solution for processing async tasks or writing servers.
I think Go is not ready yet for writing large applications. It might be ok if you write a small utility but I cannot imagine ORM like Hibernate or web application written in Go.
Also I took a look at the code in the presentation. I wouldn't want to write such code. For example, here https://talks.golang.org/2016/applicative.slide#20 they use static methods (http.HandleFunc(), log.Fatal()) instead of instance methods. So you cannot have two logs or two servers. Using static methods everywhere is bad especially in large applications. Google itself uses Go only for small utilities like simple proxy servers.
comment 10y ago · link · parent
comment 10y ago · link · parent
Is that really so? It seems that last 20 years Microsoft just plays whack-a-mole game closing endless vulnerabilities instead of designing a better architecture that would not allow such things.
For example in Windows any app has full access to a device. The user can run any app written by anyone just by clicking a link on a web page or mail message. In Android these problems are partially fixed and in iOS the user is unable to run malicious applications at all.
comment 10y ago · link · parent
comment 10y ago · link · parent
It might be acceptable if Microsoft gave their product away for free: many free products (e.g. Sublime or Skype) include annoying autoupdate popups for non-paying users. But Windows is quite expensive software.
Microsoft's motives are just getting more paid services, getting more telemetry (for free! they do not pay for it) and maybe adding some kind of subscription in future. Recent Windows versions like 7 or 8 seem to be 'good enough' for most customers so they do not want to upgrade for free let alone buy newer versions.
And subscription is as bad as DRM.
comment 10y ago · link · parent
There is a lot of people trying to earn on clicking ads with bots.
Edit: and by the way disabling JS is an effective method against most of the fingerprinting techniques.