Skip to content

feat: Smart/Origin: ffcam livraison1#2205

Merged
eddy-geek merged 7 commits into
masterfrom
smart-origin/ffcam_livraison1
Jul 8, 2026
Merged

feat: Smart/Origin: ffcam livraison1#2205
eddy-geek merged 7 commits into
masterfrom
smart-origin/ffcam_livraison1

Conversation

@lgourdin

@lgourdin lgourdin commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Details:

  • Better navitia API and UT error handling
  • UT for stopareas and waypoint_stopareas
  • Additional guard in the refactored navitia script from fix: Reduce outage when updating public transport information #2102 that skips stopareas when the API didn't respect the max walking duration (see issue 2208 on S/O ticket platform)
  • Minor syntax changes

@codacy-production

codacy-production Bot commented Jul 3, 2026

Copy link
Copy Markdown

Not up to standards ⛔

🔴 Issues 1 minor

Alerts:
⚠ 1 issue (≤ 0 issues of at least minor severity)

Results:
1 new issue

Category Results
Documentation 1 minor

View in Codacy

🟢 Metrics 19 complexity · 2 duplication

Metric Results
Complexity 19
Duplication 2

View in Codacy

🟢 Coverage 94.80% diff coverage · +0.18% coverage variation

Metric Results
Coverage variation +0.18% coverage variation
Diff coverage 94.80% diff coverage

View coverage diff in Codacy

Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (6696cad) 21824 20126 92.22%
Head commit (ebaab6d) 21972 (+148) 20303 (+177) 92.40% (+0.18%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#2205) 173 164 94.80%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

(cherry picked from commit 93bebb80fdb59d386ceef810b2adec13521ce962)
@eddy-geek
eddy-geek merged commit 259a3dc into master Jul 8, 2026
11 of 12 checks passed
@eddy-geek
eddy-geek deleted the smart-origin/ffcam_livraison1 branch July 8, 2026 07:28

@Nayor Nayor left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK pour moi, juste 2 petits détail pour faciliter l'exploitation

elif not response.ok:
raise HTTPInternalServerError(
"Navitia API error: %d " % response.status_code
"unknown_error"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Il faudrait logger l'erreur quelque part non ?
Sinon ça va être impossible à débugger

if response.status_code == 401:
raise HTTPInternalServerError("Authentication error with Navitia API")
if response.status_code == 400:
raise HTTPBadRequest("invalid_param")

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idem, mettre le message d'erreur de la réponse pour mieux débugger

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants