ed7e1b8
# For translations, check docs/*/docs/index.md
ed7e1b8
# Note that there are many other localized versions of the documentation
ed7e1b8
# *present*, but untranslated.
ed7e1b8
%global sum_en  FastAPI framework
ed7e1b8
%global sum_es  FastAPI framework
46d6976
%global sum_fr  Framework FastAPI
ed7e1b8
%global sum_he  תשתית FastAPI
ed7e1b8
%global sum_ja  FastAPI framework
ed7e1b8
%global sum_ko  FastAPI 프레임워크
ed7e1b8
%global sum_pl  FastAPI to szybki
ed7e1b8
%global sum_pt  Framework FastAPI
d8f3754
%global sum_ru  FastAPI
ed7e1b8
%global sum_tr  FastAPI framework
ed7e1b8
%global sum_zh  FastAPI 框架
ed7e1b8
ed7e1b8
Name:           python-fastapi
7dc3d47
Version:        0.99.0
ed7e1b8
Release:        %autorelease
ed7e1b8
Summary:        %{sum_en}
ed7e1b8
65f73c8
# SPDX
ed7e1b8
License:        MIT
ed7e1b8
URL:            https://github.com/tiangolo/fastapi
ed7e1b8
Source0:        %{url}/archive/%{version}/fastapi-%{version}.tar.gz
ed7e1b8
BuildArch:      noarch
ed7e1b8
d8f1c6f
# https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval
d8f1c6f
# This package is noarch, but excluding i686 allows this package’s dependencies
d8f1c6f
# to exclude i686 support too, which ultimately affects some arched packages.
d8f1c6f
ExcludeArch:    %{ix86}
d8f1c6f
ed7e1b8
# Fix sql_app_py39 and py310 tests
ed7e1b8
# https://github.com/tiangolo/fastapi/pull/4409
ed7e1b8
Patch:          %{url}/pull/4409.patch
2579697
# Upgrade databases and SQLAlchemy
2579697
# https://github.com/tiangolo/fastapi/pull/5799
28a8207
Patch:          %{url}/pull/5799.patch
fe21f7a
# Merge pull request from GHSA-qf9m-vfgh-m389
fe21f7a
# https://github.com/tiangolo/fastapi/commit/9d34ad0ee8a0dfbbcce06f76c2d5d851085024fc
fe21f7a
# Requires python-multipart >= 0.0.7. Raises upper bound on python-multipart
fe21f7a
# versions for testing to <0.1.0.
fe21f7a
# See:
2e24b2a
# https://github.com/tiangolo/fastapi/security/advisories/GHSA-qf9m-vfgh-m389
fe21f7a
# Rebased on 0.99.0 and on top of the other patches.
2e24b2a
Patch:          fastapi-0.99.0-multipart-0.0.7.patch
ed7e1b8
ed7e1b8
BuildRequires:  python3-devel
ed7e1b8
ed7e1b8
Obsoletes:      python-fastapi-doc < 0.68.1-6
ed7e1b8
ed7e1b8
Summary(en):    %{sum_en}
ed7e1b8
Summary(es):    %{sum_es}
46d6976
Summary(fr):    %{sum_fr}
ed7e1b8
Summary(he):    %{sum_he}
ed7e1b8
Summary(ja):    %{sum_ja}
ed7e1b8
Summary(ko):    %{sum_ko}
ed7e1b8
Summary(pl):    %{sum_pl}
ed7e1b8
Summary(pt):    %{sum_pt}
9af288a
Summary(ru):    %{sum_ru}
ed7e1b8
Summary(tr):    %{sum_tr}
ed7e1b8
Summary(zh):    %{sum_zh}
ed7e1b8
ed7e1b8
%global common_description_en %{expand:
ed7e1b8
FastAPI is a modern, fast (high-performance), web framework for building APIs
e18f2cb
with Python 3.7+ based on standard Python type hints.
ed7e1b8
ed7e1b8
The key features are:
ed7e1b8
ed7e1b8
  • Fast: Very high performance, on par with NodeJS and Go (thanks to Starlette
ed7e1b8
    and Pydantic). One of the fastest Python frameworks available.
ed7e1b8
079bc14
  • Fast to code: Increase the speed to develop features by about 200% to
079bc14
    300%.*
ed7e1b8
  • Fewer bugs: Reduce about 40% of human (developer) induced errors.*
ed7e1b8
  • Intuitive: Great editor support. Completion everywhere. Less time
ed7e1b8
    debugging.
ed7e1b8
  • Easy: Designed to be easy to use and learn. Less time reading docs.
ed7e1b8
  • Short: Minimize code duplication. Multiple features from each parameter
ed7e1b8
    declaration. Fewer bugs.
ed7e1b8
  • Robust: Get production-ready code. With automatic interactive
ed7e1b8
    documentation.
ed7e1b8
  • Standards-based: Based on (and fully compatible with) the open standards
ed7e1b8
    for APIs: OpenAPI (previously known as Swagger) and JSON Schema.
ed7e1b8
079bc14
* estimation based on tests on an internal development team, building
079bc14
  production applications.}
