Python Continuous Integration and Delivery: A Concise Guide With Examples Lenz 2024 Scribd Download
Python Continuous Integration and Delivery: A Concise Guide With Examples Lenz 2024 Scribd Download
com
https://textbookfull.com/product/python-
continuous-integration-and-delivery-a-concise-
guide-with-examples-lenz/
https://textbookfull.com/product/perl-6-fundamentals-a-primer-with-
examples-projects-and-case-studies-moritz-lenz/
textbookfull.com
https://textbookfull.com/product/online-machine-learning-a-practical-
guide-with-examples-in-python-1st-edition-thomas-bartz-beielstein/
textbookfull.com
https://textbookfull.com/product/feeling-it-language-race-and-affect-
in-latinx-youth-learning-mary-bucholtz/
textbookfull.com
https://textbookfull.com/product/fighters-fact-book-2-street-fighting-
essentials-christensen-loren/
textbookfull.com
https://textbookfull.com/product/the-datacenter-as-a-computer-
designing-warehouse-scale-machines-luiz-andre-barroso/
textbookfull.com
https://textbookfull.com/product/transforming-perspectives-in-
lifelong-learning-and-adult-education-a-dialogue-laura-formenti/
textbookfull.com
https://textbookfull.com/product/essentials-of-organizational-
behavior-an-evidence-based-approach-teresa-terri-a-anne-scandura/
textbookfull.com
Towards a Maq■■id al-Shar■■ah Index of Socio-Economic
Development: Theory and Application Salman Syed Ali
https://textbookfull.com/product/towards-a-maqa%e1%b9%a3id-al-
shari%ca%bfah-index-of-socio-economic-development-theory-and-
application-salman-syed-ali/
textbookfull.com
Python
Continuous
Integration
and Delivery
A Concise Guide with Examples
—
Moritz Lenz
Python Continuous
Integration and
Delivery
A Concise Guide with Examples
Moritz Lenz
Python Continuous Integration and Delivery: A Concise Guide with
Examples
Moritz Lenz
Fürth, Bayern, Germany
iii
Table of Contents
Smoke Tests��������������������������������������������������������������������������������������������������10
Performance Tests�����������������������������������������������������������������������������������������10
1.5 Summary�����������������������������������������������������������������������������������������������������12
iv
Table of Contents
v
Table of Contents
vi
Table of Contents
vii
Table of Contents
Chapter 10: D
istributing and Deploying Packages in the Pipeline������143
10.1 Uploading in the Pipeline�������������������������������������������������������������������������143
User Accounts and Security�������������������������������������������������������������������������146
10.2 Deploying in the Pipeline�������������������������������������������������������������������������147
10.3 Results�����������������������������������������������������������������������������������������������������149
10.4 Going All the Way to Production���������������������������������������������������������������150
10.5 Achievement Unlocked: Basic Continuous Delivery���������������������������������152
viii
Table of Contents
Index�������������������������������������������������������������������������������������������������189
ix
Visit https://textbookfull.com
now to explore a rich
collection of eBooks, textbook
and enjoy exciting offers!
About the Author
Moritz Lenz is a prolific blogger, author, and
contributor to Open Source projects.
He works as software architect and
principal software engineer for a midsize IT
outsourcing company, where he has created a
Continuous Integration and Delivery system
for over 50 software libraries and applications.
xi
About the Technical Reviewer
Michael Thomas has worked in software
development for over 20 years as an individual
contributor, team lead, program manager,
and vice president of engineering. Michael
has more than 10 years of experience working
with mobile devices. His current focus is in
the medical sector, using mobile devices
to accelerate information transfer between
patients and health-care providers.
xiii
Acknowledgments
Writing a book is not a solitary endeavor and is only possible with help
from many individuals and organizations. I would like to thank all of my
beta readers who provided feedback. These include, in no particular order,
Karl Vogel, Mikhail Itkin, Carl Mäsak, Martin Thurn, Shlomi Fish, Richard
Lippmann, Richard Foley, and Roman Filippov. Paul Cochrane deserves
special thanks for reviewing and providing feedback on the blog posts
and manuscript and for being available to discuss content, ideas, and
organization matters.
I also want to thank my publishing team at Apress: Steve Anglin, Mark
Powers, and Matthew Moodie, as well as everybody doing awesome work
in the background, such as cover design, typesetting, and marketing.
Finally, thanks go to my parents, for kindling both my love for books
and engineering. And most important, to my family: to Signe, my wife, for
constant support; and to my daughters, Ida and Ronja, for keeping me
grounded in the real world and bringing joy to my life.
xv
Introduction
One of the keys to successful software development is getting fast
feedback. This helps developers avoid going down blind alleys, and in the
case of a bug that is revealed quickly, it can be fixed while the code is still
fresh in the developer’s mind.
On the business side, fast feedback also helps the stakeholders and
the product manager not to build features that turn out not to be useful,
thus avoiding wasted effort. Achieving a mutual understanding about
the desired product is a very difficult problem in any software project.
Showing a working (if partial) product early on often helps to eliminate
misunderstandings between stakeholders and developers.
There are many ways to add feedback loops on different levels, from
adding linting and other code checks in the IDE to agile processes that
emphasize incremental value delivery. The first part of this book focuses
on software tests and their automatic execution, a practice known as
continuous integration (CI).
When implementing CI, you set up a server that automatically tests
every change to the source code, potentially in multiple environments,
such as on combinations of operating system and programming language
versions.
The next logical step, and the topic of the second part of this book, is
continuous delivery (CD). After building and testing code, you add more
steps to the automated process: automated deployment to one or more test
environments, more tests in the installed state, and, finally, deployment to
a production environment. The last step is typically guarded by a manual
approval gate.
xvii
Introduction
CD extends the automation and, thus, the possibility for quick iteration
cycles, all the way into the production environment, where the software
can deliver value for you. With such a mechanism in place, you can quickly
obtain feedback or usage data from real customers and assess whether
expanding on a feature is useful or discover bugs while the developers still
remember the code that they wrote.
The code examples in this book use Python. Owing to its dynamic
nature, Python is well-suited to small experiments and fast feedback. The
well-stocked standard library and vast ecosystem of available libraries and
frameworks, as well as Python’s clean syntax, make it a good choice, even
for larger applications. Python is commonly used in many domains, for
example, web development, data science and machine learning, Internet
of things (IoT), and system automation. It is becoming the lingua franca of
professional programmers and those who just touch a subject to automate
some part of their job or hobby.
Python comes in two major language versions, 2 and 3. Because
Python 2 support is scheduled to end in 2020, and nearly all major libraries
now support Python 3, new projects should be started in Python 3, and
legacy applications should be ported to that language version as well,
if possible. Hence, this book assumes that “Python” refers to Python 3,
unless explicitly stated otherwise. If you only know Python 2, rest assured
that you will easily understand the source code contained in this book, and
transferring the knowledge to Python 3 is very easy.
xviii
Introduction
The chapters that use source code examples assume basic familiarity
with the Python programming language. If you are familiar with other
programming languages, spending a few hours reading introductory
material on Python will likely bring you to a level at which you can easily
follow the code examples in this book.
The sample infrastructure uses Debian GNU/Linux, so familiarity with
that operating system is helpful, though not required.
xix
CHAPTER 1
Automated Testing
Before diving into examples of how to test Python code, the nature of tests
must be discussed in more detail. Why do we want to have tests? What do
we gain from them? What are the downsides? What makes a good test;
what’s a bad test? How can we classify tests? And how many of which kinds
of tests should we write?
F ast Feedback
Every change to code comes with the risk of introducing bugs. Research
shows that somewhere in the range of 7% to 20% of all bug fixes introduce
new bugs.1
1
J im Bird, “Bugs and Numbers: How Many Bugs Do You Have in Your Code?”
Building Real Software: Developing and Maintaining Secure and Reliable
Software in the Real World, http://swreflections.blogspot.de/2011/08/
bugs-and-numbers-how-many-bugs-do-you.html, August 23, 2011.
Wouldn’t it be great if we could find those bugs before they find their
way to the customer? Or even before your colleagues see them? This is
not just a question of vanity. If you receive quick feedback that you have
introduced a bug, you are more likely to remember all the details of the
part of the code base you just worked on, so fixing the bug tends to be
much faster when you get fast feedback.
Many test cases are written to give this kind of fast feedback loop.
You can often run them before you ever commit your changes to the
source control system, and they make your work more efficient and keep
your source control history clear.
C
onfidence
Related to the previous point, but worth mentioning separately, is the
confidence boost you can get from knowing that the test suite will catch
simple mistakes for you. In most software-based businesses, there are
critical areas where serious bugs could endanger the whole business.
Just imagine you, as a developer, accidentally mess up the login system
of a health-care data management product, and now people see others’
diagnoses. Or imagine that automatic billing charges the wrong amount to
customers’ credit cards.
Even non-software businesses have had catastrophic failures from
software errors. Both the Mars climate orbiter2 and the first launch of
the Ariane 5 rocket3 suffered the loss of the respective vehicle, owing to
software issues.
2
ikipedia, “Mars Climate Orbiter,” https://en.wikipedia.org/wiki/Mars_
W
Climate_Orbiter, 2018.
3
J. L. Lions, “Ariane 5: Flight 501 Failure. Report by the Inquiry Board,”
http://sunnyday.mit.edu/accidents/Ariane5accidentreport.html, July 1996.
2
Chapter 1 Automated Testing
D
ebugging Aid
When developers change code, which in turn causes a test to fail, they want
the test to be helpful in finding the bug. If a test simply says “something is
wrong,” this knowledge is better than not knowing about the bug. It would be
even more helpful if the test could provide a hint to start debugging.
If, for example, a test failure indicates that the function find_
shortest_path raised an exception, rather than returning a path, as
expected, we know that either that function (or one it called) broke, or it
received wrong input. That’s a much better debugging aid.
D
esign Help
The Extreme Programming (XP)5 movement advocates that you should
practice test-driven development (TDD). That is, before you write any code
that solves a problem, you first write a failing test. Then you write just
enough code to pass the test. Either you are done, or you write the next
test. Rinse and repeat.
4
ikipedia, “Big ball of mud,” https://en.wikipedia.org/wiki/Big_ball_of_
W
mud, 2018.
5
Wikipedia, “Extreme programming,” https://en.wikipedia.org/wiki/Extreme_
programming, 2018.
3
Chapter 1 Automated Testing
This has obvious advantages: you make sure that all code you write
has test coverage and that you don’t write unnecessary or unreachable
code. However, TDD practitioners have also reported that the test-first
approach helped them write better code. One aspect is that writing a test
forces you to think about the application programming interface (API) that
the implementation will have, and so you start implementing with a better
plan in mind. Another reason is that pure functions (functions whose
return value depends only on the input and that don’t produce side effects
or read data from databases, etc.) are very simple to test. Thus, the test-first
approach guides the developer toward a better separation of algorithms
or business logic from supporting logic. This separation of concerns is an
aspect of good software design.
It should be noted that not everybody agrees with these observations,
with counterpoints from experience or arguments that some code is much
harder to test than write, leading to a waste of effort, by requiring tests
for everything. Still, the design help that tests can provide is a reason why
developers write code and so should not be missing here.
4
Visit https://textbookfull.com
now to explore a rich
collection of eBooks, textbook
and enjoy exciting offers!
Chapter 1 Automated Testing
Effort
It takes time and effort to write tests. So, when you are tasked with
implementing a feature, you not only have to implement the feature but
also write tests for it, resulting in more work and less time do other things
that might provide direct benefit to the business. Unless, of course, the
tests provide enough time savings (for example, through not having to fix
bugs in the production environment and clean up data that was corrupted
through a bug) to amortize the time spent on writing the tests.
5
Chapter 1 Automated Testing
Brittleness
Some tests can be brittle, that is, they occasionally give the wrong result.
A test that fails even though the code in question is correct is called a false
positive. Such a test failure takes time to debug, without providing any value.
A false negative is a test that does not fail when the code under test is broken.
A false negative test provides no value either but tends to be much harder to
spot than false positives, because most tools draw attention to failed tests.
Brittle tests undermine the trust in the test suite. If deployment of a
product with failing tests becomes the norm because everybody assumes
those failed tests are false positives, the signaling value of the test suite
has dropped to zero. You might still use it to track which of the tests failed
in comparison to the last run, but this tends to degenerate into a lot of
manual work that nobody wants to do.
Unfortunately, some kinds of tests are very hard to do robustly.
Graphical user interface (GUI) tests tend to be very sensitive to layout or
technology changes. Tests that rely on components outside your control
can also be a source of brittleness.
6
Chapter 1 Automated Testing
Unit Tests
A unit test exercises—in isolation—the smallest unit of a program
that makes sense to cover. In a procedural or functional programming
language, that tends to be a subroutine or function. In an object-oriented
language such as Python, it could be a method. Depending on how strictly
you interpret the definition, it could also be a class or a module.
7
Chapter 1 Automated Testing
A unit test should avoid running code outside the tested unit. So, if you
are testing a database-heavy business application, your unit test should
still not perform calls to the database (access the network for API calls) or
the file system. There are ways to substitute such external dependencies
for testing purposes that I will discuss later, though if you can structure
your code to avoid such calls, at least in most units, all the better.
Because access to external dependencies is what makes most code
slow, unit tests are usually blazingly fast. This makes them a good fit for
testing algorithms or core business logic.
For example, if your application is a navigation assistant, there is at
least one algorithmically challenging piece of code in there: the router,
which, given a map, a starting point, and a target, produces a route or,
maybe, a list of possible routes, with metrics such as length and expected
time of arrival attached. This router, or even parts of it, is something that
you want to cover with unit tests as thoroughly as you can, including
strange edge cases that might cause infinite loops, or check that a journey
from Berlin to Munich doesn’t send you via Rome.
The sheer volume of test cases that you want for such a unit makes
other kinds of tests impractical. Also, you don’t want such tests to fail,
owing to unrelated components, so keeping them focused on a unit
improves their specificity.
Integration Tests
If you assembled a complex system such as a car or a spacecraft from
individual components, and each component works fine in isolation, what
are the chances the thing as a whole works? There are so many ways things
could go wrong: some wiring might be faulty, components want to talk
through incompatible protocols, or maybe the joints can’t withstand the
vibration during operation.
8
Chapter 1 Automated Testing
System Tests
A system test puts a piece of software into an environment and tests it
there. For a classical three-tiered architecture, a system test starts from
input through the user interface and tests all layers down to the database.
Where unit tests and integration tests are white box tests (tests
that require and make use of the knowledge of how the software is
implemented), system tests tend to be black box tests. They take the user’s
perspective and don’t care about the guts of the system.
This makes system tests the most realistic, in terms of how the software
is put under test, but they come with several downsides.
First, managing dependencies for system tests can be really hard. For
example, if you are testing a web application, you typically first need an
account that you can use for login, and then each test case requires a fixed
set of data it can work with.
Second, system tests often exercise so many components at once
that a test failure doesn’t give good clues as to what is actually wrong and
requires that a developer look at each test failure, often to find out that
changes are unrelated to the test failures.
Third, system tests expose failures in components that you did not
intend to test. A system test might fail owing to a misconfigured Transport
Layer Security (TLS) certificate in an API that the software uses, and that
might be completely outside of your control.
Last, system tests are usually much slower than unit and integration
tests. White box tests allow you to test just the components you want, so
you can avoid running code that is not interesting. In a system test for a
web application, you might have to perform a login, navigate to the page
9
Random documents with unrelated
content Scribd suggests to you:
came outside of Manele. 97 He hou no keia mawaho ae o
noticed that their house was Manele. Ike aku la keia i ka hale
surrounded by a many-colored o laua ua paa i ka ua koko. A
cloud. When he arrived at his old hiki keia ilaila i kahi ana i lawaia
fishing ground his line and hook ai, ua moku aku la ke aho a ianei
were broken off. He returned and a me ka makau. Huli hoi mai la
when near shore he saw his wife keia a kokoke ike aku la keia i
standing on the seashore kana wahine e ku mai ana ma ka
beckoning to him. He said to aekai e peahi mai ana iaia. I iho
himself, “You are unaccountable, la keia iloko ona: “Kupanaha oe
my wife; you can see that I am e ka wahine, ua ike mai la no hoi
returning.” With one scoop of his ke hoi aku nei.” Hookahi no a
paddle in the sea the bow of the ianei kope ana i ke kai me ka
canoe landed on the sand. The hoe kau ana ka ihu o ka waa i ke
wife ran to him and grasped him one. Ia wa holo mai la kana
tremblingly. He asked, “What is wahine a apo mai la iaia, me ka
the cause of this heavy haalulu. Ninau ae la keia:
breathing?” She replied, with “Heaha hoi ke kumu o ka nui o
tears, “Our child has acted the ka hanu?” Pane iho la ia me ka
ghost to me.” “For what reason?” uwe: “Ua lapu ke keiki a kaua
“For this reason: soon after you ia’u.” “Heaha ke kumu?” “Eia ke
were gone I went to sleep and kumu, ia oe no hala aku nei, a
slept [558]soundly. A voice called, liuliu iki, ua keia loa wau e ka
‘Say, my dear mother, do thou hiamoe, kani ana kahea, ‘E! e
awaken; father is dead.’ I was ko’u mama aloha, e ala mai oe,
startled out of my sleep; I ua [559]make o papa.’ Ia wa
thought it was you. Not long after puiwa ae la wau mailoko mai o
that a voice chanted!” ka hiamoe, ua kuhi wau o oe, hoi
hou no wau a moe no, aole no i
The husband said, “Do you upu iho, kani ana ke oli.” I aku la
remember the chant?” “Yes,” ke kane: “Ua maopopo no nae
said the wife. paha ia oe ke oli ana mai?” “Ae,”
wahi a ka wahine.
How I desire the moisture of the Aloha au o kahi wai a ke kehau,
dew, Oia wai haaheo mai iluna o ka
The water proudly hanging on laau,
the tree; A ua mai ka ua i na pali,
When the rain falls on the E hoopiha ana i na kahawai,
precipice, O ka waiwai no ia a kuu maka o
It fills up the streams. ka ike aku,
That is the benefit my eyes A ike kuu maka a nehe kuu lima.
behold!
My eyes to behold, my hands to
rustle.
When the child had gone the I ka hele ana a ua keiki nei, ua
womb of Kapoiliili contracted, mimino iho la ka opu o Kapoiliilii,
and she said to her husband, olelo aku la ia i ke kane: “E ianei
“Where are you? Please feel my e! e haha mai oe i kuu opu.”
belly.” The other felt of it: “Why, Haha mai la ia: “E, ua emi iho
your stomach has shrunken!” nei ka ko opu.” “Kupanaha,”
“Strange!” said the wife. The wahi a ka wahine. I aku la kana
husband said, “Do not be kane: “Mai haohao oe ua hele
troubled, he has gone to see the aku la e makaikai ma kela wahi
different parts of the world.” They keia wahi o ka honua.” Hoi iho la
retired awhile for a short rest, laua hoonanea iki, kani ana
when the child called out: “You kahea a ua keiki nei: “E laua nei
two, awake, light the lamp.” They e, e ala, e hoa i ke kukui.” Ala ae
awakened and lit the lamp. “You laua hoa aku la i ke kukui. “E
two smoke up some tobacco for puhi mai olua i paka no’u, a e
me, and chew my piece of awa mama iho i kuu wahi opuupuu
root; it is above the door.” awa, aia maluna ae o ka puka.”
This is the way the fire was Eia ke kumu o ka loaa ana mai o
obtained, according to some ke ahi, wahi a kekahi poe, penei:
people. Maui took to wife Hina O Maui kai noho ae ia Hina
and begat Mauimua, 99 hanau mai o Mauimua, a me
Mauihope, 100 Mauikiikii 101 and Mauihope, a me Mauikiikii, a me
Mauiokalana; 102 they were all Mauiokalana, he poe keiki kane
boys. The occupation of these wale no keia. O ka hana a keia
boys was fishing. This was their poe keiki he lawaia. Penei ka
practice in fishing while living at lakou lawaia ana, ia lakou nei e
Kaupo, Maui: Mauiokalana noho ana ma Kaupo, i Maui,
wished to go fishing; he said to makemake iho la o Mauiokalana
his elder brothers: “Say, this is a e holo i ka lawaia; olelo aku i
calm day; shouldn’t we sail the kona poe kaikuaana: “E, kai ka
sea? for this is a good day, the malie o keia la, holo paha kakou
sea is calm; this is a day when i kai, nokamea, he la maikai
the tide is not strong in its keia, ua hele a malino ke kai, a
opposition for it is flowing in one he la ikaika ole o ke au i ke pale,
direction.” When he had finished a he la moekahi o ke au.” A pau
speaking, Mauimua answered: ka ianei olelo ana, pane mai la o
“Let us not sail, for this will be a Mauimua: “Aohe make holo o
tempestuous day; this calmness kakou, nokamea, he oi keia o ka
which we see is only in the la ino, o keia malie a kakou e ike
morning; when the sun rises you aku nei, he malie kakahiaka, ai
will see the waves rise, the wind aenei keia a kau ae ka la, alaila,
will increase, and in a short time ike aku oe e okaikai mai ana, a o
we will be obliged to return. Put ke ala mai no ia o ka makani,
off your fishing until a calm day.” aole e emo ka hoi koke mai no ia
Then Mauiokalana spoke again: o kakou. E waiho no ka lawaia a
“Why, I thought because you are hiki i ka la maile.” Alaila pane
the first-born you knew the signs hou mai la o Mauiokalana: “E, ke
of the sky, but I see you do not! kuhi nei au i kou hanau mua ike
Your yellow teeth signify oe i na ouli o ke ao, eia ka aole,
nothing.” Then Mauimua, he lenalena niho wale iho no
displeased, answered: “Say, my kou.” Alaila pane hookuakaeo
younger [562]brother, you do not mai la [563]o Mauimua: “E, auhea
realize that I am the one oe e ka pokii, aole oe i ike, owau
acquainted with the ways of this mai ka mea i kamaaina i ke ano
place. This is the sign I know o keia wahi; penei ka’u ouli i ike
about: when you sleep until near ai, aia moe aku oe a hiki i ka
morning, and should hear the wehe ana o kai o ke ao, a i poha
breaking surf above the wind, mai ka nalu iloko o ka makani,
then it will be calm. That is my alaila e malie aenei; oia ka’u
sign, that you may hear, my ouli, i lohe oe, e kuu pokii.
younger brother. But what of it? Heaha la nei hoi; e holo paha
let us sail according to your kakou mamuli o kau koi.”
urging.” Mauimua ordered the Hoolale ae la o Mauimua e hapai
canoes lifted to the beach. The na waa i kai. Hapai ia aku la no
canoes were taken to the shore, hoi na waa a hiki i ke kai, alaila
and they prepared to sail for makakau iho la lakou no ka holo
fishing. When they arrived at the i ka lawaia. Ia lakou nei i hiki aku
reef they saw a fire burning on ai i kohola ike aku la lakou nei i
land. Then Mauiokalana said to ka a mai o ke ahi o uka, alaila
his elder brothers: “Say, there is olelo mai la o Mauiokalana i
a fire burning; whose fire can this kona poe kaikuaana: “E, ke a
be?” The others replied: “Whose mai la ke ahi, nawai la hoi keia
indeed? Perhaps we had better ahi?” I mai la no hoi lakou:
return so we can cook some “Nawai hoi; e hoi paha kakou i
food for us.” “Pshaw! Let us first moa ona ai na kakou.” “Ka! e
go and get some fish, then holo kakou a loaa mai ona ia,
return; so that when we get back alaila lea ka hiamoe, ua moana.”
with fish we can broil them, cook Holo aku la lakou nei; aole i emo
the food, and then [we can] loaa mai la na ia. O ka hoi iho la
sleep well, being satisfied.” They no ia. A ia lakou nei i hiki aku ai i
went on; in no time they had kahakai, haalele iho la o
caught some fish. They then Mauimua i ka waa, a holo aku la
returned. As soon as they arrived e nana i kahi i a ai o ke ahi. Ike
at the beach Mauimua left the mai la o Kaalaehuapi, o ko lakou
canoe, and ran to where the fire kuehu ae la no ia i ke ahipio, pau
was seen burning. aku la lakou la i ka lele. Hoka iho
Kaalaehuapi 103 saw him so he la o Mauimua, hoi mai la a hiki i
and the others threw dirt on the ko lakou hale; ninau mai la ko
fire and smothered it, and flew lakou poe: “Pehea mai nei ka hoi
away. Mauimua was ke ahi?” “Aohe ahi, ua pio, ke
disappointed; he returned to their kuhi nei au he kanaka, eia ka
house. The others asked, “How aole, he alae ka mea nana ke
about the fire?” “There is no fire; ahi. O ka maia a kakou, ua pau i
it is put out; I thought it was man, ka aihue ia.” No ko lakou nei ike
but it was not; some mudhens ana i ka pau i ka aihue ia o ka
kindled the fire. Our bananas are maia, nolaila aole o lakou hele i
being stolen.” Because they saw ka lawaia, me ka manao e a hou
that their bananas were being mai ke ahi. Eia nae aohe a iki o
stolen they did not go fishing; ke ahi. Nolaila, holo hou lakou i
they hoped the fire would be ka lawaia; aia holo lakou nei i ka
kindled again, but it was not lawaia, alaila e a auanei ke ahi.
lighted. Then they went fishing Pela lakou nei i hooluhi ia ai,
again. Whenever they went out aohe loaa iki; nokamea, ua
fishing the fire would burn. Thus maopopo ia Kaalaehuapi eha no
were they harassed, but they keiki a Maui laua me Hina. I ka
could not get anything, because wa e holo ai i ka lawaia, helu aku
Kaalaehuapi knew that Maui and o Kaalaehuapi i ka nui o lakou; a
Hina had four sons. When they pau pono, alaila hoa ke ahi.
went fishing Kaalaehuapi
counted them; when they were
all present it would light the fire.