Giter Site home page Giter Site logo

enso-org / enso Goto Github PK

View Code? Open in Web Editor NEW
7.3K 87.0 316.0 78.68 MB

Hybrid visual and textual functional programming.

Home Page: https://enso.org

License: Apache License 2.0

Haskell 0.02% C++ 0.03% Scala 40.16% Batchfile 0.01% Java 25.39% Rust 11.02% Shell 0.04% Makefile 0.01% Python 0.45% JavaScript 0.87% HTML 0.37% Dockerfile 0.02% CSS 0.16% Roff 0.02% TypeScript 18.58% ANTLR 0.03% PowerShell 0.01% Vue 2.83%
visual language functional compiler hybrid enso textual interpreter rts jit

enso's People

Contributors

4e6 avatar adriley avatar akavel avatar akirathan avatar binarysoftware avatar dependabot[bot] avatar farmaazon avatar frizi avatar galin-enso avatar gregorytravis avatar hubertp avatar iamrecursion avatar indiv0 avatar jaroslavtulach avatar jdunkerley avatar kazcw avatar kesanov avatar kustosz avatar lolczak avatar michaelmauderer avatar mrflashaccount avatar mwu-tow avatar notdanilo avatar pablobuchu avatar procrat avatar radeusgd avatar s9ferech avatar somebody1234 avatar vitvakatu avatar wdanilo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

enso's Issues

Stdlib 1.0

This epic aims to capture all the tasks necessary to provide our users with a usable standard library.

The goals here are:

  • feature completeness: we want to support a sensible set of operations on numbers, text, lists and maps, including: checking for equality, converting to text, casting (e.g. 4.toReal) and so on.
  • consistency: the users have a right to expect certain consistency throughout the library, like every two objects of the same time being comparable (.equals) or show-able (within reason).
  • reliability: the core StdLib should be tested and fool-proof.

XML/HTML library

Rudimentary โ€“ just the most common parts of spec will do for now. We need parsing and generation of these.

Http client drops params passed in the URI

The following code:

Http.getJSON "http://example.com?foo=bar"

results in a request with empty param list. In order to pass any query params we need to write

defaultHttpRequest "http://example.com" . setParam "foo" (Just "bar") . perform . json

but we should be handling params coming from the URI too.

Parser does not work correctly with empty string

Lately when I was developing System library error from parser have occurred with this code:

import Std.HTTP
import Std.System

