Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 21:37
    Oldes commented #5140
  • 21:27
    Oldes commented #5140
  • 19:24
    Oldes commented #5157
  • 19:19
    Oldes commented #5157
  • 18:37
    Oldes opened #5157
  • Jul 02 07:42
    hiiamboris commented #5156
  • Jul 02 01:30
    ALANVF opened #5156
  • Jul 01 09:02

    qtxie on IO

    FIX: remove unused checking in … (compare)

  • Jun 30 18:13
    dockimbel labeled #5154
  • Jun 29 17:06
    hiiamboris commented #5155
  • Jun 29 16:52
    hiiamboris opened #5155
  • Jun 29 01:34
    qtxie opened #5154
  • Jun 28 12:36
    hiiamboris commented #4988
  • Jun 28 07:52
    meijeru commented #5
  • Jun 28 07:50
    hiiamboris commented #123
  • Jun 28 07:50
    meijeru closed #123
  • Jun 28 07:50
    meijeru commented #123
  • Jun 28 07:45
    meijeru opened #123
  • Jun 27 10:28
    hiiamboris closed #5153
  • Jun 27 10:28
    hiiamboris labeled #5153
GiuseppeChillemi
@GiuseppeChillemi
Good night Oldes, do not despair! We are humans. Our difficulties let us all exchange opinions and evolve. It's falling down and emitting strange sounds we learn to walk and talk.
koba-yu
@koba-yu

Though I have not read and understood all discussion here(Sorry, not have enough time and knowledge for me), I just want to comment
VS Code treats JSON and JSON with Comments as different languages.

https://drive.google.com/file/d/1rH2lXn1Nms_BDHamyNFMOBin7hgf-ufK/view?usp=sharing

Maybe this is one practical choice example that JSON and JSON with Comments are different.
If Red distinguishes them in the same way, JSON codec(if it is not JSON with Comments codec) does not allow comments is understandable.

Gregg Irwin
@greggirwin
Thanks for the info @koba-yu.
koba-yu
@koba-yu
@greggirwin Thank you for your reading!
packetrhino
@packetrhino
Question: is anyone familiar with the "expect" program that was based on TCL? Is there an equivalent for Red, at least under Linux/Unix systems?
Gregg Irwin
@greggirwin
There is no Excpect for Red...yet. I have Exploring Expect on my shelf, and have thought about implementing it at times. Step 1, I think is a CLI dialect that offers interrogation and feedback for itself, and sub-commands it may launch.
xqlab
@xqlab
@dockimbel maybe I was too hasty. I was thinking about something like a load-json: function with the optional refinement. But even with load/asis a solution possible. Offer a json-comment field under system\options, that can contain the wanted comment ways.
xqlab
@xqlab
from IParser (HAPI FHIR Structures - DSTU3 3.8.0 API)
   getHandleComments

    boolean getHandleComments()

    Whether to parse or ignore comments - either reading or writing

    setHandleComments

    IParser setHandleComments(boolean value)