ed7e1b8
%global common_description_es %{expand:
ed7e1b8
FastAPI es un web framework moderno y rápido (de alto rendimiento) para
e18f2cb
construir APIs con Python 3.7+ basado en las anotaciones de tipos estándar de
ed7e1b8
Python.
ed7e1b8
ed7e1b8
Sus características principales son:
ed7e1b8
ed7e1b8
  • Rapidez: Alto rendimiento, a la par con NodeJS y Go (gracias a
ed7e1b8
    Starlette y Pydantic). Uno de los frameworks de Python más rápidos.
ed7e1b8
ed7e1b8
  • Rápido de programar: Incrementa la velocidad de desarrollo entre 200% y
ed7e1b8
    300%.*
ed7e1b8
  • Menos errores: Reduce los errores humanos (de programador) aproximadamente
ed7e1b8
    un 40%.*
ed7e1b8
  • Intuitivo: Gran soporte en los editores con auto completado en todas
ed7e1b8
    partes. Gasta menos tiempo debugging.
ed7e1b8
  • Fácil: Está diseñado para ser fácil de usar y aprender. Gastando menos
ed7e1b8
    tiempo leyendo documentación.
ed7e1b8
  • Corto: Minimiza la duplicación de código. Múltiples funcionalidades con
ed7e1b8
    cada declaración de parámetros. Menos errores.
ed7e1b8
  • Robusto: Crea código listo para producción con documentación automática
ed7e1b8
    interactiva.
ed7e1b8
  • Basado en estándares: Basado y totalmente compatible con los estándares
ed7e1b8
    abiertos para APIs: OpenAPI (conocido previamente como Swagger) y JSON
ed7e1b8
    Schema.
ed7e1b8
ed7e1b8
* Esta estimación está basada en pruebas con un equipo de desarrollo interno
ed7e1b8
  contruyendo aplicaciones listas para producción.}
46d6976
%global common_description_fr %{expand:
46d6976
FastAPI est un framework web moderne et rapide (haute performance) pour la
46d6976
création d’API avec Python 3.7+, basé sur les annotations de type standard de
46d6976
Python.
46d6976
46d6976
Les principales fonctionnalités sont :
46d6976
46d6976
  • Rapidité : De très hautes performances, au niveau de NodeJS et Go (grâce à
46d6976
    Starlette et Pydantic). L’un des frameworks Python les plus rapides.
46d6976
  • Rapide à coder : Augmente la vitesse de développement des fonctionnalités
46d6976
    d’environ 200 % à 300 %. *
46d6976
  • Moins de bugs : Réduit d’environ 40 % les erreurs induites par le
46d6976
    développeur. *
46d6976
  • Intuitif : Excellente compatibilité avec les IDE. Complétion complète.
46d6976
    Moins de temps passé à déboguer.
46d6976
  • Facile : Conçu pour être facile à utiliser et à apprendre. Moins de temps
46d6976
    passé à lire la documentation.
46d6976
  • Concis : Diminue la duplication de code. De nombreuses fonctionnalités
46d6976
    liées à la déclaration de chaque paramètre. Moins de bugs.
46d6976
  • Robuste : Obtenez un code prêt pour la production. Avec une documentation
46d6976
    interactive automatique.
46d6976
  • Basé sur des normes : Basé sur (et entièrement compatible avec) les
46d6976
    standards ouverts pour les APIs : OpenAPI (précédemment connu sous le nom
46d6976
    de Swagger) et JSON Schema.
46d6976
46d6976
* estimation basée sur des tests d’une équipe de développement interne,
46d6976
  construisant des applications de production.}
ed7e1b8
%global common_description_he %{expand:
ed7e1b8
FastAPI היא תשתית רשת מודרנית ומהירה (ביצועים גבוהים) לבניית ממשקי תכנות
e18f2cb
יישומים (API) עם פייתון 3.7+ בהתבסס על רמזי טיפוסים סטנדרטיים.
ed7e1b8
ed7e1b8
תכונות המפתח הן:
ed7e1b8
ed7e1b8
  • מהירה: ביצועים גבוהים מאוד, בקנה אחד עם NodeJS ו - Go (תודות ל - Starlette
ed7e1b8
  • ו - Pydantic). אחת מתשתיות הפייתון המהירות ביותר.
ed7e1b8
ed7e1b8
  • מהירה לתכנות: הגבירו את מהירות פיתוח התכונות החדשות בכ - %200 עד %300.*
ed7e1b8
  • פחות שגיאות: מנעו כ - %40 משגיאות אנוש (מפתחים).*
ed7e1b8
  • אינטואיטיבית: תמיכת עורך מעולה. השלמה בכל מקום. פחות זמן ניפוי שגיאות.
ed7e1b8
  • קלה: מתוכננת להיות קלה לשימוש וללמידה. פחות זמן קריאת תיעוד.
ed7e1b8
  • קצרה: מזערו שכפול קוד. מספר תכונות מכל הכרזת פרמטר. פחות שגיאות.
ed7e1b8
  • חסונה: קבלו קוד מוכן לסביבת ייצור. עם תיעוד אינטרקטיבי אוטומטי.
ed7e1b8
  • מבוססת סטנדרטים: מבוססת על (ותואמת לחלוטין ל -) הסטדנרטים הפתוחים לממשקי
ed7e1b8
    תכנות יישומים: OpenAPI (ידועים לשעבר כ - Swagger) ו - JSON Schema.
ed7e1b8
ed7e1b8
* הערכה מבוססת על בדיקות של צוות פיתוח פנימי שבונה אפליקציות בסביבת ייצור.}
ed7e1b8
%global common_description_ja %{expand:
e18f2cb
FastAPI は、Pythonの標準である型ヒントに基づいてPython 3.7 以降でAPI
ed7e1b8
を構築するための、モダンで、高速(高パフォーマンス)な、Web フレームワークです。
ed7e1b8
ed7e1b8
主な特徴:
ed7e1b8
ed7e1b8
  - 高速: NodeJS や Go 並みのとても高いパフォーマンス (Starlette と Pydantic
ed7e1b8
    のおかげです)。最も高速な Python フレームワークの一つです。
ed7e1b8
ed7e1b8
  - 高速なコーディング: 開発速度を約 200%~300%向上させます。 *
ed7e1b8
  - 少ないバグ: 開発者起因のヒューマンエラーを約 40%削減します。 *
ed7e1b8
  - 直感的: 素晴らしいエディタのサポートや オートコンプリート。
ed7e1b8
    デバッグ時間を削減します。
ed7e1b8
  - 簡単: 簡単に利用、習得できるようにデザインされています。
ed7e1b8
    ドキュメントを読む時間を削減します。
ed7e1b8
  - 短い: コードの重複を最小限にしています。
ed7e1b8
    各パラメータからの複数の機能。少ないバグ。
ed7e1b8
  - 堅牢性:
ed7e1b8
    自動対話ドキュメントを使用して、本番環境で使用できるコードを取得します。
ed7e1b8
  - Standards-based: API
ed7e1b8
    のオープンスタンダードに基づいており、完全に互換性があります: OpenAPI
ed7e1b8
    (以前は Swagger として知られていました) や JSON スキーマ.
ed7e1b8
ed7e1b8
* 本番アプリケーションを構築している開発チームのテストによる見積もり。}
ed7e1b8
%global common_description_ko %{expand:
ed7e1b8
FastAPI는 현대적이고, 빠르며(고성능), 파이썬 표준 타입 힌트에 기초한
e18f2cb
Python3.7+의 API를 빌드하기 위한 웹 프레임워크입니다.
ed7e1b8
ed7e1b8
주요 특징으로:
ed7e1b8
ed7e1b8
  • 빠름: (Starlette과 Pydantic 덕분에) NodeJS 및 Go와 대등할 정도로 매우 높은
ed7e1b8
    성능. 사용 가능한 가장 빠른 파이썬 프레임워크 중 하나.
ed7e1b8
ed7e1b8
  • 빠른 코드 작성: 약 200%에서 300%까지 기능 개발 속도 증가.*
ed7e1b8
  • 적은 버그: 사람(개발자)에 의한 에러 약 40% 감소.*
ed7e1b8
  • 직관적: 훌륭한 편집기 지원. 모든 곳에서 자동완성. 적은 디버깅 시간.
ed7e1b8
  • 쉬움: 쉽게 사용하고 배우도록 설계. 적은 문서 읽기 시간.
ed7e1b8
  • 짧음: 코드 중복 최소화. 각 매개변수 선언의 여러 기능. 적은 버그.
ed7e1b8
  • 견고함: 준비된 프로덕션 용 코드를 얻으십시오. 자동 대화형 문서와 함께.
ed7e1b8
  • 표준 기반: API에 대한 (완전히 호환되는) 개방형 표준 기반: OpenAPI (이전에
ed7e1b8
    Swagger로 알려졌던) 및 JSON 스키마.
ed7e1b8
ed7e1b8
* 내부 개발팀의 프로덕션 애플리케이션을 빌드한 테스트에 근거한 측정}
ed7e1b8
%global common_description_pl %{expand:
ed7e1b8
FastAPI to nowoczesny, wydajny framework webowy do budowania API z użyciem
e18f2cb
Pythona 3.7+ bazujący na standardowym typowaniu Pythona.
ed7e1b8
ed7e1b8
Kluczowe cechy:
ed7e1b8
ed7e1b8
  • Wydajność: FastAPI jest bardzo wydajny, na równi z NodeJS oraz Go (dzięki
ed7e1b8
    Starlette i Pydantic). Jeden z najszybszych dostępnych frameworków
ed7e1b8
    Pythonowych.
ed7e1b8
  • Szybkość kodowania: Przyśpiesza szybkość pisania nowych funkcjonalności o
ed7e1b8
    około 200% do 300%.*
ed7e1b8
  • Mniejsza ilość błędów: Zmniejsza ilość ludzkich (dewelopera) błędy o około
ed7e1b8
    40%.*
ed7e1b8
  • Intuicyjność: Wspaniałe wsparcie dla edytorów kodu. Dostępne wszędzie
ed7e1b8
    automatyczne uzupełnianie kodu. Krótszy czas debugowania.
ed7e1b8
  • Łatwość: Zaprojektowany by być prosty i łatwy do nauczenia. Mniej czasu
ed7e1b8
    spędzonego na czytanie dokumentacji.
ed7e1b8
  • Kompaktowość: Minimalizacja powtarzającego się kodu. Wiele funkcjonalności
ed7e1b8
    dla każdej deklaracji parametru. Mniej błędów.
ed7e1b8
  • Solidność: Kod gotowy dla środowiska produkcyjnego. Wraz z automatyczną
ed7e1b8
    interaktywną dokumentacją.
ed7e1b8
  • Bazujący na standardach: Oparty na (i w pełni kompatybilny z) otwartych
ed7e1b8
    standardach API: OpenAPI (wcześniej znane jako Swagger) oraz JSON Schema.
ed7e1b8
ed7e1b8
* oszacowania bazowane na testach wykonanych przez wewnętrzny zespół
ed7e1b8
  deweloperów, budujących aplikacie używane na środowisku produkcyjnym.}
ed7e1b8
%global common_description_pt %{expand:
ed7e1b8
FastAPI é um moderno e rápido (alta performance) framework web para construção
e18f2cb
de APIs com Python 3.7 ou superior, baseado nos type hints padrões do Python.
ed7e1b8
ed7e1b8
Os recursos chave são:
ed7e1b8
ed7e1b8
  • Rápido: alta performance, equivalente a NodeJS e Go (graças ao Starlette e
ed7e1b8
    Pydantic). Um dos frameworks mais rápidos disponíveis.
ed7e1b8
  • Rápido para codar: Aumenta a velocidade para desenvolver recursos entre
ed7e1b8
    200% a 300%.*
ed7e1b8
  • Poucos bugs: Reduz cerca de 40% de erros induzidos por humanos
ed7e1b8
    (desenvolvedores).*
ed7e1b8
  • Intuitivo: Grande suporte a IDEs. Auto-Complete em todos os lugares. Menos
ed7e1b8
    tempo debugando.
ed7e1b8
  • Fácil: Projetado para ser fácil de aprender e usar. Menos tempo lendo
ed7e1b8
    documentação.
ed7e1b8
  • Enxuto: Minimize duplicação de código. Múltiplos recursos para cada
ed7e1b8
    declaração de parâmetro. Menos bugs.
ed7e1b8
  • Robusto: Tenha código pronto para produção. E com documentação interativa
ed7e1b8
    automática.
ed7e1b8
  • Baseado em padrões: Baseado em (e totalmente compatível com) os padrões
ed7e1b8
    abertos para APIs: OpenAPI (anteriormente conhecido como Swagger) e JSON
ed7e1b8
    Schema.
ed7e1b8
ed7e1b8
* estimativas baseadas em testes realizados com equipe interna de
ed7e1b8
  desenvolvimento, construindo aplicações em produção.}
9af288a
%global common_description_ru %{expand:
9af288a
FastAPI — это современный, быстрый (высокопроизводительный) веб-фреймворк для
e18f2cb
создания API используя Python 3.7+, в основе которого лежит стандартная
9af288a
аннотация типов Python.
9af288a
9af288a
Ключевые особенности:
9af288a
9af288a
  • Скорость: Очень высокая производительность, на уровне NodeJS и Go
9af288a
    (благодаря Starlette и Pydantic). Один из самых быстрых фреймворков Python.
9af288a
  • Быстрота разработки: Увеличьте скорость разработки примерно на 200–300%.*
9af288a
  • Меньше ошибок: Сократите примерно на 40% количество ошибок, вызванных
9af288a
    человеком (разработчиком).*
9af288a
  • Интуитивно понятный: Отличная поддержка редактора. Автозавершение везде.
9af288a
    Меньше времени на отладку.
9af288a
  • Лёгкость: Разработан так, чтобы его было легко использовать и осваивать.
9af288a
    Меньше времени на чтение документации.
9af288a
  • Краткость: Сведите к минимуму дублирование кода. Каждый объявленный
9af288a
    параметр - определяет несколько функций. Меньше ошибок.
9af288a
  • Надежность: Получите готовый к работе код. С автоматической интерактивной
9af288a
    документацией.
9af288a
  • На основе стандартов: Основан на открытых стандартах API и полностью
9af288a
    совместим с ними: OpenAPI (ранее известном как Swagger) и JSON Schema.
9af288a
9af288a
* оценка на основе тестов внутренней команды разработчиков, создающих
9af288a
  производственные приложения.}
ed7e1b8
%global common_description_tr %{expand:
e18f2cb
FastAPI, Python 3.7+'nın standart type hintlerine dayanan modern ve hızlı
ed7e1b8
(yüksek performanslı) API'lar oluşturmak için kullanılabilecek web framework'ü.
ed7e1b8
ed7e1b8
Ana özellikleri:
ed7e1b8
ed7e1b8
  • Hızlı: çok yüksek performanslı, NodeJS ve Go ile eşdeğer seviyede
ed7e1b8
  performans sağlıyor, (Starlette ve Pydantic sayesinde.) Python'un en hızlı
ed7e1b8
  frameworklerinden bir tanesi.
ed7e1b8
75925fc
  • Kodlaması hızlı: Yeni özellikler geliştirmek neredeyse %200 - %300 daha
75925fc
    hızlı.*
ed7e1b8
  • Daha az bug: Geliştirici (insan) kaynaklı hatalar neredeyse %40 azaltıldı.*
ed7e1b8
  • Sezgileri güçlü: Editor (otomatik-tamamlama) desteği harika. Otomatik
ed7e1b8
    tamamlama her yerde. Debuglamak ile daha az zaman harcayacaksınız.
ed7e1b8
  • Kolay: Öğrenmesi ve kullanması kolay olacak şekilde. Doküman okumak için
ed7e1b8
    harcayacağınız süre azaltıldı.
ed7e1b8
  • Kısa: Kod tekrarını minimuma indirdik. Fonksiyon parametrelerinin tiplerini
ed7e1b8
    belirtmede farklı yollar sunarak karşılaşacağınız bug'ları azalttık.
ed7e1b8
  • Güçlü: Otomatik dokümantasyon ile beraber, kullanıma hazır kod yaz.
ed7e1b8
  • Standartlar belirli: Tamamiyle API'ların açık standartlara bağlı ve (tam
ed7e1b8
    uyumlululuk içerisinde); OpenAPI (eski adıyla Swagger) ve JSON Schema.
ed7e1b8
ed7e1b8
* Bahsi geçen rakamsal ifadeler tamamiyle, geliştirme takımının kendi
ed7e1b8
  sundukları ürünü geliştirirken yaptıkları testlere dayanmakta.}
ed7e1b8
%global common_description_zh %{expand:
e18f2cb
FastAPI 是一个用于构建 API 的现代、快速(高性能)的 web 框架,使用 Python 3.7+
ed7e1b8
并基于标准的 Python 类型提示。
ed7e1b8
ed7e1b8
关键特性:
ed7e1b8
ed7e1b8
  • 快速:可与 NodeJS 和 Go 比肩的极高性能(归功于 Starlette 和 Pydantic)。
ed7e1b8
    最快的 Python web 框架之一。
ed7e1b8
  • 高效编码:提高功能开发速度约 200% 至 300%。*
ed7e1b8
  • 更少 bug:减少约 40% 的人为(开发者)导致错误。*
ed7e1b8
  • 智能:极佳的编辑器支持。处处皆可自动补全,减少调试时间。
ed7e1b8
  • 简单:设计的易于使用和学习,阅读文档的时间更短。
ed7e1b8
  • 简短:使代码重复最小化。通过不同的参数声明实现丰富功能。bug 更少。
ed7e1b8
  • 健壮:生产可用级别的代码。还有自动生成的交互式文档。
ed7e1b8
  • 标准化:基于(并完全兼容)API 的相关开放标准:OpenAPI (以前被称为 Swagger)
ed7e1b8
    和 JSON Schema。
ed7e1b8
ed7e1b8
* 根据对某个构建线上应用的内部开发团队所进行的测试估算得出。}
ed7e1b8
ed7e1b8
%description %{common_description_en}
ed7e1b8
ed7e1b8
%description -l en %{common_description_en}
ed7e1b8
%description -l es %{common_description_es}
46d6976
%description -l fr %{common_description_fr}
ed7e1b8
%description -l he %{common_description_he}
ed7e1b8
%description -l ja %{common_description_ja}
ed7e1b8
%description -l ko %{common_description_ko}
ed7e1b8
%description -l pl %{common_description_pl}
ed7e1b8
%description -l pt %{common_description_pt}
9af288a
%description -l ru %{common_description_ru}
ed7e1b8
%description -l tr %{common_description_tr}
ed7e1b8
%description -l zh %{common_description_zh}
ed7e1b8
ed7e1b8
ed7e1b8
%pyproject_extras_subpkg -n python3-fastapi all
ed7e1b8
ed7e1b8
ed7e1b8
%package -n     python3-fastapi
ed7e1b8
Summary:        %{sum_en}
ed7e1b8
ed7e1b8
Summary(en):    %{sum_en}
ed7e1b8
Summary(es):    %{sum_es}
46d6976
Summary(fr):    %{sum_fr}
ed7e1b8
Summary(he):    %{sum_he}
ed7e1b8
Summary(ja):    %{sum_ja}
ed7e1b8
Summary(ko):    %{sum_ko}
ed7e1b8
Summary(pl):    %{sum_pl}
ed7e1b8
Summary(pt):    %{sum_pt}
9af288a
Summary(ru):    %{sum_ru}
ed7e1b8
Summary(tr):    %{sum_tr}
ed7e1b8
Summary(zh):    %{sum_zh}
ed7e1b8
ed7e1b8
%description -n python3-fastapi %{common_description_en}
ed7e1b8
ed7e1b8
%description -n python3-fastapi -l en %{common_description_en}
ed7e1b8
%description -n python3-fastapi -l es %{common_description_es}
46d6976
%description -n python3-fastapi -l fr %{common_description_fr}
ed7e1b8
%description -n python3-fastapi -l he %{common_description_he}
ed7e1b8
%description -n python3-fastapi -l ja %{common_description_ja}
ed7e1b8
%description -n python3-fastapi -l ko %{common_description_ko}
ed7e1b8
%description -n python3-fastapi -l pl %{common_description_pl}
ed7e1b8
%description -n python3-fastapi -l pt %{common_description_pt}
9af288a
%description -n python3-fastapi -l ru %{common_description_ru}
ed7e1b8
%description -n python3-fastapi -l tr %{common_description_tr}
ed7e1b8
%description -n python3-fastapi -l zh %{common_description_zh}
ed7e1b8
ed7e1b8
ed7e1b8
%prep
ed7e1b8
%autosetup -n fastapi-%{version} -p1
ed7e1b8
ed7e1b8
# Comment out test dependencies that are only for linting/formatting/analysis,
59aeb9f
# and will not be used.
59aeb9f
#
ed7e1b8
# We won’t be running a type checker (mypy), so we don’t need any
59aeb9f
# auto-generated PEP 561 stub packages.
59aeb9f
#
59aeb9f
# Dependency generation does not support -e, and we will generate the
59aeb9f
# install-time dependencies without it.
59aeb9f
sed -r \
59aeb9f
    -e 's/^(mypy|black|ruff|coverage)\b/# &/' \
59aeb9f
    -e 's/^(types-(u|or)json)\b/# &/' \
59aeb9f
    -e 's/^(-e .)$/# &/' \
59aeb9f
    requirements-tests.txt | tee requirements-tests-filtered.txt
898c2f3
ed7e1b8
# Remove bundled js-termynal 0.0.1; since we are not building documentation, we
ed7e1b8
# do this very bluntly:
ed7e1b8
rm -rvf docs/*/docs/js docs/*/docs/css
ed7e1b8
ed7e1b8
ed7e1b8
%generate_buildrequires
59aeb9f
%pyproject_buildrequires -x all requirements-tests-filtered.txt
ed7e1b8
ed7e1b8
ed7e1b8
%build
ed7e1b8
%pyproject_wheel
ed7e1b8
ed7e1b8
ed7e1b8
%install
ed7e1b8
%pyproject_install
5bccd2d
%pyproject_save_files -l fastapi
ed7e1b8
ed7e1b8
ed7e1b8
%check
a8aee0d
# Ignore all DeprecationWarning messages, as they pop up from various
a8aee0d
# dependencies in practice. Upstream deals with this by tightly controlling
a8aee0d
# dependency versions in CI.
9dcceb8
%pytest -W 'ignore::DeprecationWarning' -k "${k-}"
ed7e1b8
ed7e1b8
ed7e1b8
%files -n python3-fastapi -f %{pyproject_files}
ed7e1b8
%doc README.md
ed7e1b8
ed7e1b8
ed7e1b8
%changelog
ed7e1b8
%autochangelog