Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Remove custom exception handling#117

Merged
orangecms merged 1 commit intofossasia:developmentfossasia/pslab-python:developmentfrom
bessman:exception-handlingbessman/pslab-python:exception-handlingCopy head branch name to clipboard
Jun 13, 2020
Merged

Remove custom exception handling#117
orangecms merged 1 commit intofossasia:developmentfossasia/pslab-python:developmentfrom
bessman:exception-handlingbessman/pslab-python:exception-handlingCopy head branch name to clipboard

Conversation

@bessman
Copy link
Collaborator

@bessman bessman commented Jun 7, 2020

This PR removes the custom exception handling discussed in #115. It should not affect normal operation (with one exception, see below).

Additionally, it changes the behavior of ScienceLab.write_bulk_flash() by changing the indentation level if this block:

        # verification by readback
        tmp = [ord(a) for a in self.read_bulk_flash(location, len(data))]
        print('Verification done', tmp == data)
        if tmp != data: raise Exception('Verification by readback failed')

In the current version, this block will never be executed because it comes after a raise statement. This does not seem intentional, so I fixed it. I have not tested it, but since it does not write anything to the hardware it should be safe.

My IDE also autoremoved some trailing whitespace here and there throughout the code.

@bessman bessman requested review from CloudyPadmal and marcoag and removed request for marcoag June 7, 2020 15:52
@bessman
Copy link
Collaborator Author

bessman commented Jun 7, 2020

The Codacy quality issues are not really related to the changes introduces by this PR. I'd rather fix them in a separate PR at a later point.

@bessman bessman requested a review from marcoag June 13, 2020 15:17
@orangecms orangecms merged commit bbd02dd into fossasia:development Jun 13, 2020
@orangecms
Copy link
Contributor

The Codacy quality issues are not really related to the changes introduces by this PR. I'd rather fix them in a separate PR at a later point.

Looks like that came with #118. Should be fixed later. :)

@bessman bessman deleted the exception-handling branch August 10, 2020 07:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.