Gringo
@15926222352
I now want to develop a DAPP in EOS block chain don't know if the community have the programmer would like to help me develop the DAPP I would like to pay with RED TOKEN
Gringo
@15926222352
Red team you should let the Red Community Token can play out the value of ICO for one year I didn't find Red scrip have any real value can not correctly reflect value
Boleslav Březovský
@rebolek
@15926222352 please, don't post same messages into multiple rooms. Thanks!
Gringo
@15926222352
@rebolek ok
Rudolf Meijer
@meijeru
I am using the Red progress site (https://progress.red-lang.org/) to stay abreast of developments. Until recently, it tracked all branches of the red/red repository on Github, but the latest activity on refactoring the lexer is not appearing there. Can @x8x, who I think is behind this site, explain?
Or is the site using a fixed list of branches?
Gringo
@15926222352
There will be language development in red DAPP programmers? I want to use red token to pay for development costs. Thanks
Gringo
@15926222352
Red language project team should organize more activities for example use red language as the foundation of application development or DAPP game development contract
@dockimbel
Petr Krenzelok
@pekr
I don't want to re-open the JSON codec, but codecs in general. As Gregg pointed out, we might have several codecs, given their size it might or might not be an ideal solution. Given the Redbol dynamic nature, I can imagine codecs having some /parsefunction and/or local storage of available parsers in a block. Imagine if some standard develops, and you might welcome versioning, it could be codec/parsers: [1.0 [.....] 1.2 [....]]. Any such storage is dynamically extendable, sortable, searchable, as it is a block or a map.
Vladimir Vasilyev
@9214
@15926222352 please use dedicated room to ask blockchain-specific questions (related to Red of course), and refrain from spamming.
FLuX
@x8x
@meijeru Hello Rudolf, please send me the links of what is not showing up so I can have a look, thank you!
Maciej Łoziński
@loziniak
>> load-json {^{^/  "name": "debug_002_RRDB_ESRGAN_x4_DIV2K"^}}
== #(
    name: "debug_002_RRDB_ESRGAN_x4_DIV2K"
)
>> load-json {^{^/  "name": "debug_002_RRDB_ESRGAN_x4_DIV2K" // comment ^/ ^}}
*** User Error: {Invalid json string. Near: ^{^^^{^^/  "name": "debug_002_RRDB_ESRGAN_x4_DI^}}
*** Where: ???

My thoughts are that @Oldes problem is perhaps not lack of comments support, but poor Red error message? A problem I also stumbled upon many times. Useful message would be Invalid json string. Near: ^{// comment^}, which would point exactly where the problem is.

Red is expressive enough that (provided you know where exactly your problem is) it's faster to write your own parse rule to clean comments than looking for a suitable npm library in JavaScript world.

Oldes Huhuman
@Oldes
@loziniak please... the JSON case is closed! But you are right, that the message should be better.. first of all it should not be User Error
Maciej Łoziński
@loziniak
Sometimes a closed case is a good start for a new case :-)
Vladimir Vasilyev
@9214

@loziniak in current codec implementation (which is not even 1.0, mind you), error reporting has coarse granularity, i.e. it marks location before malformed JSON value (object in this case), and reports it only after parsing have failed.

As for "poor Red messages" see red/red#3282 thread. Informative error reporting in dynamic and homoiconic language (such as Red) is not a trivial problem to solve.

Maciej Łoziński
@loziniak
@9214 great info, thanks! Apparently not a new case.
JacobGood1
@JacobGood1
I have probably linked these before, but I am just refreshing everyone's memory in case these examples, the ones from Pharo and Common Lisp, are forgotten.
lucindamichele
@lucindamichele
Thank you, @JacobGood1!
dsunanda
@dsunanda

@9214

I appreciate that error reporting is not trivial, but what we have at the moment is not fit for purpose. It may be more-or-less adequate when debugging the latest dozen lines of code writte while developing (9/10 times the problem is in those lines). But it seems to fundamentally put a limit on the size of Red systems - and/or the ability to easily integrate two separate code bases.

User example - a couple of weeks ago, I experimentally tried to convert a Rebol/Core system (60 scripts, 25,000 lines of code) to Red. I did not expect it to be easy or fun. But I was not expecting to be so misled by errors messages.

Take this one - it took a couple of hours of my life to resolve:

 type: 'script  id: 'invalid-type  arg1: word!  near: none  where: 'set-path

There is not a single instance of SET-PATH in the 60 scripts / 25,000 lines of code. So basically, not a single clue in the message where to start looking.

(If you are interested, the bug fix was to make the 'word in a FOREACH local to its function). I got a log of around 20 other errors which might as well have just said "Shrug. Magic bad".

So attacking the non-trivial problem with some priority could well be a unique selling point for Red.

Vladimir Vasilyev
@9214

There is not a single instance of SET-PATH

Error doesn't tell you that there's a problem with set-path! value, it prints out stack trace, in which set-path was the last called action. Not very informative, true, but hardly misleading.

dirtbagger
@dirtbagger
I am not a programmer, but from time to time I have a data-manipulation problem that I can't handle using off-the-shelf software. In cases like that I write the program I need. For the latest such project I set out wanting to try to write the program in Red, but when I found that I would have to learn using the Rebol documentation I decided to write in Rebol, with the aim of eventually converting to Red.
dirtbagger
@dirtbagger
Hmm, just learned not to hit return if I'm not finished a message. I'm new to this sort of message board. Anyway, to carry on, I now have a working program in Rebol. I started looking at what I'd have to do to convert it to Red. One problem I've found is that in Rebol I made extensive use of ports for file I/O. In other words, I used "open" and "close" a lot. These instructions don't seem to exist in Red. Am I missing something. Does Red not have a facility like ports for file I/O?
GiuseppeChillemi
@GiuseppeChillemi
@dirtbagger ports are being implemented, soon you will see them. Be patient, they are doing lot of work behind the scenes.
Vladimir Vasilyev
@9214
@dirtbagger ports are scheduled for 0.7.0 release. In the meantime, depending on your actual task, you can substitute them with read.
dsunanda
@dsunanda
@9214 Thanks. Actually, completely uniformative, as the last action called is irrelevant to the failure....If a SET-PATH was called, it was not (directly) from the user-level code. It might have well have said "Failure in something defined somewhere in SYSTEM. You're on your own". Red can do better than that - Rebol does (somewhat).
packetrhino
@packetrhino
@greggirwin there are many ports of "expect" like behavior to examine, such as Perl's Expect.pm , Python's pexpect or pyexpect, even Windows PowerShell has an "expect" like package.
Rudolf Meijer
@meijeru
@x8x basically it is all of the branches of the red/red repository that have new commits - you have shown thenegative-zero and the GTK branch last week, but this week there is activity in refactor-lexer and it does not show up. The links are like https://github.com/red/red/tree/refactor-lexer and similar for all branches.
FLuX
@x8x
@meijeru Thank you! I'll have a look and let you know.
FLuX
@x8x
@meijeru Should be fine now, please let me know if you spot issues again!
Rudolf Meijer
@meijeru
@x8x :+1:
Rudolf Meijer
@meijeru
I have just published a small program to check if you have the latest Red version. It is in my Gist
I have a suggestion: incorporate this in the current GUI console as a second option in the Help menu (after About).
Maciej Łoziński
@loziniak
User would probably never see "you are up-to-date" message with current speed of generating commits by the team! :-)
Rudolf Meijer
@meijeru
BTW in the red/gui-branch room I show how I added this facility myself to the console, by modifying the menu and the on-menu actor.
lucindamichele
@lucindamichele
I have just published a small program to check if you have the latest Red version. It is in my Gist
Very cool @meijeru !
Gregg Irwin
@greggirwin
@packetrhino thanks!
dirtbagger
@dirtbagger
Thanks to @GiuseppeChillemi and @9214 for the responses to my question about ports. On a more general question, does anyone have advice to offer on converting Rebol code to Red? My perhaps rather naive approach would be to just try running the Rebol code from the Red console and see what doesn't work. If there's a more efficient or systematic approach to use I'd be pleased to learn of it.
Vladimir Vasilyev
@9214
@dirtbagger Rebol2 and Red are highly compatible, I suggest to gradually copypaste Rebol bits, bottom-up, and check if they work as expected. In case something breaks - the best way to figure out what went wrong is to ask for help in our chat room.
Dave Andersen
@dander
@dirtbagger It would probably be helpful to look over this reference for differences before you start. And would be very helpful if you record any new things you find there as well!
Gregg Irwin
@greggirwin
Thanks @dander, yes, more info is always good.