Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob

A workaround to solve "Some boards and apps may be missing" in ModusToolbox

lock attach
Attachments are accessible only for community members.

A workaround to solve "Some boards and apps may be missing" in ModusToolbox

Charles_Lai
Moderator
Moderator
Moderator
500 replies posted 250 solutions authored 250 sign-ins

Note: This blog is DEPRECATED since better solutions are officially provided in KBA230953 - Offloading the Manifest Files of ModusToolbox. Read this blog for reference purpose only.

 

-----------------------------------------------------------------------------------------------------------------------------

 

Network connection problems to raw.githubusercontent.com could cause malfunctioning of ModusToolbox. In this case you may face the following issues:

 

  1. While trying to new a ModusToolbox IDE application, you see the blank list of Boad Support Package (BSP) shown below:
    pastedImage_0.png
    And you could also find a log message in Console saying:
    Unable to open file at http://github.com/cypresssemiconductorco/mtb-super-manifest/raw/v2.X/mtb-super-manifest.xml. Some boards and apps may be missing. Check the logfile for a detailed error message.
  2. While trying to launch Library Manager, you see the logs shown below:
    pastedImage_1.png

 

This is because ModusToolbox needs the manifest files (mtb-super-manifest.xml, etc.) at the very beginning to initiate the following download procedures. But the manifest file could be compromised because it is actually hosted in the domain raw.githubusercontent.com which could be restricted in some regions due to the report of customers.

 

Further investigation shows that, the manifest files are the only files that could face the impact of restrictions, and none of the following download procedures (i.e. the cloning operation of Git client) would be touched. So a workaround to quickly solve this issue is that we could merely "hijack" the requests of the manifest files of ModusToolbox and redirect them to the locally stored ones. ModusToolbox will then find the proper manifest files and conduct the following actions successfully.

 

Before other solutions (like a complete offline repo source is officially provided as a standalone supplement) come out, this should be the easiest way to bypass the filtering and restriction issue in case you can't use VPNs / Tunnels.

 

///////////////////////////////////////////////////////////////////////////////////////////

 

Here are the instructions of it:

 

a) Download and install Fiddler.

 

b) Download the attached file and unzip it to directory "C:\".

 

c) Open Fiddler, and then do the following:

  1. Find "AutoResponder" tab in the main window and click it.
  2. Click the checkboxes "Enable rules" and "Unmatched requests passthrough".
  3. Click the button "Import...". Then navigate to and choose the file "C:\test\rules.farx".
  4. The final settings should be the same as the screenshot shown below:
    pastedImage_3.png

 

d) Continue to setup Fiddler, in the following steps:

  1. Choose "Tools ==> Options" in the top menubar. Go to "HTTPS" tab in the pop-up dialogue, make sure "Capture HTTPS CONNECTs" and "Decrypt HTTPS traffic" is checked as shown below:
    pastedImage_9.png
    Then permit and fire the operations automatically generated by Fiddler, which is essential for Fiddler to "hijack" the request of HTTPS, using Man-In-The-Middle strategy. If it is interrupted, you can click the button "Actions" to recover from it.
  2. Then make sure the item "File ==> Capture traffic" in the top menubar is checked as shown below, making it a proxy server system-wide:
    pastedImage_10.png

 

e) Open ModusToolbox, then do the following:

  1. Open Preference dialogue by selecting "Window ==> Preference" in the top menu bar.
  2. Expand to "General => Network Connections" from the left menutree.
  3. In this tab, change "Active Provider" to "Native" and make sure the settings in this tab is like below:
    pastedImage_11.png
  4. Click "Apply and Close" to save properly.

 

f) It's all set and done. Use "New Application" or "Library Manager" in ModusToolbox as usual and the boards or BSPs can now be seen and cloned properly:
pastedImage_15.png

pastedImage_16.pngpastedImage_17.pngpastedImage_18.png

 

g) How to undo?

Simply quit Fiddler.

The proxy settings in your system will be restored then. It should be automatically undone by Fiddler after you quit it.

And Since ModusToolbox is set to use system proxy settings, it will always be consistent with the system changes.

 

///////////////////////////////////////////////////////////////////////////////////////////

 

Trouble-shooting:

 

If you are still facing problems, please double check the key work noted below:

  • Make sure no "HTTP_PROXY" or "HTTPS_PROXY" is set in system environment variables. These variables could compromise "git clone" phase. Please note that Git client must be able to access github.com directly and independently in this workaround. And If you changed or delete these variables, remember to re-open ModusToolbox to make it work.
  • The global gitconfig of Git client could also lead to exceptions. There are several ways to verify and change it but I suggest that you do it in ModusToolbox. Open "Windows ==> Preference" and navigate to "Team ==> Git ==> Configuration", and then make sure that you won't see something like this below:
    pastedImage_0.png
    And the best global gitconfig should be like this below (it would be best to add key http.sslVerify and https.sslVerify and set them to false):
    pastedImage_1.png
  • Make sure the attached file is unzipped to the exact directory "C:\" otherwise Fiddler won't be able to find the xml files (or your should make sure you change the rules in Fiddler properly and point it to your location).
  • Make sure the "Capture traffic" is checked in Fiddler to ensure that project-creator or library-manager can get the xml files, too (because they don't follow ModusToolbox preference but comply to system proxy settings).
  • Don't use "Manual" proxy settings in ModusToolbox preference but use "Native" instead, to avoid unexpected errors or troubles.
  • Make sure Fiddler is decoding HTTPS and redirecting request properly. For example, A Complete "New Application" action could produce the following records in Fiddler. Make sure that purple lines can be seen (which indicates that the request matches with AutoResponder's rules and is redirected). Then make sure that "HTTPS" can be found at column "Protocol" (which indicates HTTPS requests are properly decoded):pastedImage_21.png
952 Views
Authors