Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FW][FIX] web: prevent owl patch before action from ActionSwiper is done #174825

Closed

Conversation

fw-bot
Copy link
Contributor

@fw-bot fw-bot commented Jul 29, 2024

Steps to reproduce

In 17.2:

  • Install calendar,hr_homeworking
  • Use the emulated mobile view from the devtools
  • Go to calendar
  • Swipe horizontally to change the displayed week

=> A crash occurs here

https://github.com/odoo/odoo/blob/saas-17.2/addons/hr_homeworking/static/src/calendar/common/calendar_common_renderer.js#L108

Cause of the issue

The AttendeeCalendarCommonRenderer is rendered before the data for the next week has been loaded.

This means that this.props.model.worklocations has no entry for the parsedDate.

Solution

Await the action before modifying the ActionSwiper state

opw-4047632

Forward-Port-Of: #173305

@robodoo
Copy link
Contributor

robodoo commented Jul 29, 2024

Pull request status dashboard

@fw-bot
Copy link
Contributor Author

fw-bot commented Jul 29, 2024

@hubvd @jpp-odoo cherrypicking of pull request #173305 failed.

stdout:

Auto-merging addons/web/static/src/core/action_swiper/action_swiper.js
CONFLICT (content): Merge conflict in addons/web/static/src/core/action_swiper/action_swiper.js

Either perform the forward-port manually (and push to this branch, proceeding as usual) or close this PR (maybe?).

In the former case, you may want to edit this PR message as well.

⚠️ after resolving this conflict, you will need to merge it via @robodoo.

More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port

@robodoo robodoo added forwardport This PR was created by @fw-bot conflict There was an error while creating this forward-port PR labels Jul 29, 2024
@C3POdoo C3POdoo added the OE the report is linked to a support ticket (opw-...) label Jul 29, 2024
@hubvd hubvd force-pushed the 17.0-16.0-opw-4047632-huvw-IJO6-fw branch from 1bffe7c to eacddbc Compare July 30, 2024 15:33
@C3POdoo C3POdoo requested review from a team, aab-odoo and Iucapad and removed request for a team July 30, 2024 15:35
Steps to reproduce
==================

In 17.2:
- Install calendar,hr_homeworking
- Use the emulated mobile view from the devtools
- Go to calendar
- Swipe horizontally to change the displayed week

=> A crash occurs here

https://github.com/odoo/odoo/blob/saas-17.2/addons/hr_homeworking/static/src/calendar/common/calendar_common_renderer.js#L108

Cause of the issue
==================

The `AttendeeCalendarCommonRenderer` is rendered before the data for the
next week has been loaded.

This means that `this.props.model.worklocations` has no entry for the
`parsedDate`.

Solution
========

Await the action before modifying the ActionSwiper state

opw-4047632

X-original-commit: 6565bdf
@hubvd hubvd force-pushed the 17.0-16.0-opw-4047632-huvw-IJO6-fw branch from eacddbc to bb9e80c Compare July 31, 2024 07:26
@hubvd
Copy link
Contributor

hubvd commented Jul 31, 2024

@robodoo r+

@robodoo robodoo closed this in 7568b6b Jul 31, 2024
@fw-bot fw-bot deleted the 17.0-16.0-opw-4047632-huvw-IJO6-fw branch August 14, 2024 11:46
Dasanchez1992 pushed a commit to Nosolotec/odoo that referenced this pull request Aug 22, 2024
Steps to reproduce
==================

In 17.2:
- Install calendar,hr_homeworking
- Use the emulated mobile view from the devtools
- Go to calendar
- Swipe horizontally to change the displayed week

=> A crash occurs here

https://github.com/odoo/odoo/blob/saas-17.2/addons/hr_homeworking/static/src/calendar/common/calendar_common_renderer.js#L108

Cause of the issue
==================

The `AttendeeCalendarCommonRenderer` is rendered before the data for the
next week has been loaded.

This means that `this.props.model.worklocations` has no entry for the
`parsedDate`.

Solution
========

Await the action before modifying the ActionSwiper state

opw-4047632

closes odoo#174825

X-original-commit: 6565bdf
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
riccardo-metrum pushed a commit to resultrum/odoo that referenced this pull request Sep 30, 2024
Steps to reproduce
==================

In 17.2:
- Install calendar,hr_homeworking
- Use the emulated mobile view from the devtools
- Go to calendar
- Swipe horizontally to change the displayed week

=> A crash occurs here

https://github.com/odoo/odoo/blob/saas-17.2/addons/hr_homeworking/static/src/calendar/common/calendar_common_renderer.js#L108

Cause of the issue
==================

The `AttendeeCalendarCommonRenderer` is rendered before the data for the
next week has been loaded.

This means that `this.props.model.worklocations` has no entry for the
`parsedDate`.

Solution
========

Await the action before modifying the ActionSwiper state

opw-4047632

closes odoo#174825

X-original-commit: 6565bdf
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conflict There was an error while creating this forward-port PR forwardport This PR was created by @fw-bot OE the report is linked to a support ticket (opw-...)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants