Skip to content

Important bugfix for Python 3 ... - #138

Open
schoettl wants to merge 5 commits into
rstacruz:masterfrom
schoettl:master
Open

Important bugfix for Python 3 ...#138
schoettl wants to merge 5 commits into
rstacruz:masterfrom
schoettl:master

Conversation

@schoettl

Copy link
Copy Markdown

... and a few more fixes and enhancements.

Please see commits for details.

And thank you for this great tool!

It only had a problem in my environment (Python 3 on Arch) because command line options did not work, e.g. --no-last-newline. This is now fixed.

According to --help, no arguments are excepted. And arguments are
apperently also not processed.
The catch for "Reading failed." is not neccessary in my opinion.
If sparkup is used like
  sparkup < file
and file cannot be opened, the shell will give an error.
For sparkup itself, it should never be a problem to read from stdin.

Catching KeyboardInterrupt here was an error: the variable "lines" is used
later on and it will be undefined when Ctrl-C is pressed.

  ^CParse error. Check your input.
  <class 'UnboundLocalError'>
  local variable 'lines' referenced before assignment

I would just wrap the try-except for KeyboardInterrupt around the main
code.
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.

1 participant