Skip to content

[17.0][FIX] currency_rate_update_xe: send User-Agent and raise on HTTP error - #218

Closed
shirashi3771 wants to merge 1 commit into
OCA:17.0from
APSL:17.0-mig-currency_rate_update_xe
Closed

shirashi3771 wants to merge 1 commit into
OCA:17.0from
APSL:17.0-mig-currency_rate_update_xe

Conversation

@shirashi3771

@shirashi3771 shirashi3771 commented May 19, 2026 •

Copy link
Copy Markdown

@OCA-git-bot OCA-git-bot added mod:currency_rate_update_xe Module currency_rate_update_xe series:17.0 labels May 19, 2026
@shirashi3771
shirashi3771 force-pushed the 17.0-mig-currency_rate_update_xe branch from d4d4ba0 to 5f1643e Compare May 19, 2026 08:33

@cubells cubells left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

👍

LGTM

Code review and test

@palomagrc93 palomagrc93 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@BernatObrador BernatObrador left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@pedrobaeza

Copy link
Copy Markdown
Member

Please put correct commit message and module name.

@peluko00 peluko00 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@miquelpascual miquelpascual left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM once you fix the commit and title

@shirashi3771 shirashi3771 changed the title [FIX] currency_rate_update_xent and raise on HTTP error [17.0][FIX] currency_rate_update_xe: send User-Agent and raise on HTTP error May 19, 2026
@shirashi3771
shirashi3771 force-pushed the 17.0-mig-currency_rate_update_xe branch from 5f1643e to 5d47152 Compare May 19, 2026 11:10
@shirashi3771

Copy link
Copy Markdown
Author

Now, it's possible to merge?
@mpascuall

@miquelpascual

Copy link
Copy Markdown

Now, it's possible to merge? @mpascuall

It looks good now, but I don't have permission to merge it. @pedrobaeza could you help us with that please?

@pedrobaeza pedrobaeza added this to the 17.0 milestone May 19, 2026
"GET",
url,
timeout=10,
headers={"User-Agent": "Mozilla/5.0"},

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Why faking the user agent?

# computes date_from = today - 1 day, producing one rate per day in
# the range — which is correct behaviour but makes this assertion
# depend on whether XE returns a rate for the past-day URL.
self.xe_provider.last_successful_run = self.today - relativedelta(days=1)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Instead of this, you can freeze the time for the tests.

@klodr klodr Jun 20, 2026 •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

@OCA-git-bot approve

@github-actions

Copy link
Copy Markdown

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days.
If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

@github-actions github-actions Bot added the stale PR/Issue without recent activity, it'll be soon closed automatically. label Oct 18, 2026
@victoralmau

Copy link
Copy Markdown
Member

Related #242

@pedrobaeza pedrobaeza closed this Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved mod:currency_rate_update_xe Module currency_rate_update_xe series:17.0 stale PR/Issue without recent activity, it'll be soon closed automatically.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants