Anyway, that's just my feeling at the moment, I'm sure others have a different take.
420 karma · joined May 17, 2011
Anyway, that's just my feeling at the moment, I'm sure others have a different take.
So as I see it there are two types of tool, formatters and checkers. A formatter doesn't alter the Abstract Syntax Tree (AST). In other words it doesn't alter the meaning of the code, just how it looks (eg. the formatter Black). A checker on the other hand looks only at the AST and just gives warnings in your editor, and then it's up to you to change it or not.
The import order is fixed in the AST, so it falls outside the scope of Black (which never changes the AST). So I felt there was a need for a tool that worked as a checker that just gives warnings in your editor if your imports don't conform to PEP8, and hence Flake8 Alphabetize.
It's worth mentioning that Flake8 Alphabetize follows Black's philosophy of having only one way of doing things, so a project can standardise on Flake8 Alphabetize and everyone's imports will look the same.
Anyway, any feedback is welcomed:-)
In the UK, where there's a semblance of a free market in electricity generation, it's been possible for decades for nuclear power stations to be build by private industry. None have because they just can't compete economically. The cases where they have been built have all been when the government intervened in the market and heavily subsidized them. Nobody really knows why!
The native API is a lot simpler, and so I'd use that if you can. The native API is really my suggestion for the next version of DB-API, so DB-API 3. I'd be interested to know people's thoughts on this, and maybe we could put together a draft specification?
https://github.com/tlocke/pg8000#copy-from-and-to-a-file
The standard API for database access in Python is DB-API 2 and it doesn't include support for COPY , so each driver may implement it differently.
There's another aspect to this, and that's the format of the file to be ingested as it can be 'text', 'CSV' or 'binary'. If you're generating the file yourself then you have a choice, but whether 'binary' is faster than 'CSV' I just don't know.
I work on pg8000 https://github.com/tlocke/pg8000 which is used by Amazon, Google etc. I'd argue that pg8000 and any Open Source software doesn't give them a competitive advantage, because in order to have a competitive advantage you have to have something that your competitors don't have. It's more that they'd be at a competitive disadvantage if they didn't use Open Source software.
That's not to say there aren't problems with the big tech companies, but I'd say that Open Source isn't where the problems lie. In my view the problems stem from the nature of the web, in that it is a centralized architecture that inevitably concentrates power. Something like IPFS https://ipfs.io would help liberate the web?
So using your analysis of the single worker, which I agree with, it actually makes a very big difference when applied to all workers.
To address your point about the training costs of moving from proprietary to Open Source, again this disappears if the move happens at scale. It disappears because every worker would have learnt Linux at their previous job (or at school / college etc.) and so in fact the cheapest thing becomes to use Linux.
What your argument demonstrates is the network effects of proprietary software, whereby if you're the first to use Open Source software it's a disadvantage, but if everyone used it, it would be an overall advantage to society.
The question then becomes, how do we get from here (often proprietary) to there (mostly Open Source)?
https://github.com/tlocke/zish
It has timestamps and decimals. Full disclosure, I am the author.
https://github.com/warner/python-versioneer
It means you only specify the version as a git tag, and all the other things that need a version number get it from that.
https://stackoverflow.com/questions/21832701/does-json-synta...
It's still in its early stages, so if anyone's got any comments I'm interested in hearing them :-)
https://github.com/tlocke/zish
It's a data serialization format with timestamp, bytes and decimal data types.
https://github.com/tlocke/zish
(as the author, I'm biased)
HEADLINE: Embrace the spirit of Open Source, not just comply with the letter of the law
DESCRIPTION:
Here's an extract from the Software Freedom Conservancy report on Canonical's licensing policy:
> Redistributors of Ubuntu have little choice but to become expert analysts of Canonical, Ltd.'s policy. They must identify on their own every place where the policy contradicts the GPL. If a dispute arises on a subtle issue, Canonical, Ltd. could take legal action, arguing that the redistributor's interpretation of GPL was incorrect. Even if the redistributor was correct that the GPL trumped some specific clause in Canonical, Ltd.'s policy, it may be costly to adjudicate the issue.
https://sfconservancy.org/news/2015/jul/15/ubuntu-ip-policy/