DesignLiquido / DesignLiquido/vscode

[Pituguês] problema ao importar a biblioteca "matematica"

Open
#82 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

pitugues problema
Dominant language
TypeScript
Stars
172
Forks
13
PR merge metrics
No merged PRs in 30d

Description

Descrição do problema

Ao tentar usar a função "raizQuadrada" da biblioteca "matematica" no Pituguês, o programa simplesmente é finalizado com a mensagem de fim da execução, sem fornecer qualquer erro ou aviso. Sendo executado em ambiente web, o programa apresenta o comportamento esperado.

Passos para reproduzir

  1. Execute o seguinte código:
mate = importar("matematica")
x1 = inteiro(leia("Digite a coordenada x do ponto 1: "))
y1 = inteiro(leia("Digite a coordenada y do ponto 1: "))
x2 = inteiro(leia("Digite a coordenada x do ponto 2: "))
y2 = inteiro(leia("Digite a coordenada y do ponto 2: "))

distancia = mate.raizQuadrada((x2 - x1) ^ 2 + (y2 - y1) ^ 2)
escreva("A distância entre os pontos é: " + distancia)

Captura de tela

No ambiente web, o código funciona corretamente, conforme mostrado na imagem abaixo:

Image

Porém, ao executar o mesmo código em um ambiente local, o programa é finalizado sem a interação com o usuário, conforme mostrado na imagem abaixo:

Image

Ambiente

  • Sistema Operacional: Windows 11
  • Versão do Delégua: 1.7.5

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the provided Pituguês code in the local VS Code environment on Windows 11 with Delégua 1.7.5, focusing on importar("matematica") and mate.raizQuadrada. Compare the local behavior with the web environment; the issue is done when local execution no longer exits silently and the example produces the expected result or a useful error.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.