Professional Documents
Culture Documents
PDF A Philosophy of Software Design First Edition V1 0 Ousterhout Ebook Full Chapter
PDF A Philosophy of Software Design First Edition V1 0 Ousterhout Ebook Full Chapter
https://textbookfull.com/product/the-logic-of-information-a-
theory-of-philosophy-as-conceptual-design-luciano-floridi/
https://textbookfull.com/product/buddhist-philosophy-a-
comparative-approach-first-edition-emmanuel/
https://textbookfull.com/product/head-first-design-patterns-
building-extensible-and-maintainable-object-oriented-
software-2nd-edition-eric-freeman/
https://textbookfull.com/product/making-a-difference-essays-on-
the-philosophy-of-causation-first-edition-helen-beebee/
The philosophy of knowledge a history Volume 1
Knowledge in ancient philosophy First Published In
Great Britain Edition Hetherington
https://textbookfull.com/product/the-philosophy-of-knowledge-a-
history-volume-1-knowledge-in-ancient-philosophy-first-published-
in-great-britain-edition-hetherington/
https://textbookfull.com/product/leibnizs-naturalized-philosophy-
of-mind-first-edition-edition-jorgensen/
https://textbookfull.com/product/computer-organization-and-
design-the-hardware-software-interface-risc-v-edition-david-a-
patterson/
https://textbookfull.com/product/computer-organization-and-
design-risc-v-edition-the-hardware-software-interface-david-a-
patterson/
https://textbookfull.com/product/advancements-in-the-philosophy-
of-design-1st-edition-pieter-e-vermaas/
A Philosophy of Software
Design
John Ousterhout
Stanford University
A Philosophy of Software Design
by John Ousterhout
Printing History:
April 2018: First Edition (v1.0)
November 2018: First Edition (v1.01)
ISBN 978-1-7321022-0-0
Preface
1 Introduction
1.1 How to use this book
11 Design it Twice
13 Comments Should Describe Things that Aren’t Obvious from the Code
13.1 Pick conventions
13.2 Don’t repeat the code
13.3 Lower-level comments add precision
13.4 Higher-level comments enhance intuition
13.5 Interface documentation
13.6 Implementation comments: what and why, not how
13.7 Cross-module design decisions
13.8 Conclusion
13.9 Answers to questions from Section 13.5
14 Choosing Names
14.1 Example: bad names cause bugs
14.2 Create an image
14.3 Names should be precise
14.4 Use names consistently
14.5 A different opinion: Go style guide
14.6 Conclusion
17 Consistency
17.1 Examples of consistency
17.2 Ensuring consistency
17.3 Taking it too far
17.4 Conclusion
19 Software Trends
19.1 Object-oriented programming and inheritance
19.2 Agile development
19.3 Unit tests
19.4 Test-driven development
19.5 Design patterns
19.6 Getters and setters
19.7 Conclusion
21 Conclusion
Index
Summary of Design Principles
People have been writing programs for electronic computers for more than
80 years, but there has been surprisingly little conversation about how to
design those programs or what good programs should look like. There has
been considerable discussion about software development processes such as
agile development and about development tools such as debuggers, version
control systems, and test coverage tools. There has also been extensive
analysis of programming techniques such as object-oriented programming
and functional programming, and of design patterns and algorithms. All of
these discussions have been valuable, but the core problem of software
design is still largely untouched. David Parnas’ classic paper “On the
Criteria to be used in Decomposing Systems into Modules” appeared in
1971, but the state of the art in software design has not progressed much
beyond that paper in the ensuing 45 years.
The most fundamental problem in computer science is problem
decomposition: how to take a complex problem and divide it up into pieces
that can be solved independently. Problem decomposition is the central
design task that programmers face every day, and yet, other than the work
described here, I have not been able to identify a single class in any
university where problem decomposition is a central topic. We teach for
loops and object-oriented programming, but not software design.
In addition, there is a huge variation in quality and productivity among
programmers, but we have made little attempt to understand what makes the
best programmers so much better or to teach those skills in our classes. I
have talked with several people I consider to be great programmers, but
most of them had difficulty articulating specific techniques that give them
their advantage. Many people assume that software design skill is an innate
talent that cannot be taught. However, there is quite a bit of scientific
evidence that outstanding performance in many fields is related more to
high-quality practice than innate ability (see, for example, Talent is
Overrated by Geoff Colvin).
For many years these issues have perplexed and frustrated me. I have
wondered whether software design can be taught, and I have hypothesized
that design skill is what separates great programmers from average ones. I
finally decided that the only way to answer these questions was to attempt to
teach a course on software design. The result is CS 190 at Stanford
University. In this class I put forth a set of principles of software design.
Students then work through a series of projects to assimilate and practice
the principles. The class is taught in a fashion similar to a traditional
English writing class. In an English class, students use an iterative process
where they write a draft, get feedback, and then rewrite to make
improvements. In CS 190, students develop a substantial piece of software
from scratch. We then go through extensive code reviews to identify design
problems, and students revise their projects to fix the problems. This allows
students to see how their code can be improved by applying design
principles.
I have now taught the software design class three times, and this book is
based on the design principles that emerged from the class. The principles
are fairly high level and border on the philosophical (“Define errors out of
existence”), so it is hard for students to understand the ideas in the abstract.
Students learn best by writing code, making mistakes, and then seeing how
their mistakes and the subsequent fixes relate to the principles.
At this point you may well be wondering: what makes me think I know
all the answers about software design? To be honest, I don’t. There were no
classes on software design when I learned to program, and I never had a
mentor to teach me design principles. At the time I learned to program,
code reviews were virtually nonexistent. My ideas about software design
come from personal experience writing and reading code. Over my career I
have written about 250,000 lines of code in a variety of languages. I’ve
worked on teams that created three operating systems from scratch, multiple
file and storage systems, infrastructure tools such as debuggers, build
systems, and GUI toolkits, a scripting language, and interactive editors for
text, drawings, presentations, and integrated circuits. Along the way I’ve
experienced firsthand the problems of large systems and experimented with
various design techniques. In addition, I’ve read a considerable amount of
code written by other people, which has exposed me to a variety of
approaches, both good and bad.
Out of all of this experience, I’ve tried to extract common threads, both
about mistakes to avoid and techniques to use. This book is a reflection of
my experiences: every problem described here is one that I have
experienced personally, and every suggested technique is one that I have
used successfully in my own coding.
I don’t expect this book to be the final word on software design; I’m
sure there are valuable techniques that I’ve missed, and some of my
suggestions may turn out to be bad ideas in the long run. However, I hope
that the book will start a conversation about software design. Compare the
ideas in this book with your own experiences and decide for yourself
whether the approaches described here really do reduce software
complexity. This book is an opinion piece, so some readers will disagree
with some of my suggestions. If you do disagree, try to understand why. I’m
interested in hearing about things that work for you, things that don’t work,
and any other ideas you may have about software design. I hope that the
ensuing conversations will improve our collective understanding of software
design. I will incorporate what I learn in future editions of this book.
The best way to communicate with me about the book is to send email
to the following address:
software-design-book@googlegroups.com
I’m interested in hearing specific feedback about the book, such as bugs or
suggestions for improvement, as well as general thoughts and experiences
related to software design. I’m particularly interested in compelling
examples that I can use in future editions of the book. The best examples
illustrate an important design principle and are simple enough to explain in
a paragraph or two. If you would like to see what other people are saying on
the email address and participate in discussions, you can join the Google
Group software-design-book.
If for some reason the software-design-book Google Group should
disappear in the future, search on the Web for my home page; it will contain
updated instructions for how to communicate about the book. Please don’t
send book-related email to my personal email address.
I recommend that you take the suggestions in this book with a grain of
salt. The overall goal is to reduce complexity; this is more important than
any particular principle or idea you read here. If you try an idea from this
book and find that it doesn’t actually reduce complexity, then don’t feel
obligated to keep using it (but, do let me know about your experience; I’d
like to get feedback on what works and what doesn’t).
Many people have offered criticisms or made suggestions that improved
the quality of the book. The following people offered helpful comments on
various drafts of the book: Jeff Dean, Sanjay Ghemawat, John Hartman,
Brian Kernighan, James Koppel, Amy Ousterhout, Kay Ousterhout, Rob
Pike, Partha Ranganathan, Keith Schwartz, and Alex Snaps. Christos
Kozyrakis suggested the terms “deep” and “shallow” for classes and
interfaces, replacing previous terms “thick” and “thin”, which were
somewhat ambiguous. I am indebted to the students in CS 190; the process
of reading their code and discussing it with them has helped to crystallize
my thoughts about design.
Chapter 1
Introduction
(It’s All About Complexity)
Figure 2.1: Each page in a Web site displays a colored banner. In (a) the background color
for the banner is specified explicitly in each page. In (b) a shared variable holds the
background color and each page references that variable. In (c) some pages display an
additional color for emphasis, which is a darker shade of the banner background color; if
the background color changes, the emphasis color must also change.
Unknown unknowns: The third symptom of complexity is that it is not
obvious which pieces of code must be modified to complete a task, or what
information a developer must have to carry out the task successfully. Figure
2.1(c) illustrates this problem. The Web site uses a central variable to
determine the banner background color, so it appears to be easy to change.
However, a few Web pages use a darker shade of the background color for
emphasis, and that darker color is specified explicitly in the individual
pages. If the background color changes, then the the emphasis color must
change to match. Unfortunately, developers are unlikely to realize this, so
they may change the central bannerBg variable without updating the
emphasis color. Even if a developer is aware of the problem, it won’t be
obvious which pages use the emphasis color, so the developer may have to
search every page in the Web site.
Of the three manifestations of complexity, unknown unknowns are the
worst. An unknown unknown means that there is something you need to
know, but there is no way for you to find out what it is, or even whether
there is an issue. You won’t find out about it until bugs appear after you
make a change. Change amplification is annoying, but as long as it is clear
which code needs to be modified, the system will work once the change has
been completed. Similarly, a high cognitive load will increase the cost of a
change, but if it is clear which information to read, the change is still likely
to be correct. With unknown unknowns, it is unclear what to do or whether
a proposed solution will even work. The only way to be certain is to read
every line of code in the system, which is impossible for systems of any
size. Even this may not be sufficient, because a change may depend on a
subtle design decision that was never documented.
One of the most important goals of good design is for a system to be
obvious. This is the opposite of high cognitive load and unknown
unknowns. In an obvious system, a developer can quickly understand how
the existing code works and what is required to make a change. An obvious
system is one where a developer can make a quick guess about what to do,
without thinking very hard, and yet be confident that the guess is correct.
Chapter 18 discusses techniques for making code more obvious.
2.3 Causes of complexity
Now that you know the high-level symptoms of complexity and why
complexity makes software development difficult, the next step is to
understand what causes complexity, so that we can design systems to avoid
the problems. Complexity is caused by two things: dependencies and
obscurity. This section discusses these factors at a high level; subsequent
chapters will discuss how they relate to lower-level design decisions.
For the purposes of this book, a dependency exists when a given piece
of code cannot be understood and modified in isolation; the code relates in
some way to other code, and the other code must be considered and/or
modified if the given code is changed. In the Web site example of Figure
2.1(a), the background color creates dependencies between all of the pages.
All of the pages need to have the same background, so if the background is
changed for one page, then it must be changed for all of them. Another
example of dependencies occurs in network protocols. Typically there is
separate code for the sender and receiver for the protocol, but they must
each conform to the protocol; changing the code for the sender almost
always requires corresponding changes at the receiver, and vice versa. The
signature of a method creates a dependency between the implementation of
that method and the code that invokes it: if a new parameter is added to a
method, all of the invocations of that method must be modified to specify
that parameter.
Dependencies are a fundamental part of software and can’t be
completely eliminated. In fact, we intentionally introduce dependencies as
part of the software design process. Every time you write a new class you
create dependencies around the API for that class. However, one of the
goals of software design is to reduce the number of dependencies and to
make the dependencies that remain as simple and obvious as possible.
Consider the Web site example. In the old Web site with the background
specified separately on each page, all of the Web pages were dependent on
each other. The new Web site fixed this problem by specifying the
background color in a central place and providing an API that individual
pages use to retrieve that color when they are rendered. The new Web site
eliminated the dependency between the pages, but it created a new
dependency around the API for retrieving the background color.
Fortunately, the new dependency is more obvious: it is clear that each
individual Web page depends on the bannerBg color, and a developer can
easily find all the places where the variable is used by searching for its
name. Furthermore, compilers help to manage API dependencies: if the
name of the shared variable changes, compilation errors will occur in any
code that still uses the old name. The new Web site replaced a nonobvious
and difficult-to-manage dependency with a simpler and more obvious one.
The second cause of complexity is obscurity. Obscurity occurs when
important information is not obvious. A simple example is a variable name
that is so generic that it doesn’t carry much useful information (e.g., time).
Or, the documentation for a variable might not specify its units, so the only
way to find out is to scan code for places where the variable is used.
Obscurity is often associated with dependencies, where it is not obvious that
a dependency exists. For example, if a new error status is added to a system,
it may be necessary to add an entry to a table holding string messages for
each status, but the existence of the message table might not be obvious to a
programmer looking at the status declaration. Inconsistency is also a major
contributor to obscurity: if the same variable name is used for two different
purposes, it won’t be obvious to developer which of these purposes a
particular variable serves.
In many cases, obscurity comes about because of inadequate
documentation; Chapter 13 deals with this topic. However, obscurity is also
a design issue. If a system has a clean and obvious design, then it will need
less documentation. The need for extensive documentation is often a red
flag that the design isn’t quite right. The best way to reduce obscurity is by
simplifying the system design.
Together, dependencies and obscurity account for the three
manifestations of complexity described in Section 2.2. Dependencies lead to
change amplification and a high cognitive load. Obscurity creates unknown
unknowns, and also contributes to cognitive load. If we can find design
techniques that minimize dependencies and obscurity, then we can reduce
the complexity of software.
2.4 Complexity is incremental
Complexity isn’t caused by a single catastrophic error; it accumulates in lots
of small chunks. A single dependency or obscurity, by itself, is unlikely to
affect significantly the maintainability of a software system. Complexity
comes about because hundreds or thousands of small dependencies and
obscurities build up over time. Eventually, there are so many of these small
issues that every possible change to the system is affected by several of
them.
The incremental nature of complexity makes it hard to control. It’s easy
to convince yourself that a little bit of complexity introduced by your
current change is no big deal. However, if every developer takes this
approach for every change, complexity accumulates rapidly. Once
complexity has accumulated, it is hard to eliminate, since fixing a single
dependency or obscurity will not, by itself, make a big difference. In order
to slow the growth of complexity, you must adopt a “zero tolerance”
philosophy, as discussed in Chapter 3.
2.5 Conclusion
Complexity comes from an accumulation of dependencies and obscurities.
As complexity increases, it leads to change amplification, a high cognitive
load, and unknown unknowns. As a result, it takes more code modifications
to implement each new feature. In addition, developers spend more time
acquiring enough information to make the change safely and, in the worst
case, they can’t even find all the information they need. The bottom line is
that complexity makes it difficult and risky to modify an existing code base.
Chapter 3
Grandfather Lepage.
By Jules Bastien-Lepage.
The grandfather was represented seated in a garden chair,
holding on his knees his horn snuff-box and his handkerchief of blue
cotton. His striking face stood out well detached from the
background of trees; the black velvet cap sloping jauntily towards his
ear gave effect to the shrewd Socratic face; his blue eyes twinkled
with humour; the nose was broad and retroussé; the white forked
beard spread itself over an ancient vest of the colour of dead leaves;
the hands, painted like life, were crossed upon the grey trousers.
Before this picture, so true, so frank, of such marvellous intensity
of familiar life, the public stood delighted, and the name of Bastien-
Lepage, unknown before, figured the next day in the first place in the
articles on the Salon.
II.
It was in front of this picture that I first met Jules. Having looked in
my catalogue for the name of the painter, I was delighted to find that
he was from the Meuse, and born at that same Damvillers where I
had once lived.
The heavy soil of our department is not fruitful in artists. When it
has produced one it takes a rest for a few centuries.
Since Ligier Richier, the celebrated sculptor, born at the end of the
fifteenth century, the Meuse could only claim credit for the painter
Yard a clever decorator of churches and houses in the time of Duke
Stanislas; so I was quite proud to find that Bastien-Lepage was a
fellow countryman of mine. A few moments later a mutual friend
introduced us to each other.
I saw before me a young man, plainly dressed, small, fair, and
muscular; his pale face, with its square determined brow, short nose,
and spiritual lips, scarcely covered with a blond moustache, was
lighted up by two clear blue eyes whose straight and piercing look
told of loyalty and indomitable energy. There was roguishness as
well as manliness in that mobile face with its flattened features, and
a certain cool audacity alternated with signs of sensitiveness and
sparkling fun and gaiety.
Remembrances of our native province, our common love of the
country and of life in the open air, soon established kindly relations
between us, and after two or three meetings we had entered upon a
close friendship.
The portrait of the grandfather had won for him a third medal, and
had ensured him a place in the sunshine.
It was not yet a money success, but it was a certain degree of
fame; he might go back to his village with his heart at rest, his head
high. The State had just bought his picture, La Chanson du
Printemps (The Song of Spring), and orders were beginning to come
in.
In 1875 Bastien-Lepage reappeared in the Salon with La
Communiante (The Communicant) and the portrait of M. Simon
Hayem, two excellent works which gave, each in its way, a new mark
of his originality.
The portrait of M. Hayem was best liked by men of the world;
artists were most struck by La Communiante.
The Communicant.
By Jules Bastien-Lepage.
This young girl’s simple awkward bearing, as she stands out from
a creamy background, with all the stiffness of her starched white veil,
naïvely opening her pure hazel eyes, and crossing her fingers, ill at
ease in the white gloves, is a marvel of truthful painting. It reminds
one of the manner of Memling and of Clouet, though with quite a
modern feeling. It is interesting, as being the first of those small,
lifelike, characteristic portraits, in a style at once broad and
conscientious, which may be reckoned among the most perfect of
this painter’s works.
At the time of these successes in the Salon, Bastien joined in the
competition for the Prix de Rome. The subject chosen for 1875 was
taken from the New Testament—L’Annonciation aux Bergers (The
Annunciation to the Shepherds).
I remember as if it were yesterday that July morning when the
gates of the Palais des Beaux Arts were opened, and the crowd of
eager inquirers rushed into the hall of the competition.
After a few minutes Bastien’s picture was surrounded, and a buzz
of approval arose from the groups of young people gathered round
that work, so real, so strongly conceived and executed that the other
nine canvases disappeared as in a mist.
The artist had understood and treated the subject in a manner
utterly different from the usual style of the Academy. It was familiar
and touching, like a page of the Bible. The visit of the angel had
surprised the shepherds sleeping by their fire in the open air; the
oldest of them was kneeling before the apparition, and prostrated
himself in adoration; the youngest was gazing with half-closed eyes,
and his open lips and hands, with fingers apart, expressed
astonishment and admiration. The angel, a graceful figure, with
childlike almost feminine head, was showing with outstretched arm
to the shepherds, Bethlehem in the distance surrounded by a
miraculous halo.
This picture, which has both the charm of poetic legend and a
manly grip of real life, was executed with uncommon grace and
vigour; its very faults contributed to the realization of the effect aimed
at.
Most of those who saw this work of Lepage declared that he
would carry off the Prix de Rome with a high hand; yet the jury
decided otherwise. It was an older and more correct competitor who
was sent to the Villa Medicis at the cost of the State.
For a moment Bastien-Lepage was troubled and discouraged by
this decision. Not that he felt himself strongly attracted towards
Rome and Italian art, but he knew that many people judge of an
artist by his success. Among the people down in his province and in
his own family the Prix de Rome would have been considered as an
official recognition of his talent, and he regretted, above all, not being
able to give this satisfaction to his relations, who had undergone so
many privations in order to maintain him at Paris. That he did not
soon forget this unmerited check, we may gather from this fragment
of a letter to a friend:
“I learned my business in Paris, I shall not forget that; but my art I
did not learn there. I should be sorry to undervalue the high qualities
and the devotion of the masters who direct the school. But is it my
fault if I have found in their studio the only doubts that have
tormented me? When I came to Paris I knew nothing at all, but I had
never dreamed of that heap of formulas they pervert one with. In the
school I have drawn gods and goddesses, Greeks and Romans, that
I knew nothing about, that I did not understand, and even laughed at.
I used to say to myself that this might be high art; I wonder
sometimes now if anything has resulted from this education….”
However, he did not consider himself beaten. The following year,
at the same time that he was exhibiting his portrait of M. Wallon, he
went in again for the Prix de Rome competition. This time it was less
for his own sake than to give a satisfaction to his family and friends.
He did not enter with any real feeling into this competition, the
subject for which was: Priam suppliant Achille de lui rendre le corps
de son fils Hector (Priam begging Achilles to restore to him the body
of his son Hector). This picture, though a vigorous composition, tells
almost nothing of the deep and poignant emotion of this episode of
the Iliad.
Once more he failed to gain the prize, but this time he did not take
it much to heart. He was occupied with more absorbing prospects:
his last visit to Damvillers had bent his mind toward another ideal.
Whatever he might say, his studies in the school had not been
without their use to him. They had developed in him the critical
faculty. His repugnance to factitious and conventional art had driven
him with more force to the exact and attentive observation of nature.
At Paris he had learned to compare, and to see better. The
Meuse country, so little heroic, with its low hills, its limited horizons,
its level plains, had appeared to him suddenly more attractive and
more worthy of interest than the heroes of Greece and Rome. Our
labourers driving the plough across the field; our peasant women
with their large liquid eyes, prominent jaws, and widely opening
mouths; our vine-dressers, their backs curved with the labour of the
hoe, had revealed themselves to him as models much more
attractive than those of the atelier. It was a work for a great artist to
bring out the poetry pervading the village folk and their belongings
and to give it a real existence, as it were, by means of line and
colour. To represent the intoxicating odour of the mown grass, the
heat of the August sun on the ripe corn, the life of the village street;
to bring into relief the men and women who have their joys and
sorrows there; to show the slow movement of thought, the anxieties
about daily bread on faces with irregular and even vulgar features;—
this is human art, and consequently high art. This is what the Dutch
painters did, and they created masterpieces. Bastien, while lounging
among the orchards of Damvillers and the woods of Réville, resolved
that he would do as they had done, that he would paint the peasants
of the Meuse.
The list of studies begun or completed at this time shows us the
progress of this dominant idea: La Paysanne au Repos (The
Peasant Woman Reposing), La Prairie de Damvillers (The Meadow
at Damvillers), the two sketches for the picture Les Foins (The Hay),
Les Jardins au Printemps (Gardens in Spring), Les Foins Mûrs (Ripe
Grasses), L’Aurore (Dawn)—all these canvases bear the date of
1876.
It was in the autumn of the same year that we carried out a long-
talked-of plan for making an excursion together on foot into the
Argonne. I went to join him in September at Damvillers.
Thanks to him, I saw with a very different feeling the town that
formerly I thought so dull. Cordially and hospitably received in the
house at the corner of the great square, I made the acquaintance of
the father, with his calm, thoughtful face; of the grandfather, so
cheerful in spite of his eighty years; of the mother, so full of life, so
devoted, the best mother that one could wish for an artist. I saw what
a strong and tender union existed between the members of this
family whose idol and whose pride was Jules.
We set out along with one of my old friends and the painter’s
young brother. For a week we walked with our bags on our backs
through the forest country of the Argonne, going through woods from
Varennes to La Chalade, and from Islettes to Beaulieu. The weather
was rainy and unpleasant enough, but we were none the less gay for
that, never winking when the rain came down, visiting the glass-
works, admiring the deep gorges in the forests, the solitary pools in
the midst of the woods, the miles of green and misty avenues at the
foot of the hills.
Jules Bastien was always the leader. When we arrived at our
resting place in an evening, after a day of walking in the rain, he
almost deafened us with scraps of café-concert songs, with which
his memory was stored.
I seem still to hear in the dripping night that voice, clear and
vibrating, now silent for ever….
As we went along he told me of his plans for the future.
He wanted to tell the whole story of country life in a series of large
pictures: hay-making, harvest, seed-time, the lovers, the burial of a
young girl…. He also wanted to paint a peasant woman as Jeanne
d’Arc, at the moment when the idea of her divine mission is taking
possession of her brain; then, a Christ in the Tomb.
Together we made a plan for publishing a series of twelve
compositions: Les Mois Rustiques (The Months in the Country), for
which he was to furnish the drawings and I the text.
From time to time we stopped at the opening of a wood or at the
entrance of a village, and Jules would make a hasty sketch, little
thinking that the wild and simple peasants of the Argonne would take
us for Germans surreptitiously making notes of their roads and
passes. At Saint Rouin, while we were looking on at a Pilgrimage,
we had nearly been taken as spies. I have told this story
elsewhere.[1] The remembrance of it amused us for a long time.
After eight days of this vagabond life we separated at Saint Mihiel,
where Bastien wished to see the group of statues of the sepulchre,
the chef d’œuvre of Ligier Richier, before beginning his Christ in the
Tomb.
Shortly afterwards he gave an account of this visit in a letter to his
friend Baude, the engraver:
“Our too short walk through the Argonne has been very
interesting, and ended with a visit to the grand chef d’œuvre of Ligier
Richier at Saint Mihiel. You must see that some day. I have seen
nothing in sculpture so touching. France ought to know better and to
be prouder of that great Lorraine artist. You will see a photograph of
this masterpiece when you come to me….”
He had scarcely been six weeks at Damvillers again when he lost
his father, who was suddenly carried off by pulmonary congestion.
Death entered the house for the first time, and it was a rude shock
for a family where each loved the other so well.
“We were too young to lose such a good friend,” he wrote to me;
“in spite of all the courage one can muster, the void, the frightful void
is so great, that one is sometimes in despair….”
“… Happily remembrance remains (letter to M. Victor Klotz), and
what a remembrance it is! … the purest that is possible;—he was
goodness and self-abnegation personified; he loved us so!… What is
to be done? We must try to fill the void with love for those who
remain, and who are attached to us, always keeping in mind him
who is gone, and working much to drive away the fixed idea.”
And indeed he did work furiously: at Damvillers, at a Job that
remains unfinished, and at Paris at the full-length portrait of a lady,
which was exhibited in the Salon of 1877.
He had left the Rue Cherche Midi and had settled in the Impasse
du Maine, where his studio and his apartment occupied one floor of
a building, at the end of a narrow neglected garden, whose only
ornaments were an apricot tree and some lilac bushes.
His brother Emile, who just then came to an end of his study of
architecture in the school, lived with him.
His studio was very large, and was simply furnished with an old
divan, a few stools, and a table covered with books and sketches. It
was decorated only with the painter’s own studies and a few
hangings of Japanese material.
I used to go there every morning at this time to sit for my portrait.
I used to arrive about eight o’clock, to find Jules already up, but
with his eyes only half awake, swallowing two raw eggs, to give
himself tone, as he said.
He already complained of stomach trouble, and lived by rule. We
used to smoke a cigarette, and then he began to work. He painted
with a feverish rapidity, and with a certainty of hand quite
astonishing. Sometimes he would stop, get up and roll a cigarette,
would closely examine the face of his model, and then, after five
minutes of silent contemplation, he would sit down again with the
vivacity of a monkey and begin to paint furiously.
The portrait, sketched in during the snows of January, was almost
finished when the apricot tree began to put on its covering of white
flowers in April.
The Hayfield.
By Jules Bastien-Lepage.
Immediately after the opening of the Salon, Bastien packed up his
baggage and fled to Damvillers to prepare for his great picture Les
Foins (The Hayfield), which occupied him all the summer of 1877,
and of which he gave me news from time to time.
“July.—I shall not say much about my work; the subject is
not yet sufficiently sketched in. What I can tell you is that I am
going to give myself up to a debauch in pearly tones: half-dry
hay and flowering grasses; and this in the sunshine, looking
like a pale yellow tissue with silver threads running through it.
“The clumps of trees on the banks of the stream and in the
meadow will stand out strongly with a rather Japanese
effect….”
“15th August.—Your verses are just the picture I should
like to paint. They smell of the hay and the heat of the
meadow…. If my hay smells as well as yours I shall be
content…. My young peasant is sitting with her arms apart,
her face hot and red; her fixed eyes seeing nothing; her
attitude altogether broken and weary. I think she will give the
true idea of a peasant woman. Behind her, flat on his back,
her companion is asleep, with his hands closed; and beyond,
in the meadow, in the full sun, the haymakers are beginning to
work again. I have had hard work to set up my first ideas,
being determined to keep simply to the true aspect of a bit of
nature. Nothing of the usual willow arrangement, with its
branches drooping over the heads of the people to frame the
scene. Nothing of that sort. My people stand out against the
half-dry hay. There is a little tree in one corner of the picture
to show that other trees are near, where the men are gone to
rest in the shade. The whole tone of the picture will be a light
grey green….”
“September.—Why didn’t you come, lazy fellow? You
would have seen my Hay before it was finished. Lenoir, the
sculptor, my neighbour in the Impasse, liked it. The country
people say it is alive. I have little more than the background to
finish. I am going to harness myself to the Reapers, and to a
nude study of a Diogenes the cynic, or rather, the sceptic….”
Les Foins was sent to the Salon in 1878. It had a great success,
though it was warmly discussed.
In the hall where it was placed, among the pictures which
surrounded it, this picture gave an extraordinary sensation of light
and of the open air. It had the effect of a large open window.
The meadow, half mown, went back bathed with sunshine, under
a summer sky, flecked with light clouds. The young haymaker sitting
drooping in the heat, intoxicated with the smell of the hay, her eyes
fixed, her limbs relaxed, her mouth open, was wonderfully real.
There was nothing of the conventional peasant whose hands look as
if they had never touched a tool, but a veritable countrywoman
accustomed from childhood to outdoor work. One felt that she was
weary with fatigue, and glad to breathe a moment at her ease, after
a morning of hard work in the sun.
This picture of life in the fields, so carefully studied, so powerfully
rendered, had a considerable influence on the painting of the day.
From the time of this exhibition many young painters, many foreign
artists especially, threw themselves with enthusiasm into the new
way opened out by Bastien-Lepage, and, without intention on his
part, the painter of the Meusian peasants became the head of a
school.