Skip to content

e2e tutorial "Step 2 - Create Sentiment Service" fails with latest func cli version. #6417

@twoGiants

Description

@twoGiants

Expected Behavior

I expect to be able to execute all sub-steps of the e2e tutorial section 2 - Create Sentiment Service.

The generated template using the command func create -l python sentiment-analysis-app should look like the listing in "Step 1: Create a Knative Function template"

start/sentiment-analysis-app
├── func.yaml
├── .funcignore
├── .gitignore
├── requirements.txt
├── app.sh
├── test_func.py
├── README.md
├── Procfile
└── func.py

I expect to be able to replace the code in sentiment-analysis-app/func.py with the listing in "Step 2: Replace the generated code..."

I expect to be able to perform:

Actual Behavior

The generated function template which is shown in the docs is outdated and does not deploy when you run func deploy -b=s2i -v.

func create -l python sentiment-analysis-app generates this template:

> tree -a -L 2 sentiment-analysis-app
sentiment-analysis-app
├── .funcignore
├── function
│   ├── func.py
│   └── __init__.py
├── func.yaml
├── .gitignore
├── pyproject.toml
├── README.md
└── tests
    └── test_func.py

func.py is in sentiment-analysis-app/function/func.py.

sentiment-analysis-app/requirements.txt does not exist, now it is sentiment-analysis-app/pyproject.toml. The dependencies from the listing in "Step 3: Configure..." are not working with the new template.

sentiment-analysis-app/setup.py does not exist. This must happen in the start hook in the Function class in sentiment-analysis-app/function/func.py.

func deploy -b=s2i -v fails with build errors if one uses the listed code and dependencies.

Steps to Reproduce the Problem

  1. Setup environment as described in Environment Setup.
  2. Go to step 2 - Create Sentiment Service.

Additional Info

Additional context
Fedora 42

Install information:

  • Platform (GKE, IKS, AKS, etc.): Kind 0.30.0, k8 1.32.7, Docker Engine 28.4.0
  • Knative Version: Serving 1.19.6, Eventing 1.19.4, func v0.46.0

Metadata

Metadata

Assignees

Labels

kind/bugCategorizes issue or PR as related to a bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions