Merge modifications for more separate backend functions #69

Open
kscheidecker wants to merge 39 commits from backend/micro-services-restructuring into main
Owner
No description provided.
kscheidecker added 1 commit 2025-06-21 16:54:48 +00:00
added more structure
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 3m29s
Run linting on the backend code / Build (pull_request) Successful in 27s
Run testing on the backend code / Build (pull_request) Failing after 12m29s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 34s
6921ab57f8
kscheidecker added 1 commit 2025-06-22 12:24:07 +00:00
working split
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m46s
Run linting on the backend code / Build (pull_request) Successful in 2m31s
Run testing on the backend code / Build (pull_request) Failing after 12m37s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 29s
e2d3d29956
kscheidecker added 1 commit 2025-07-02 19:58:53 +00:00
fixed typo in invalid inputs
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 2m24s
Run linting on the backend code / Build (pull_request) Successful in 27s
Run testing on the backend code / Build (pull_request) Failing after 20m39s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 32s
37926e68ec
kscheidecker added 1 commit 2025-07-02 19:59:15 +00:00
simplified test pipeline
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m38s
Run linting on the backend code / Build (pull_request) Successful in 27s
Run testing on the backend code / Build (pull_request) Failing after 17m36s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 35s
54bc9028ad
kscheidecker added 1 commit 2025-07-13 15:44:27 +00:00
Implement backend API for landmarks, trip optimization, and toilet locations
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m49s
Run linting on the backend code / Build (pull_request) Successful in 30s
Run testing on the backend code / Build (pull_request) Failing after 45s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 32s
b0f9d31ee2
- Added landmarks_router.py to handle landmark retrieval based on user preferences and location.
- Implemented optimization_router.py for trip optimization, including handling preferences and landmarks.
- Created toilets_router.py to fetch toilet locations within a specified radius from a given location.
- Enhanced error handling and logging across all new endpoints.
- Generated a comprehensive report.html for test results and environment details.
kscheidecker added 1 commit 2025-07-13 15:45:19 +00:00
fixed dependcu
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 2m8s
Run linting on the backend code / Build (pull_request) Successful in 29s
Run testing on the backend code / Build (pull_request) Failing after 46s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 28s
d9e5d9dac6
kscheidecker added 1 commit 2025-07-13 15:47:28 +00:00
removed unused landmark attributes
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m39s
Run linting on the backend code / Build (pull_request) Successful in 31s
Run testing on the backend code / Build (pull_request) Failing after 49s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 38s
96b0718081
kscheidecker added 4 commits 2025-07-26 10:44:55 +00:00
changed to no dev when building the docker image
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 2m24s
Run linting on the backend code / Build (pull_request) Failing after 21s
Run testing on the backend code / Build (pull_request) Failing after 22m41s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 36s
132aa5a19b
kscheidecker added 1 commit 2025-07-27 15:13:20 +00:00
fixed the toilets and works with uv now
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m58s
Run linting on the backend code / Build (pull_request) Failing after 20s
Run testing on the backend code / Build (pull_request) Failing after 22m6s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 1m8s
9ccf68d983
kscheidecker added 1 commit 2025-07-27 15:22:55 +00:00
Added field validation for preferences
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m31s
Run linting on the backend code / Build (pull_request) Failing after 19s
Run testing on the backend code / Build (pull_request) Failing after 19m47s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 33s
c6bb0cddb7
kscheidecker added 3 commits 2025-07-27 16:18:34 +00:00
added supabase routes and payment handling
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m34s
Run linting on the backend code / Build (pull_request) Failing after 18s
Run testing on the backend code / Build (pull_request) Failing after 38s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 1m5s
e41d3f5e3a
kscheidecker added 1 commit 2025-07-27 16:27:55 +00:00
fixed linter
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m23s
Run linting on the backend code / Build (pull_request) Failing after 15s
Run testing on the backend code / Build (pull_request) Failing after 38s
Build and deploy the backend to staging / Deploy to staging (pull_request) Successful in 30s
89c95063dd
kscheidecker added 1 commit 2025-07-27 16:31:39 +00:00
fixed linter 4 real
Some checks failed
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been cancelled
Build and deploy the backend to staging / Build and push image (pull_request) Has been cancelled
Run testing on the backend code / Build (pull_request) Has been cancelled
Run linting on the backend code / Build (pull_request) Failing after 16s
44cd983fb8
kscheidecker added 1 commit 2025-07-27 16:32:30 +00:00
i am stoopid
Some checks failed
Run testing on the backend code / Build (pull_request) Has been cancelled
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been cancelled
Build and deploy the backend to staging / Build and push image (pull_request) Has been cancelled
Run linting on the backend code / Build (pull_request) Successful in 19s
bf8b64aacf
kscheidecker added 4 commits 2025-09-25 19:30:51 +00:00
used .env for supabase secrets
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 52s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 50s
Run testing on the backend code / Build (pull_request) Failing after 3m8s
b65d184f48
kscheidecker added 1 commit 2025-09-25 19:41:36 +00:00
moved the rest of endpoints to individual routers
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 5m45s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m57s
Run testing on the backend code / Build (pull_request) Failing after 4m6s
b201dfe97c
kscheidecker added 1 commit 2025-09-25 20:00:21 +00:00
added todo
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m42s
Run linting on the backend code / Build (pull_request) Successful in 3m12s
Run testing on the backend code / Build (pull_request) Failing after 3m20s
Build and deploy the backend to staging / Deploy to staging (pull_request) Failing after 29s
5549f8b0e5
remoll self-assigned this 2025-09-26 11:36:16 +00:00
remoll requested review from remoll 2025-09-26 11:36:25 +00:00
remoll removed their assignment 2025-09-26 11:36:26 +00:00
remoll reviewed 2025-09-26 12:54:56 +00:00
remoll left a comment
Owner

