geospatial icon indicating copy to clipboard operation
geospatial copied to clipboard

[14.0][FIX]base_geoengine: missing sidebar

Open PicchiSeba opened this issue 1 year ago • 21 comments

I installed a fresh Odoo instance with the module fieldservice_geoengine (from OCA's field-service repo), added the geoengine view mode to the FSM Location action but the button didn't show up.

Screenshot from 2024-06-20 11-42-42

Opening up the browser console I was greeted by an error message stating that base_geoengine.GeoengineController couldn't be initialized because it was referencing web.Sidebar which was nowhere to be found.

After a bit of investigation I stumbled into this commit in Odoo 14.0 which essentially replaced web.Sidebar with web.ActionMenus.

We can verify this by reading the first comment in the newly added file

/** * Action menus (or Action/Print bar, previously called 'Sidebar') * * The side bar is the group of dropdown menus located on the left side of the * control panel. Its role is to display a list of items depending on the view * type and selected records and to execute a set of actions on active records. * It is made out of 2 dropdown menus: Print and Action. * * This component also provides a registry to use custom components in the ActionMenus's * Action menu. * @extends Component */

SOMEHOW running a clean runboat instance of the field-service repo and installing fieldservice_geoengine makes the geoengine action appear, but not on a local installation. I don't understand what's happening here.

Please let me know if you encountered this situation before or if I'm just hallucinating.

PicchiSeba avatar Jun 20 '24 09:06 PicchiSeba

Changes look good

anusriNPS avatar Jun 21 '24 07:06 anusriNPS

@lmignon @yvaucher

SOMEHOW running a clean runboat instance of the field-service repo and installing fieldservice_geoengine makes the geoengine action appear, but not on a local installation.

I finally found an answer to this mistery. Starting a Runboat instance for the field-service repo doesn't show any issue. Why is that? We can get a clue by installing the fieldservice_geoengine module which requires base_geoengine, and looking at the latter's version.

Screenshot from 2024-06-24 12-11-19

14.0.1.0.3? But if I inspect the manifest of base_geoengine module in this repo I see another version: 14.0.1.0.1 https://github.com/OCA/geospatial/blob/d9d9a3ba12a906ca42ddcf9ff28dc151946b4c32/base_geoengine/manifest.py#L6

This is because of a past event regarding missing history https://github.com/OCA/geospatial/pull/316#issuecomment-1410353162

The whole module was re-merged into 14.0 https://github.com/OCA/geospatial/pull/326

Because of this some of the changes are still buried in the branch 14.0-bad-history.

In the lost changes the base_geoengine was at the version 14.0.1.0.3, the same we have in the Runboat.

In the bad-history repo we have this line in particular, which makes the geoengine action behave correctly

https://github.com/OCA/geospatial/blob/2818cc74e44fdd2f849c56043638df468f2c7246/base_geoengine/static/src/js/views/geoengine/geoengine_controller.js#L22

We can see the same line if we add geoengine to the Fieldservice Location action

Screenshot from 2024-06-24 12-31-28

And then reload the page with debug=assets, if we explore the static files that loaded by the browser and inspect base_geoengine/static/src/js/views/geoengine/geoengine_controller.js we see the same line I previously highlighted (line 22).

Screenshot from 2024-06-24 12-34-42

I suspect that even though this repo has been fixed, the module in the Runboat doesn't update because its version is higher than what we have in the most recent 14.0 branch.

I guess we could increase the version number in order to achieve consistency. Let me know what you think.

PicchiSeba avatar Jun 24 '24 10:06 PicchiSeba

@PicchiSeba Thank you for the explanation. You could propose a PR with the missing part and we will merge it with a bump of the minor version. In this way we are sure that the one into pipy will be the lastest.

lmignon avatar Jun 26 '24 07:06 lmignon

@lmignon I updated this PR with the changes. I tested it with the fieldservice_geoengine module

PicchiSeba avatar Jun 26 '24 07:06 PicchiSeba

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

OCA-git-bot avatar Jun 26 '24 09:06 OCA-git-bot

/ocabot merge minor

lmignon avatar Jun 26 '24 09:06 lmignon

On my way to merge this fine PR! Prepared branch 14.0-ocabot-merge-pr-375-by-lmignon-bump-minor, awaiting test results.

OCA-git-bot avatar Jun 26 '24 09:06 OCA-git-bot

@lmignon your merge command was aborted due to failed check(s), which you can inspect on this commit of 14.0-ocabot-merge-pr-375-by-lmignon-bump-minor.

After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.

OCA-git-bot avatar Jun 26 '24 09:06 OCA-git-bot

@lmignon Some tests failed during the merge but I cannot see them.

PicchiSeba avatar Jun 26 '24 14:06 PicchiSeba

ping @OCA/geospatial-maintainers

marcelsavegnago avatar Aug 19 '24 13:08 marcelsavegnago

/ocabot merge minor

lmignon avatar Aug 26 '24 07:08 lmignon

Hey, thanks for contributing! Proceeding to merge this for you. Prepared branch 14.0-ocabot-merge-pr-375-by-lmignon-bump-minor, awaiting test results.

OCA-git-bot avatar Aug 26 '24 07:08 OCA-git-bot

@lmignon your merge command was aborted due to failed check(s), which you can inspect on this commit of 14.0-ocabot-merge-pr-375-by-lmignon-bump-minor.

After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.

OCA-git-bot avatar Aug 26 '24 07:08 OCA-git-bot

@lmignon your merge command was aborted due to failed check(s), which you can inspect on this commit of 14.0-ocabot-merge-pr-375-by-lmignon-bump-minor.

After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.

OCA-git-bot avatar Aug 26 '24 07:08 OCA-git-bot

@lmignon Is it necessary to do a rebase?

marcelsavegnago avatar Aug 27 '24 15:08 marcelsavegnago

Please try a rebase. This is really weird, I don't see any error in the 2 last attempts of merge.

yvaucher avatar Oct 17 '24 08:10 yvaucher

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[bot] avatar Feb 16 '25 12:02 github-actions[bot]

/ocabot merge minor

yvaucher avatar Jul 23 '25 16:07 yvaucher

On my way to merge this fine PR! Prepared branch 14.0-ocabot-merge-pr-375-by-yvaucher-bump-minor, awaiting test results.

OCA-git-bot avatar Jul 23 '25 16:07 OCA-git-bot

@yvaucher your merge command was aborted due to failed check(s), which you can inspect on this commit of 14.0-ocabot-merge-pr-375-by-yvaucher-bump-minor.

After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.

OCA-git-bot avatar Jul 23 '25 16:07 OCA-git-bot

@yvaucher your merge command was aborted due to failed check(s), which you can inspect on this commit of 14.0-ocabot-merge-pr-375-by-yvaucher-bump-minor.

After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red.

OCA-git-bot avatar Jul 23 '25 16:07 OCA-git-bot

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[bot] avatar Nov 30 '25 12:11 github-actions[bot]