def main:
    putStr "luna"
    foo = Process "ls" (Empty . prepend "/Users/LJK/Desktop/") "" . readProcessWithExitCode
    putStr foo.toText```

Console output:
```luna: unsupported
CallStack (from HasCallStack):
  error, called at src/Luna/Syntax/Text/Parser/Parsing.hs:686:30 in luna-syntax-text-parser-0.2-FmYTGPSXj6D8zT6gDdHkTj:Luna.Syntax.Text.Parser.Parsing```

Debugging shows that if third argument of `Process` is not empty string or empty string in parenthesis it works correctly.

Gray-out all successors of a modified node

After a node is edited (its expression or connections changed) all the nodes that depend on its result should also be grayed-out. Their types are most probably invalid anyway and this way we get a clear indication as to which nodes have valid results and types, and which are being recomputed.

Parser error on number negation

Following code:

def main:
    powers 1 . take 100
def powers s:
    Prepend s (powers (-2*s))

Produces following error:

SomeParserException FIXME: prec not found between "#uminus#" and "*"
CallStack (from HasCallStack):
  error, called at src/Luna/Syntax/Text/Scope.hs:74:35 in luna-syntax-text-parser-0.2-EhiUrnuqfI18wmiz5Qdsxa:Luna.Syntax.Text.Scope

While this code works correctly:

def main:
    powers 1 . take 100
def powers s:
    Prepend s (powers ((-2)*s))

Uncaught TypeError: parsed.forEach is not a function

Steps to reproduce:

  1. Download Luna installer
  2. Run Luna installer
  3. Run /Applications/LunaStudio.app
  4. In Private section, click on plus sign to create a project

Atom: 1.18.0 x64
Electron: 1.3.15
OS: Mac OS X 10.13.1
Thrown From: luna-studio package 1.0.0

Stack Trace

Uncaught TypeError: parsed.forEach is not a function

At /Users/yigitozkavci/.luna/config/luna-studio/1.0/atom/packages/luna-studio/lib/projects.coffee:160

TypeError: parsed.forEach is not a function
    at Request._callback (/packages/luna-studio/lib/projects.coffee:160:32)
    at Request.self.callback (/packages/settings-view/node_modules/request/request.js:186:22)
    at emitTwo (events.js:106:13)
    at Request.emit (events.js:191:7)
    at /packages/settings-view/node_modules/request/request.js:1163:10)
    at emitOne (events.js:96:13)
    at Request.emit (events.js:188:7)
    at /packages/settings-view/node_modules/request/request.js:1085:12)
    at IncomingMessage.g (events.js:286:16)
    at emitNone (events.js:91:20)
    at IncomingMessage.emit (events.js:185:7)
    at endReadableNT (_stream_readable.js:974:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)

Commands

  3x -1:16.2.0 dev-live-reload:reload-all (atom-workspace.workspace.scrollbars-visible-when-scrolling)
     -0:09.9.0 tree-view:show (atom-workspace.workspace.scrollbars-visible-when-scrolling.theme-luna-syntax.theme-luna-dark-ui)

Non-Core Packages

advanced-open-file 0.16.6 
busy-signal 1.4.3 
color-picker 2.2.5 
column-select 0.2.0 
cursor-history 0.11.1 
custom-window-title 1.0.4 
file-icons 2.1.11 
git-blame 1.2.2 
git-history 3.3.0 
git-log 0.4.1 
git-plus 7.9.3 
hasklig 0.4.0 
highlight-line 0.12.0 
highlight-selected 0.13.1 
intentions 1.1.5 
language-gitignore 0.3.0 
language-haskell 1.13.2 
luna-dark-ui 0.1.1 
luna-dpi 0.1.2 
luna-studio 1.0.0 
luna-syntax 0.1.0 
minimap 4.29.6 
minimap-codeglance 0.4.7 
minimap-cursorline 0.2.0 
minimap-find-and-replace 4.5.2 
minimap-git-diff 4.3.1 
minimap-highlight-selected 4.6.1 
multi-cursor 2.1.5 
sort-lines 0.14.0 
split-diff 1.5.0 
web-view 3.0.0 

Case for luna laziness problem

I have suspicion that in some cases luna is not lazy when we really need it to be. Console version of luna hangs on following code (I haven't tested it in luna studio):

import Std.Base
import Std.HTTP
import Std.System

def main:
    putStr (powers 1 . take 10 . toText)

def powers s:
    Prepend s (powers ((-2)*s))

Parser errors should contain line number

At the very least: Ideally they would tell you (natural language) what's wrong with the code.

Right now the numbers are very misleading: I expected them to be line/column numbers but I quickly found out they are not that :D

Report HTTP library errors in luna

Things like HTTP timeouts, TLS errors or even invalid urls (just try Http.getJSON "someurl") are displayed in the console instead of being passed to Luna. We need them inside our own error monad.

Broken Assumptions Resolution when Defining Methods

This is a curious case, probably resulting from broken resolution of CurrentTarget in Luna typechecker. This code:

class Complex:
    real :: Real
    imag :: Real
    def + that:
        Complex (self.real + that.real) (self.imag + that.imag)

yields compile errors whenever addition on complex numbers is used. Errors suggest that the TC is messing reals and complex numbers together. Everything works fine when the + definition is changed to explicit use of method instead of the operator wrapper:

def + that:
    Complex (self.real.+ that.real) (self.imag.+ that.imag)

Interestingly enough, this only happens when the operator used in body is the same as one currently being defined (i.e. using the operator * inside definition of + method works fine. And it breaks when using * in the definition of *, but + works fine there).

Parser does not parse defs after an empty class correctly

With this code:

class Foo:
    Foo Bool

def main:
    putStr "hello world!"

the function main is parsed as a method of class Foo, not a module-level definition. This is fixed when we add any methods inside Foo โ€“ this code parses correctly:

class Foo:
    Foo Bool
    def dummy: None

def main:
    putStr "hello world!"

Uncaught TypeError on Opening LunaStudio

How to reproduce

  1. Install LunaStudio on Mac
  2. Open it for the first time and click new project

Atom: 1.18.0 x64
Electron: 1.3.15
OS: Mac OS X 10.12.6
Thrown From: luna-studio package 1.0.0

Stack Trace

Uncaught TypeError: parsed.forEach is not a function

At /Users/saltzm/.luna/config/luna-studio/1.0/atom/packages/luna-studio/lib/projects.coffee:160

TypeError: parsed.forEach is not a function
    at Request._callback (/packages/luna-studio/lib/projects.coffee:160:32)
    at Request.self.callback (/packages/settings-view/node_modules/request/request.js:186:22)
    at emitTwo (events.js:106:13)
    at Request.emit (events.js:191:7)
    at /packages/settings-view/node_modules/request/request.js:1163:10)
    at emitOne (events.js:96:13)
    at Request.emit (events.js:188:7)
    at /packages/settings-view/node_modules/request/request.js:1085:12)
    at IncomingMessage.g (events.js:286:16)
    at emitNone (events.js:91:20)
    at IncomingMessage.emit (events.js:185:7)
    at endReadableNT (_stream_readable.js:974:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)

Commands

  3x -0:46.5.0 dev-live-reload:reload-all (atom-workspace.workspace.scrollbars-visible-when-scrolling)
     -0:17 tree-view:show (atom-workspace.workspace.scrollbars-visible-when-scrolling.theme-luna-syntax.theme-luna-dark-ui)

Non-Core Packages

advanced-open-file 0.16.6 
busy-signal 1.4.3 
color-picker 2.2.5 
column-select 0.2.0 
cursor-history 0.11.1 
custom-window-title 1.0.4 
file-icons 2.1.11 
git-blame 1.2.2 
git-history 3.3.0 
git-log 0.4.1 
git-plus 7.9.3 
hasklig 0.4.0 
highlight-line 0.12.0 
highlight-selected 0.13.1 
intentions 1.1.5 
language-gitignore 0.3.0 
language-haskell 1.13.2 
luna-dark-ui 0.1.1 
luna-dpi 0.1.2 
luna-studio 1.0.0 
luna-syntax 0.1.0 
minimap 4.29.6 
minimap-codeglance 0.4.7 
minimap-cursorline 0.2.0 
minimap-find-and-replace 4.5.2 
minimap-git-diff 4.3.1 
minimap-highlight-selected 4.6.1 
multi-cursor 2.1.5 
sort-lines 0.14.0 
split-diff 1.5.0 
web-view 3.0.0 

Wrong suggestions for methods named the same as functions

How to reproduce:
Say we have a node n with an instance of a List class, which exposes the average method. Incidentally, this is also a function taking a Stream, defined in the same file (Std.Base).

Now, when we click on the node with the list and hit "Tab" -> ". average" -> "Enter" we expect the resulting expression to be n . average. However, we end up with average n, which is nonsensical type- and sematics- wise.

Allowing comments to be hidden in docs.

# not a docstring at all, just a comment for the devs using this private function
def _foo a b:
    a + b

I would expect code like this to work just fine: it's a comment, not a docstring (I don't want it to be one).

Improve Time library for Luna

  1. Add conversions between epoch ints and internal Time.
  2. Add helper methods like Time.beginningOfDay, Time.endOfYear etc.
  3. Add helpers for creating hours, days, possibly more, TimeIntervals.
  4. Add printing Time with a given format.
  5. The most devilish of them all: some rudimentary support for timezones is needed.

Can I use luna with c9.io?

I use c9.io for my projects. And c9.io doesn't have possibility to use Luna visually.

Can I use luna compiler in terminal mode only? c9.io uses Ubuntu LTS.

parser error at startup

[Enter steps to reproduce:]

  1. Start up 1.0 beta
  2. Create new private project

Atom: 1.18.0 x64
Electron: 1.3.15
OS: Mac OS X 10.13.2
Thrown From: luna-studio package 1.0.0

Stack Trace

Uncaught TypeError: parsed.forEach is not a function

At /Users/viraptor/.luna/config/luna-studio/1.0/atom/packages/luna-studio/lib/projects.coffee:160

TypeError: parsed.forEach is not a function
    at Request._callback (/packages/luna-studio/lib/projects.coffee:160:32)
    at Request.self.callback (/packages/settings-view/node_modules/request/request.js:186:22)
    at emitTwo (events.js:106:13)
    at Request.emit (events.js:191:7)
    at /packages/settings-view/node_modules/request/request.js:1163:10)
    at emitOne (events.js:96:13)
    at Request.emit (events.js:188:7)
    at /packages/settings-view/node_modules/request/request.js:1085:12)
    at IncomingMessage.g (events.js:286:16)
    at emitNone (events.js:91:20)
    at IncomingMessage.emit (events.js:185:7)
    at endReadableNT (_stream_readable.js:974:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)

Commands

  3x -3:26.6.0 dev-live-reload:reload-all (atom-workspace.workspace.scrollbars-visible-when-scrolling)
     -1:46.4.0 tree-view:show (atom-workspace.workspace.scrollbars-visible-when-scrolling.theme-luna-syntax.theme-luna-dark-ui)

Non-Core Packages

advanced-open-file 0.16.6 
busy-signal 1.4.3 
color-picker 2.2.5 
column-select 0.2.0 
cursor-history 0.11.1 
custom-window-title 1.0.4 
file-icons 2.1.11 
git-blame 1.2.2 
git-history 3.3.0 
git-log 0.4.1 
git-plus 7.9.3 
hasklig 0.4.0 
highlight-line 0.12.0 
highlight-selected 0.13.1 
intentions 1.1.5 
language-gitignore 0.3.0 
language-haskell 1.13.2 
luna-dark-ui 0.1.1 
luna-dpi 0.1.2 
luna-studio 1.0.0 
luna-syntax 0.1.0 
minimap 4.29.6 
minimap-codeglance 0.4.7 
minimap-cursorline 0.2.0 
minimap-find-and-replace 4.5.2 
minimap-git-diff 4.3.1 
minimap-highlight-selected 4.6.1 
multi-cursor 2.1.5 
sort-lines 0.14.0 
split-diff 1.5.0 
web-view 3.0.0 

Luna studion

[Enter steps to reproduce:]

  1. Download Luna installer
  2. Run installer
  3. Run .luna/bin/luna-studio/current/luna-studio
  4. Message says "Downloading Tutorials" but never completes
  5. Expanding window to full screen reveals stack trace as below

Atom: 1.18.0 x64
Electron: 1.3.15
OS: Debian GNU/Linux
Thrown From: luna-studio package 1.0.0

Stack Trace

Uncaught TypeError: parsed.forEach is not a function

At /home/andy/.luna/config/luna-studio/1.0/atom/packages/luna-studio/lib/projects.coffee:160

TypeError: parsed.forEach is not a function
    at Request._callback (/packages/luna-studio/lib/projects.coffee:160:32)
    at Request.self.callback (/packages/settings-view/node_modules/request/request.js:186:22)
    at emitTwo (events.js:106:13)
    at Request.emit (events.js:191:7)
    at /packages/settings-view/node_modules/request/request.js:1163:10)
    at emitOne (events.js:96:13)
    at Request.emit (events.js:188:7)
    at /packages/settings-view/node_modules/request/request.js:1085:12)
    at IncomingMessage.g (events.js:286:16)
    at emitNone (events.js:91:20)
    at IncomingMessage.emit (events.js:185:7)
    at endReadableNT (_stream_readable.js:974:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickCallback (internal/process/next_tick.js:98:9)

Commands

  3x -0:37.5.0 dev-live-reload:reload-all (atom-workspace.workspace.scrollbars-visible-always)
     -0:12.6.0 tree-view:show (atom-workspace.workspace.scrollbars-visible-always.theme-luna-syntax.theme-luna-dark-ui)

Non-Core Packages

advanced-open-file 0.16.6 
busy-signal 1.4.3 
color-picker 2.2.5 
column-select 0.2.0 
cursor-history 0.11.1 
custom-window-title 1.0.4 
file-icons 2.1.11 
git-blame 1.2.2 
git-history 3.3.0 
git-log 0.4.1 
git-plus 7.9.3 
hasklig 0.4.0 
highlight-line 0.12.0 
highlight-selected 0.13.1 
intentions 1.1.5 
language-gitignore 0.3.0 
language-haskell 1.13.2 
luna-dark-ui 0.1.1 
luna-dpi 0.1.2 
luna-studio 1.0.0 
luna-syntax 0.1.0 
minimap 4.29.6 
minimap-codeglance 0.4.7 
minimap-cursorline 0.2.0 
minimap-find-and-replace 4.5.2 
minimap-git-diff 4.3.1 
minimap-highlight-selected 4.6.1 
multi-cursor 2.1.5 
sort-lines 0.14.0 
split-diff 1.5.0 
web-view 3.0.0 

Parametric Types Don't Mention Referenced Properties

Given a function which uses properties on a value:

1516183545

The type doesn't mention the referenced properties:

1516183527

I read the polymorphism as "forall b d" but it seems like I can't use the function for all types, I can only use the function when the value has a "mappend2" method.

Is the type I'm reading in the use of "mappend" accurate? Is it just not being printed correctly?

I see this as a big problem, because I can't determine the implementation of a function by reading the type, like I can usually do with polymorphic types. I don't know what values a function can take by looking at the type.

Incorrect typecheck case

I've run into this wrong typecheck:
screen shot 2017-09-05 at 13 04 37 2
Expected type: [Int]
Actual type: *

What is more, in function powers type is correct:
screen shot 2017-09-05 at 13 04 53 2

Code:

def main:
    powers 1 . take 100
def powers s:
    Prepend s (powers ((-2)*s))

proper message when luna started not in project folder

[sylwia@linux luna]$ ./dist-package/appimage/out/luna.AppImage 
Found the standard library at: /tmp/.mount_luna.AYiagHO/usr/config/env/Std
Requested module: Std.Base
Compiling module: Std.Base
Requested module: Std.HTTP
Compiling module: Std.HTTP
Requested module: Std.System
Compiling module: Std.System
Requested module: Std.Time
Compiling module: Std.Time
Requested module: Std.WebSockets
Compiling module: Std.WebSockets
/tmp/.mount_luna.AYiagHO/usr/src/: /tmp/.mount_luna.AYiagHO/usr/src/: getSymbolicLinkStatus: does not exist (No such file or directory)
Requested module: Main.Main
luna: user error (Pattern match failure in do expression at src/Luna/Shell.hs:174:5-18)

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.