Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CI e automação de deploys em bibliotecas Python
Search
Camila Maia
August 13, 2021
Programming
490
0
Share
CI e automação de deploys em bibliotecas Python
DevOps Extreme 2021
Camila Maia
August 13, 2021
More Decks by Camila Maia
See All by Camila Maia
GitHub Actions - Semana DevOps LINUXTips.pdf
camilamaia
0
51
Minha Jornada em Developer Experience (DX) - DevOpsDays Salvador 2024
camilamaia
0
50
Cumbuca Dev: Ensinando com Open Source - 71º Python Floripa no MeLi
camilamaia
0
83
COMO E PORQUE ENSINAR A PROGRAMAR COM OPEN SOURCE - Python Brasil 2023
camilamaia
0
79
Como testar e manter APIs de qualidade - Codecon Digital 2023
camilamaia
0
1.2k
factory_boy: testing like a pro. DjangoCon US 2022
camilamaia
0
920
ScanAPI Workshop. DjangoCon EU 2022
camilamaia
0
810
factory_boy: testing like a pro. DjangoCon EU 2022
camilamaia
1
920
Como testar e documentar REST APIs com ScanAPI - Agile Testers Conference 2021
camilamaia
0
460
Other Decks in Programming
See All in Programming
Surviving Black Friday: 329 billion requests with Falcon!
ioquatix
0
850
実用!Hono RPC2026
yodaka
2
270
tRPCの概要と少しだけパフォーマンス
misoton665
2
240
The Monolith Strikes Back: Why AI Agents ❤️ Rails Monoliths
serradura
0
350
NakouPAY説明用
annouim0
0
270
ついに来た!本格的なマルチクラウド時代の Google Cloud
maroon1st
0
270
事業会社でのセキュリティ長期インターンについて
masachikaura
1
270
AIを導入する前にやるべきこと
negima
2
260
クラウドネイティブなエンジニアに向ける Raycastの魅力と実際の活用事例
nealle
2
220
瑠璃の宝石に学ぶ技術の声の聴き方 / 【劇場版】アニメから得た学びを発表会2026 #エンジニアニメ
mazrean
0
300
セグメントとターゲットを意識するプロポーザルの書き方 〜採択の鍵は、誰に刺すかを見極めるマーケティング戦略にある〜
m3m0r7
PRO
0
590
iOS機能開発のAI環境と起きた変化
ryunakayama
0
190
Featured
See All Featured
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
500
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.4k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
350
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Technical Leadership for Architectural Decision Making
baasie
3
340
ラッコキーワード サービス紹介資料
rakko
1
3.1M
A Modern Web Designer's Workflow
chriscoyier
698
190k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.4k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.9k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.5k
Transcript
CI e automação de deploys em bibliotecas Python Para deixar
qualquer DevOps orgulhoso ⭐ DevOps Extreme - Ago 2021 Camila Maia
Esta apresentação está disponível em: speakerdeck.com/cmaiacd
Quem sou eu? - Desenvolvedora Backend - 10+ anos xp
👵 - Python 🐍 e Ruby 💎 - OpenSource e Comunidades ❤ - Organização de eventos: Pyjamas, EuroPython, Python Brasil….
- Primeiro perfil aprovado no programa de Sponsors para quem
reside no Brasil Quem sou eu?
A biblioteca • Biblioteca Python • Gerenciamento de pacotes e
dependências via Poetry • Distribuída via PyPI e TestPyPI • Código no GitHub
Integração Contínua: • Testes unitários + Cobertura de Testes •
Lint: checagem de formatação do código, tipagem estática e formatação de mensagens de commit • Testes de integração Automação de deploys: • Merge no branch main: deploy no TestPyPI • Nova release: deploy no PyPI O objetivo
Ferramenta
A Aplicação Exemplo
• Framework de código aberto • Command line interface (CLI)
• Escrito em Python Objetivos: 1. Fornecer Live Documentation 2. Possibilitar a implementação de Testes de Integração
Fluxo ESPECIFICAÇÃO YAML / JSON RELATÓRIO EFETUA AS REQUESTS EXECUTA
OS TESTES
Integração Contínua
Integração Contínua Main Branch 1 Testes Unitários Lint Testes de
Integração
Makefile test: @pytest --cov=./scanapi --cov-report=xml black: @poetry run black -l
80 --check . --exclude=.venv flake8: @poetry run flake8 --ignore=E501,W501,E231,W503 mypy: @poetry run mypy scanapi gitlint: @poetry run gitlint --ignore-stdin check: black flake8 mypy gitlint
Pytest and Codecov
Lint
Testes de Integração - Run Examples
Deploys
Deploys Main Branch 1 Publish to TestPyPI New Release Publish
to PyPI
timestamp = `date -u +'%Y%m%d%H%M%S'` change-version: @poetry version `poetry version
-s | cut -f-3 -d.`.dev$(timestamp) Makefile + Setup das Chaves
Publish to TestPyPI
Publish to PyPI
👀
scanapi.dev 🌐
GitHub - https://github.com/scanapi Twitter - @ScanAPI_ Discord - discord.scanapi.dev Comunicação:
ScanAPI Bora trocar uma ideia! 🗣
MUITO OBRIGADA! @cmaiacd camilamaia cmaiacd.com