Payment logic is taking shape - exciting!

Payment logic is taking shape - exciting!
@@ -19,3 +19,3 @@
run: |
apt-get update && apt-get install -y python3 python3-pip
pip install pipenv
pip install uv
Owner

Using the uv action would be cleaner:

      - name: Install uv
        uses: astral-sh/setup-uv@v6
Using the uv action would be cleaner: ``` - name: Install uv uses: astral-sh/setup-uv@v6 ```
Owner
See https://docs.astral.sh/uv/guides/integration/github/#installation
Owner

Using this works in the backend_run_lint.yaml step as well. Just run uv run pylint ....

Using this works in the `backend_run_lint.yaml` step as well. Just run `uv run pylint ...`.
@@ -2,1 +1,4 @@
FROM python:3.12-slim-bookworm
# The installer requires curl (and certificates) to download the release archive
RUN apt-get update && apt-get install -y --no-install-recommends curl ca-certificates
Owner

Is this the way they do it at stadler? 😀
I prefer a different approach:

  1. use a minimal image: -alpine is enough
  2. Import files from the uv docker container - the package is already built there. No need to run the installer, no curl dependencies, etc...

The result looks something like:

# use python 3.12 as a base image
FROM docker.io/python:3.12-alpine
# use the latest version of uv, independently of the python version
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/

What do you think?

Is this the way they do it at stadler? 😀 I prefer a different approach: 1. use a minimal image: `-alpine` is enough 2. Import files from the `uv` docker container - the package is already built there. No need to run the installer, no curl dependencies, etc... The result looks something like: ``` # use python 3.12 as a base image FROM docker.io/python:3.12-alpine # use the latest version of uv, independently of the python version COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ ``` What do you think?
Author
Owner

Good idea. Changes implemented in commit fe1b42fff9

