Laur IVAN

Check Duplicated Paths with LoDash (and Angular 2)

Posted by in Uncategorized

One of the things I’m looking at is to be able to create a list of paths I’d want to scan. The first iteration had blind addition to the list. However, this would make the user’s responsibility to manage the duplicated paths, which is not really nice. Therefore, I think it’s a good thing to add some sort of path duplication detection in the code. The pseudo-code would be something like:

In this case, if we have a non-null item, then we already have something in the list. Otherwise,…read more

Get all Proposal Names from the Participant Portal

Posted by in Software, Tutorial, Uncategorized

I’ve found out the participant portal for H2020 offers an API. This is quite neat as one can integrate with the data, e.g. by reading and listing the calls. I’ve written a proof of concept to list all calls from this and last years. First, we load the data in a JSON object:

Then, we extract the year:

Lastly, we iterate through all calls and extract the ones we need:

For the calls API, you can have access to the following information (fields): CallIdentifier FileName – e.g….read more

Set Up Concourse Behind a Proxy

Posted by in IT, Uncategorized

TL;DR: Most important thing is to find out if your proxy mangles/removes headers. If yes, then you need to contact your IT department. I’ve got the following error: Get https://registry-1.docker.io/v2: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers) Prerequisites In order to get Concourse CI working, you need to : Install VirtualBox and Install Vagrant in a directory without spaces (ruby bug) Now, you need to install the proxy plugin for Vagrant:

Then, initalise the install

Proxy configurations The vagrant proxy will allow you…read more

Custom saving path for FileField

Posted by in Uncategorized

Saving FileFields is pretty annoying anyway (all the manual stuff, saving chunks by hand…). The top bother is actually the limited way of creating paths: In MEDIA_ROOT, only with strftime arguments. While this does limit the number of files in a directory, it’s not as customisable as it should… So, here‘s the alternative:

…and

Now, your files are going to be saved in a path containing the username, with a mangled local name (so the only way to see which file it is and what’s supposed to do…read more

MacPorts Berkley-DB 4 problem and work around

Posted by in Uncategorized

I’ve upgraded my MacPro’s hardware a bit the other day and I’ve noticed that something went bye-bye when running eclipse. Namely eclipse itself wasn’t working anymore. So I thought: What a great opportunity to do an update (eclipse, jdk…). And MacPorts. Because I wanted to upgrade my python to 2.7 (2.7 has a couple of extra niceties compared to 2.6, and django doesn’t yet work with 3.x). Anyway, I’ve downloaded the Helios eclipse, cleaned up macports and updated it again. Nice. Had to re-download Xcode, which, this time is a…read more