Changing Chromium's major version build fails

179 views
Skip to first unread message

Asesh Shrestha

unread,
May 23, 2018, 1:44:58 PM5/23/18
to Chromium-dev
We are having issues with Chomium 66.0.3359.181 so we have decided to go back to 64 but however we are just planning to increase minor version number of 64 to 66.1.3359.181. But after doing so I get these build errors: 

D:\workspace\workstream_browser\src>ninja -C out\Release_x64 mini_installer
ninja: Entering directory `out\Release_x64'
[2/12840] ACTION //components/policy:cloud_policy_code_generate(//build/toolchain/win:win_clang_x64)
FAILED: gen/components/policy/policy_constants.h gen/components/policy/policy_constants.cc gen/components/policy/cloud_policy_generated.cc gen/components/policy/proto/chrome_settings.proto gen/components/policy/proto/cloud_policy.proto gen/components/policy/risk_tag.h
D:/depot_tools/win_tools-2_7_6_bin/python/bin/python.exe ../../components/policy/tools/generate_policy_source.py --policy-constants-header=gen/components/policy/policy_constants.h --policy-constants-source=gen/components/policy/policy_constants.cc --chrome-settings-protobuf=gen/components/policy/proto/chrome_settings.proto --cloud-policy-protobuf=gen/components/policy/proto/cloud_policy.proto --cloud-policy-decoder=gen/components/policy/cloud_policy_generated.cc --app-restrictions-definition=gen/components/policy/app_restrictions.xml --risk-tag-header=gen/components/policy/risk_tag.h ../../chrome/VERSION win 0 ../../components/policy/resources/policy_templates.json
Traceback (most recent call last):
  File "../../components/policy/tools/generate_policy_source.py", line 1420, in <module>
    sys.exit(main())
  File "../../components/policy/tools/generate_policy_source.py", line 261, in main
    GenerateFile(opts.source_path, _WritePolicyConstantSource, sorted=True)
  File "../../components/policy/tools/generate_policy_source.py", line 256, in GenerateFile
    os, f, risk_tags)
  File "../../components/policy/tools/generate_policy_source.py", line 771, in _WritePolicyConstantSource
    schema_generator.GenerateAndCollectID(chrome_schema, 'root node')
  File "../../components/policy/tools/generate_policy_source.py", line 613, in GenerateAndCollectID
    index = self.Generate(schema, name)
  File "../../components/policy/tools/generate_policy_source.py", line 581, in Generate
    for key, subschema in sorted_properties ]
  File "../../components/policy/tools/generate_policy_source.py", line 613, in GenerateAndCollectID
    index = self.Generate(schema, name)
  File "../../components/policy/tools/generate_policy_source.py", line 557, in Generate
    if schema['items'].get('type', '') == 'string':
KeyError: 'items'
[11/12840] ACTION //content/common:mojo_bindings__generator(//build/toolchain/win:win_clang_x64)
ninja: build stopped: subcommand failed.

But the compilation will continue if I switch major version back to 64. So can someone give me a pointer on how to solve this issue? Thanks

PhistucK

unread,
May 23, 2018, 1:51:52 PM5/23/18
to Asesh Shrestha, Chromium-dev
So, just to verify, 66.1.3359.181 fails, 64.1.3359.181 works, right?

Anyway, it fails on something you probably do not need (policy stuff), so maybe try to remove that target somehow for now? If that does not work (I guess the generated file is needed), try to debug that Python script a bit.

PhistucK


”This email and any files transmitted with it may be confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the sender.”

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/51483f5b-6ca0-44df-907c-9bd3c1dfc94d%40chromium.org.

Asesh Shrestha

unread,
May 23, 2018, 2:09:27 PM5/23/18
to Chromium-dev, asesh.s...@cloudfactory.com
May I know what targets should I remove (policy stuff)?  and where should I find those policy data? I remember something like this in Omaha client too but it had something to do with odd/even number in versions.

Thanks

Harald Alvestrand

unread,
May 23, 2018, 2:34:10 PM5/23/18
to PhistucK, Asesh Shrestha, Chromium-dev
I think there are policies that say things like "after this version, do that" - if the code for "do that" isn't there in 64, we would expect this sort of error.
But creating version numbers that are going to be colliding with mainline Chromium versions but refer to very different codebases seems like a dangerous thing. Are you sure you want to do this?


On Wed, May 23, 2018 at 7:50 PM, PhistucK <phis...@gmail.com> wrote:
So, just to verify, 66.1.3359.181 fails, 64.1.3359.181 works, right?

Anyway, it fails on something you probably do not need (policy stuff), so maybe try to remove that target somehow for now? If that does not work (I guess the generated file is needed), try to debug that Python script a bit.

PhistucK

To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev+unsubscribe@chromium.org.

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/CABc02_%2BU%3Dey74PBPacgMtN3sEUcoT-YAHa1H8_j34NzatO1RZA%40mail.gmail.com.

Asesh Shrestha

unread,
May 23, 2018, 2:50:34 PM5/23/18
to Chromium-dev, phis...@gmail.com, asesh.s...@cloudfactory.com
Yes am sure we will do this. The reason we are planning to do this is because our workers are having issues in the Chromium 66.x while everything was working fine in 64.x. So to update their browser, we have no other choice but to move back to 64.x but increase the version number to 66.1.x so that we can push updates on their machines. May I know where should I modify to do this? If someone can pinpoint the location then I would really appreciate it.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev...@chromium.org.

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev...@chromium.org.

Greg Thompson

unread,
May 24, 2018, 5:02:15 AM5/24/18
to asesh.s...@cloudfactory.com, Chromium-dev, phis...@gmail.com
There's a reason that Chrome's installer on Windows blocks downgrades -- there is no guarantee that the files in a user's User Data directory can be read by an older version of Chrome. I can't resist mentioning that by packaging a build of Chromium 64 as 66, you are misleading your users and web sites (via the U-A string) as to what features and security vulnerabilities are present. If you must back up to 64, perhaps there is another way.

As an aside: have you reported whatever the breaking issue in 66 is? Is it something that can/should be fixed in the main Chromium repo?

Asesh Shrestha

unread,
May 24, 2018, 5:08:37 AM5/24/18
to Chromium-dev, asesh.s...@cloudfactory.com, phis...@gmail.com
Thanks a lot for replying. May I know another way to do so? I have been debugging that Python but I don't think am going any where. After 67 comes out, we will test with our clients' site again and if everything works as expected then we will upgrade to 67 but right now we don't have any option. 

No, we have not reported that issue on crbug and yes it should be fixed in the main Chromium repo. But that bug is not easy to replicate as we will have login to our client's site and then work to replicate it

Thanks again

Greg Thompson

unread,
May 24, 2018, 5:55:19 AM5/24/18
to asesh.s...@cloudfactory.com, Chromium-dev, phis...@gmail.com
You're planning to built 64-as-66 and then ship it to another party? Obviously, I'm not in your shoes and don't know anything about your business or your customers, so take this with whatever grains of salt you have laying around: shipping an M64 build as if it were M66 is a bad idea. I would not approve a CL that attempted to do this in an organization I worked in. But hey, that's just my opinion.

If you control install/update, can you script uninstalling 66 and then installing 64?

What platform(s) are you building for?

Asesh Shrestha

unread,
May 24, 2018, 6:03:24 AM5/24/18
to Chromium-dev, asesh.s...@cloudfactory.com, phis...@gmail.com
Our workers use our browser and ever since we started rolling out version 66.0.3359.181 they have been complaining a lot because of bugs. We replicated the same bugs in Chromium too. We control the installation and updating of our browser too cause we are using modified version of Omaha client and Omaha server too. We are building for Windows platform only.

Thanks

Greg Thompson

unread,
May 24, 2018, 6:16:36 AM5/24/18
to asesh.s...@cloudfactory.com, Chromium-dev, phis...@gmail.com
Chromium on Windows has a downgrade feature. Have a look at installer::master_preferences::kAllowDowngrade. To use it in your fleet, you would need to devise a way to ship a mini_installer to your machines and run it with --installerdata=PATH_TO_JSON where PATH_TO_JSON points to a master_preferences file containing the allow_downgrade property.

That aside, if they are your machines in your org, perhaps uninstall 66 then install 64 is the cleanest thing.

Asesh Shrestha

unread,
May 24, 2018, 6:24:46 AM5/24/18
to Chromium-dev, asesh.s...@cloudfactory.com, phis...@gmail.com
Thanks a lot. Rather than doing so we might just stop rolling out version 66 and then enable rolling out of version 64 instead to solve this issue. But we will take this as an option too.

Thanks again
Message has been deleted

Asesh Shrestha

unread,
Jul 9, 2018, 3:59:47 AM7/9/18
to Chromium-dev, asesh.s...@cloudfactory.com, phis...@gmail.com
Late post, I have managed to implement downgrade feature. I also had to bundle master_preferences file in mini installer and modify our Omaha server to support it. Here's that master_preferences file am using right now:

{
  "homepage": "http://www.google.com",
  "homepage_is_newtabpage": false,
  "browser": {
    "show_home_button": false
  },
  "session": {
    "restore_on_startup": 4,
    "startup_urls": [
    ]
  },
  "bookmark_bar": {
    "show_on_all_tabs": false
  },
  "sync_promo": {
    "show_on_first_run_allowed": false
  },
  "distribution": {
    "allow_downgrade": true,
    "import_bookmarks_from_file": "bookmarks.html",
    "import_bookmarks": true,
    "import_history": true,
    "import_home_page": true,
    "import_search_engine": true,
    "ping_delay": 60,
    "suppress_first_run_bubble": true,
    "do_not_create_desktop_shortcut": false,
    "do_not_create_quick_launch_shortcut": false,
    "do_not_launch_chrome": false,
    "do_not_register_for_update_launch": true,
    "make_chrome_default": true,
    "make_chrome_default_for_user": true,
    "suppress_first_run_default_browser_prompt": true,
    "system_level": true,
    "verbose_logging": true
  },
  "first_run_tabs": [
    "chrome://newtab"
  ]
}



When you pass --allow_downgrade --installerdata=master_preferences to mini installer/setup, it will look for this value: "allow_downgrade": true to downgrade. Unfortunately existing browser profile will be deleted and will create a new one so that profile error dialog box won't popup. 

Thanks again :)
Reply all
Reply to author
Forward
0 new messages