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

Add .hpp to list of Uvision Exporter extensions #3010

Merged
merged 1 commit into from
Nov 9, 2016

Conversation

nuket
Copy link
Contributor

@nuket nuket commented Oct 13, 2016

Doing an export fails if .hpp files are included, this patch add it to the list of recognized extensions.

Log

mbed export -i UVISION5 -m NRF52_DK
Traceback (most recent call last):
  File "c:\mbed-project\mbed-os\tools\project.py", line 234, in <module>
    main()
  File "c:\mbed-project\mbed-os\tools\project.py", line 230, in main
    zip_proj=zip_proj, build_profile=profile)
  File "c:\mbed-project\mbed-os\tools\project.py", line 93, in export
    build_profile=build_profile, silent=silent)
  File "c:\mbed-project\mbed-os\tools\project_api.py", line 229, in export_project
    macros=macros)
  File "c:\mbed-project\mbed-os\tools\project_api.py", line 90, in generate_project_files
    exporter.generate()
  File "c:\mbed-project\mbed-os\tools\export\uvision\__init__.py", line 189, in generate
    'project_files': self.format_src(srcs),
  File "c:\mbed-project\mbed-os\tools\export\uvision\__init__.py", line 175, in format_src
    grouped[group] = [self.uv_file(src) for src in files]
  File "c:\mbed-project\mbed-os\tools\export\uvision\__init__.py", line 141, in uv_file
    type = self.file_types[ext.lower()]
KeyError: '.hpp'
[mbed] ERROR: "python" returned error code 1.
[mbed] ERROR: Command "python -u c:\mbed-project\mbed-os\tools\project.py -i uvision5 -m NRF52_DK --source ." in "c:\mbed-project"

@theotherjimmy
Copy link
Contributor

theotherjimmy commented Oct 13, 2016

I do have a question: is there line you modified now longer than 80?

@nuket
Copy link
Contributor Author

nuket commented Oct 13, 2016

Nope, it's 59 characters long.

Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

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

+1

@sg-
Copy link
Contributor

sg- commented Oct 13, 2016

@nuket What about IAR or other IDEs?

@nuket
Copy link
Contributor Author

nuket commented Oct 13, 2016

Unfortunately, I don't have a copy of IAR.

On October 13, 2016 18:17:36 Sam Grove [email protected] wrote:

@nuket What about IAR or other IDEs?

You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#3010 (comment)

@sg-
Copy link
Contributor

sg- commented Oct 13, 2016

OK - lets wait until someone can verify and add support there too. Point solutions make the maintenance of exporters really painful.

@theotherjimmy
Copy link
Contributor

I don't see this as a point solution: it modifies a dict that is a mapping that is only used in this one exporter type.

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 2, 2016

I had a look at this PR, tested locally ,reviewed all tools we support. This should be good to go.

Reasons:

  • .hpp is supported in our build API, thus tools should also be able to display it
  • all tools with this patch support .hpp - only uvision is special that requires this patch, the rest should work out of the box

LGTM

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 2, 2016

/morph export-build

@mbed-bot
Copy link

mbed-bot commented Nov 2, 2016

Result: ABORTED

Your command has finished executing! Here's what you wrote!

/morph export-build

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 3, 2016

/morph export-build

@mbed-bot
Copy link

mbed-bot commented Nov 3, 2016

Result: ABORTED

Your command has finished executing! Here's what you wrote!

/morph export-build

@bridadan
Copy link
Contributor

bridadan commented Nov 3, 2016

There's definitely an issue with uVision hanging during the exporter tests, I had to kill it again. I'll try it one more time but in the meantime I'll look into a patch.

/morph export-build

@mbed-bot
Copy link

mbed-bot commented Nov 3, 2016

Result: ABORTED

Your command has finished executing! Here's what you wrote!

/morph export-build

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 7, 2016

@bridadan any update? I dont see how this small change can break exporters, as I tested locally, we accept .hpp in the tools anyway.

@bridadan
Copy link
Contributor

bridadan commented Nov 7, 2016

@0xc0170 sorry for the delay in my response. The failure I mentioned has been present (but spurious) in the exporter tests for sometime now. A patch was merged recently that should help with the stability if it was in fact a problem with our tools and not an issue with uVision. I'll go ahead and restart the CI.

/morph export-build

@mbed-bot
Copy link

mbed-bot commented Nov 7, 2016

Result: ABORTED

Your command has finished executing! Here's what you wrote!

/morph export-build

@bridadan
Copy link
Contributor

bridadan commented Nov 7, 2016

There was a git issue with one of the machines so I unfortunately had to stop this build so mbed-os testing could become unblocked. Restarting now!

/morph export-build

@mbed-bot
Copy link

mbed-bot commented Nov 7, 2016

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph export-build

@theotherjimmy
Copy link
Contributor

Yea! that took way too long.

@sg- sg- merged commit e175f61 into ARMmbed:master Nov 9, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants