Profile

Cover photo
Mikhail Glushenkov
70,424 views
AboutPostsPhotosVideos

Stream

 
"Generally, denotational semantics gets into a somewhat hairy world of comparative linguistics since ultimately the domain of your denotation can usually be thought of as not much more than a "nicer" language than the one who's syntax you're studying." - tel@reddit, https://www.reddit.com/r/haskell/comments/2qvbhp/denotational_design_does_not_work/cnaawmv
1
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
Thanks to GHCJS developers, Cabal is getting some new features to better support compilers that target JavaScript. If you maintain such a compiler, you may want to leave a comment in this thread: http://thread.gmane.org/gmane.comp.lang.haskell.cabal.devel/10020
2
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
Possible lessons for Hackage here?
The Zen of Comprehensive Archive Networks. It seems that there is a lot of interest in having similar archives for other languages like CPAN [1] is for Perl. I should know; over the years people from at least Python, Ruby, and Java communities have approached me or other core CPAN people to ask ...
1
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
I've implemented a new option '--allow-newer' for 'cabal install' / 'cabal configure' that allows to relax upper bounds in dependencies without editing the package description.

In plain English: if you want to install a package A that depends on B >= 1.0 && < 2.0, but you have the version 2.0 of B installed, you can now compile A against B 2.0 by using 'cabal install --allow-newer=B A'. This works for the whole package index: if A also depends on C that in turn depends on B < 2.0, C's dependency on B will be also relaxed.

Example:

    $ cd foo
    $ cabal configure
    Resolving dependencies...
    cabal: Could not resolve dependencies:
    [...]

    $ cabal configure --allow-newer
    Resolving dependencies...
    Configuring foo...

Additional examples:

    # Relax upper bounds in all dependencies.
    $ cabal install --allow-newer foo

    # Relax upper bounds only in dependencies on bar, baz and quux.
    $ cabal install --allow-newer=bar,baz,quux foo

    # Relax the upper bound on bar and force bar==2.1.
    $ cabal install --allow-newer=bar --constraint="bar==2.1" foo

It's also possible to enable '--allow-newer' permanently by setting 'allow-newer: True' in the '~/.cabal/config' file.

Hopefully, this feature will alleviate at least some of the problems people have been having with strict upper bounds on Hackage.
19
1
Mikhail Glushenkov's profile photoSergei Trofimovich's profile photo
2 comments
 
+Sergei Trofimovich It's cabal-install only, for now.
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
New blog post:
What's new in Cabal 1.18 - sandboxes, REPL, cross-compilation and more! Tags: haskell. The 1.18 release of Cabal is almost ready. This post describes what's new and improved in this version. User-visible features. Sandboxes - isolated environments for building packages, similar to (and inspired ...
10
2
Oliver Braun's profile photoSergei Trofimovich's profile photo
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
Please help us test the Windows installer for the 2013.2.0.0 Haskell Platform release!
From: Mikhail Glushenkov gmail.com> Subject: Haskell Platform 2013.2.0.0 Windows installer RC1 Newsgroups: gmane.comp.lang.haskell.libraries, gmane.comp.lang.haskell.platform. Date: 2013-05-21 00:00:15 GMT (17 hours and 4 minutes ago) ...
1
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
Gmail tip of the day: Settings > General > Default reply behaviour > Reply all.
2
1
Alexander Batischev's profile photo
Add a comment...
 
cabal-install binaries for Windows, Linux and OS X are now available on the Cabal website: http://www.haskell.org/cabal/download.html
Note: Most people already have Cabal because it is included in the Haskell Platform. If you want to upgrade to the latest stable version, just run: $ cabal install cabal cabal-install. Sometimes the older installed version is still on the program search $PATH, you can check you're running the ...
4
1
Johan Tibell's profile photo
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
cabal-install now has a '--require-sandbox' option that makes all sandbox-aware commands ('install'/'build'/etc.) exit with error if there is no sandbox present. This makes it harder to accidentally modify the user package database by e.g. forgetting to initialise a sandbox and then using 'cabal install' on a project with many dependencies. The option can be turned on via the per-user configuration file ('~/.cabal/config') or the per-project one ('$PROJECT_DIR/cabal.config'). Use '--no-require-sandbox' if you want to override the config setting temporarily.
14
IC Rainbow's profile photoMikhail Glushenkov's profile photoDon Stewart's profile photoJohan Tibell's profile photo
4 comments
 
+Don Stewart we could do it behind the scenes to the user can't tell. ;)

More seriously, sandboxes are just a mechanism for hermetic builds. Sandboxes are intended to simulate the following behavior: the package being built is built as-if there are no other packages installed on the machine. Nix (i.e. immutable) package stores are another way to achieve the same results, but we haven't been able to build one for GHC yet.
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
 
Cabal 1.18.0 is out: https://groups.google.com/forum/#!topic/haskell-cafe/SFoNwaq8wdc

Here's the typical workflow we expect people to use with this cabal release. First you create the sandbox and install all dependencies:

    cd my-pkg
    cabal sandbox init  # only once
    cabal install --only-dependencies --enable-tests

While installing dependencies take a while, it only needs to be done once (unless you add dependencies). If you put

    jobs: $ncpus

in your ~/.cabal/config file, all builds will be done in parallel, speeding up dependency installation.

For your day-to-day development you run either `cabal build` or `cabal test` (both now imply `cabal configure`).

    cabal build  # or:
    cabal test

If you need to e.g. debug a function, you can play with it from within GHCi:

    cabal repl

`cabal repl` automatically passes the right flags to ghci and also re-runs any preprocessors (e.g. hsc2hs) so you don't have to do that manually. We're still working on making `cabal repl` better, but even the first version should be a big improvement to what we had before.

Note how we're trying to move away from global (or user) installs of packages. There are still use cases for that, but by default we try to keep each project's dependencies separate (by using a sandbox). For a bit more on the philosophy behind the development behind the current UI read my blog post:

http://blog.johantibell.com/2012/03/cabal-of-my-dreams.html
[Haskell-cafe] ANN: Cabal v1.18.0 released, Johan Tibell, 9/4/13 2:11 PM, Hi all, On behalf of the cabal maintainers and contributors I'm proud to announce the Cabal (and cabal-install) 1.18.0 release. To install run cabal update && cabal install Cabal-1.18.0 cabal-install-1.18.0 With 854 ...
7 comments on original post
7
2
Jens Petersen's profile photoSergei Trofimovich's profile photoAlejandro Cabrera's profile photo
 
Thanks for the great work!
Add a comment...

Mikhail Glushenkov

Shared publicly  - 
 
New blog post:
An Introduction to Cabal sandboxes. Tags: haskell, gsoc. This post describes sandboxes, a new feature of cabal that will be present in the 1.18 release. Sandboxes allow to build packages in isolation by creating a private package environment for each package. If you are familiar with Python's ...
4
Add a comment...
 
These slides point out that the common idiom "write(tmp); close(tmp); rename(dst, tmp)" is wrong and should actually be "write(tmp); fflush(tmp); fsync(tmp); close(tmp); rename(tmp, dst);". Except fsync has a null implementation on some platforms, so you have to jump through some extra hoops. Shouldn't we be providing a portable implementation of this idiom in the standard library?
4
Ben Millwood's profile photoKirill Zaborsky's profile photoGeorge Pollard's profile photoRobin Green's profile photo
8 comments
 
+George Pollard The problem with Unicode strings is not in relation to filenames, it only affects file contents. Filenames are fine, they're just represented as strings. It's when you use Bytestrings that you have to be careful about unicode.
Add a comment...
Basic Information
Gender
Male
Story
Tagline
Student, Haskell programmer.
Links