Good idea. Changes implemented in commit [fe1b42fff9](https://git.kluster.moll.re/anydev/anyway/commit/fe1b42fff918453f5e085907954b75c37ef4a22c)
kscheidecker marked this conversation as resolved
@@ -0,0 +7,4 @@
# Load variables from environment
load_dotenv(override=True)
Owner

I don't like this. Under no circumstances should this run in prod. For testing purposes the dotenv should be loaded by the user. E.g. through launch.json, or direnv.

I don't like this. Under no circumstances should this run in prod. For testing purposes the dotenv should be loaded by the user. E.g. through `launch.json`, or `direnv`.
Owner

This should be fixed by #70

This should be fixed by #70
@@ -0,0 +11,4 @@
@dataclass
class Environment :
Owner

I like this.

I like this.
kscheidecker marked this conversation as resolved
@@ -24,3 +23,3 @@
nature_coeff: float # coeff to adjust score of parks
overall_coeff: float # coeff to adjust weight of tags
n_important: int # number of important landmarks to consider
# n_important: int # number of important landmarks to consider
Owner

Be brave! Delete it

Be brave! Delete it
Author
Owner

Removed in commit 510aabcb0a

Removed in commit [510aabcb0a](https://git.kluster.moll.re/anydev/anyway/commit/510aabcb0a423b38114101a890aad87dc9417934)
kscheidecker marked this conversation as resolved
@@ -0,0 +104,4 @@
landmarks_around = manager.generate_landmarks_list(
center_coordinates = (lat, lon),
preferences = prefs,
allow_clusters=False,
Owner

should this be a landmark-parameter? No need to let the user choose that option. But it might be intersting to allow this to be set at runtime instead of hardcoding it.

should this be a landmark-parameter? No need to let the user choose that option. But it might be intersting to allow this to be set at runtime instead of hardcoding it.
Author
Owner

Also a good point! Implemented in commit bfc0c9adae

Also a good point! Implemented in commit [bfc0c9adae](https://git.kluster.moll.re/anydev/anyway/commit/bfc0c9adae3877d59f4127e94e2a4916d9072a7b)
kscheidecker marked this conversation as resolved
@@ -34,3 +34,3 @@
logging.getLogger('urllib3.connectionpool').setLevel(logging.WARNING)
# no need for time since it's added by loki or can be shown in kube logs
logging_format = '%(name)s - %(levelname)s - %(message)s'
logging_format = '%(name)-55s - %(levelname)-7s - %(message)s'
Owner

What does this do?

What does this do?
remoll marked this conversation as resolved
@@ -0,0 +52,4 @@
"description": self.details.description
}],
"redirect_urls": {
"return_url": "http://localhost:8000/payment/success",
Owner

Pretty sure that won't work. It should definitely not be hardcoded since the callback will change depending on prod or staging.

Pretty sure that won't work. It should definitely not be hardcoded since the callback will change depending on prod or staging.
remoll marked this conversation as resolved
@@ -94,0 +106,4 @@
start_coords: tuple[float, float] = None,
end_coords: tuple[float, float] = None,
):
def decorator(test_func):
Owner

what's going on here?

what's going on here?
kscheidecker added 1 commit 2025-10-02 11:59:11 +00:00
overhaul of paypal handler WIP
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 3m44s
Run linting on the backend code / Build (pull_request) Successful in 23s
Run testing on the backend code / Build (pull_request) Failing after 3m7s
Build and deploy the backend to staging / Deploy to staging (pull_request) Failing after 35s
3bdcdea850
kscheidecker added 1 commit 2025-10-05 14:13:15 +00:00
overhaul of paypal handler WIP
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 56s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 1m54s
Run testing on the backend code / Build (pull_request) Failing after 2m33s
f86174bc11
kscheidecker added 1 commit 2025-10-08 15:30:23 +00:00
strong base for payment handling
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 50s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run testing on the backend code / Build (pull_request) Failing after 2m32s
Run linting on the backend code / Build (pull_request) Successful in 2m39s
ab03cee3e3
kscheidecker added 1 commit 2025-10-08 15:31:52 +00:00
changed unit_price to float
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 6m14s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 1m50s
Run testing on the backend code / Build (pull_request) Failing after 4m1s
d374dc333f
kscheidecker added 1 commit 2025-10-08 15:34:29 +00:00
forgot the credits lol
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 48s
Run linting on the backend code / Build (pull_request) Successful in 3m9s
Run testing on the backend code / Build (pull_request) Failing after 1m59s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
29ac462725
kscheidecker added 1 commit 2025-10-09 12:41:18 +00:00
integrated supabase in payment process
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 1m13s
Run linting on the backend code / Build (pull_request) Successful in 3m9s
Run testing on the backend code / Build (pull_request) Failing after 2m32s
Build and deploy the backend to staging / Deploy to staging (pull_request) Failing after 35s
54f541382e
kscheidecker added 1 commit 2025-10-19 16:34:52 +00:00
added todo
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 3h0m47s
Run linting on the backend code / Build (pull_request) Successful in 3m24s
Run testing on the backend code / Build (pull_request) Failing after 2m46s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been cancelled
b4cac3a357
kscheidecker added 1 commit 2025-10-19 19:59:59 +00:00
changed the UV install step to implicit pull with binary copy
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 55s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m37s
Run testing on the backend code / Build (pull_request) Failing after 1m53s
fe1b42fff9
kscheidecker added 1 commit 2025-10-19 20:03:03 +00:00
cleaned up stale comments from before renovation
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 1m44s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 1m19s
Run testing on the backend code / Build (pull_request) Failing after 2m2s
510aabcb0a
kscheidecker added 1 commit 2025-10-19 20:05:48 +00:00
added the option to enable/disable the cluster search in get-nearby endpoint
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 59s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m7s
Run testing on the backend code / Build (pull_request) Failing after 56s
bfc0c9adae
kscheidecker added 1 commit 2025-10-19 20:10:20 +00:00
removed leftover decorator from before testing rework
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 2m2s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m37s
Run testing on the backend code / Build (pull_request) Failing after 3m16s
a884b9ee14
kscheidecker added 1 commit 2025-10-19 20:21:01 +00:00
more cleaning and added the url in API endpoint
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 1m59s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 46s
Run testing on the backend code / Build (pull_request) Failing after 2m46s
d9724ff07d
kscheidecker added 1 commit 2025-10-19 21:22:48 +00:00
better endpoint for payments
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 51s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 3m8s
Run testing on the backend code / Build (pull_request) Failing after 3m56s
9c930996c7
kscheidecker added 1 commit 2025-10-19 21:29:07 +00:00
better demonstrator
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 1m21s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m22s
Run testing on the backend code / Build (pull_request) Failing after 4m28s
51b7117c6d
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Failing after 1m21s
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been skipped
Run linting on the backend code / Build (pull_request) Successful in 2m22s
Run testing on the backend code / Build (pull_request) Failing after 4m28s
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin backend/micro-services-restructuring:backend/micro-services-restructuring
git checkout backend/micro-services-restructuring
Sign in to join this conversation.
No Reviewers
No Label
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anydev/anyway#69
No description provided.