Giter Club home page Giter Club logo

nougaro's Issues

[BUG] Tabs make `string_with_arrows` do weird stuff

Describe the bug
When you put a tab in incorrect code, the wrong positions are arrowed in error messages.

To Reproduce
Steps to reproduce the behavior:

  1. Type '(tab)foo'
  2. The arrows are not shown
  3. Type '(tab)foobar'
  4. The arrows are only under the 3 first characters

Expected behavior
The arrows should be under the whole text causing error

Screenshots
image

Your setup (please complete the following information):

  • OS: Ubuntu
  • OS version: 23.10 (Linux 6.5.0-21-generic)
  • Nougaro version: 0.17.0-beta (dev branch of 0.18.0-beta, commit 5312b29).

Code analysis
Line 51:53, file strings_with_arrows.py :

        # Append to result
        result += line + '\n'
        result += ' ' * col_start + '^' * (col_end - col_start)

Instead of spaces, a mix of tab and spaces depending on what’s on the line should be happened. But this could cause errors: just replacing the tabs by 4 spaces in the line could solve the problem.

Milestone: 0.18.0-beta

[BUG] in builtin functions, SymbolTable.get() tries to get symbol in parent if it doesn't exist

Evertyhing in title

To Reproduce
Steps to reproduce the behavior:

  1. Launch shell
  2. Execute test to demonstrate everything works fine
  3. Execute the calculator
  4. Do a calculation (the bug doesn't occur if you just exit without using the calculator)
  5. Exit the calculator then execute test again
  6. AssertionError

Expected behavior
It should not crash

Screenshots
screenshot

Your setup (please complete the following information):

  • OS: Android (termux)
  • Nougaro version: beta 0.13.1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.