Re: [sage-devel] No output from GAP

2019-05-06 Thread E. Madison Bray
On Mon, May 6, 2019 at 12:25 AM Andrey Novoseltsev wrote: > > OK, here is me not trying to rely on implicit printing by REPL: > > sage: gap.eval("Print({});".format(10^1)) > '10' > sage: gap.eval("Print({});".format(10^10)) > '100' > sage: gap.eval("Print({});".format(10^100)) > '' > > Is

Re: [sage-devel] No output from GAP

2019-05-05 Thread Nils Bruin
On Sunday, May 5, 2019 at 3:25:27 PM UTC-7, Andrey Novoseltsev wrote: > > OK, here is me not trying to rely on implicit printing by REPL: > > sage: gap.eval("Print({});".format(10^1)) > '10' > sage: gap.eval("Print({});".format(10^10)) > '100' > sage: gap.eval("Print({});".format(10^100))

Re: [sage-devel] No output from GAP

2019-05-05 Thread Andrey Novoseltsev
OK, here is me not trying to rely on implicit printing by REPL: sage: gap.eval("Print({});".format(10^1)) '10' sage: gap.eval("Print({});".format(10^10)) '100' sage: gap.eval("Print({});".format(10^100)) '' Is gap pexpect interface still used internally? If not, it seems that consistent

Re: [sage-devel] No output from GAP

2019-05-05 Thread Nils Bruin
On Sunday, May 5, 2019 at 12:04:32 PM UTC-7, Andrey Novoseltsev wrote: > > > It seems to me that the best fix for the current situation is to prohibit > using files completely. Any reasons NOT to do it? > > One reason is that pexpect has a rather high per-character overhead, so when sending over

Re: [sage-devel] No output from GAP

2019-05-05 Thread Andrey Novoseltsev
Here is the logic of executing GAP commands via files: if it has := before " write it to file as is otherwise wrap it in Print( ) execute via Read() which has no input on its own However when multiple commands are fed into gap.eval as in the original post, they all are combined into a single

Re: [sage-devel] No output from GAP

2019-05-03 Thread E. Madison Bray
On Fri, May 3, 2019 at 5:10 PM E. Madison Bray wrote: > > On Fri, May 3, 2019 at 5:06 PM E. Madison Bray wrote: > > > > On Mon, Apr 29, 2019 at 2:30 AM Andrey Novoseltsev > > wrote: > > > > > > Hello, > > > > > > I got a report about GAP problem in SageMathCell, but it looks like the > > > GAP

Re: [sage-devel] No output from GAP

2019-05-03 Thread E. Madison Bray
On Fri, May 3, 2019 at 5:06 PM E. Madison Bray wrote: > > On Mon, Apr 29, 2019 at 2:30 AM Andrey Novoseltsev wrote: > > > > Hello, > > > > I got a report about GAP problem in SageMathCell, but it looks like the GAP > > interface in Sage itself is having issues. I am getting an empty string > >

Re: [sage-devel] No output from GAP

2019-05-03 Thread E. Madison Bray
On Mon, Apr 29, 2019 at 2:30 AM Andrey Novoseltsev wrote: > > Hello, > > I got a report about GAP problem in SageMathCell, but it looks like the GAP > interface in Sage itself is having issues. I am getting an empty string from > the following command: > sage: print(gap.eval(""" > : D_4 := S

Re: [sage-devel] No output from GAP

2019-04-30 Thread Andrey Novoseltsev
The use case here is: take a snippet of GAP code, execute it, and display the result. GAP is one of the languages "supported" by SageMathCell and it is done via print gap.eval(...) It is not really for users of Sage who need GAP functionality, it is an easy way for GAP users to embed live compu

Re: [sage-devel] No output from GAP

2019-04-30 Thread Dima Pasechnik
On Tue, Apr 30, 2019 at 1:37 PM E. Madison Bray wrote: > > On Tue, Apr 30, 2019 at 6:55 AM Dima Pasechnik wrote: > > > > On Tue, Apr 30, 2019 at 1:18 AM Andrey Novoseltsev > > wrote: > > > > > > On Monday, 29 April 2019 14:20:39 UTC-6, Dima Pasechnik wrote: > > >> > > >> would it be easier to s

Re: [sage-devel] No output from GAP

2019-04-30 Thread E. Madison Bray
On Tue, Apr 30, 2019 at 6:55 AM Dima Pasechnik wrote: > > On Tue, Apr 30, 2019 at 1:18 AM Andrey Novoseltsev wrote: > > > > On Monday, 29 April 2019 14:20:39 UTC-6, Dima Pasechnik wrote: > >> > >> would it be easier to switch to libgap? > > > > > > Do you mean this? > > http://doc.sagemath.org/h

Re: [sage-devel] No output from GAP

2019-04-29 Thread Dima Pasechnik
On Tue, Apr 30, 2019 at 1:18 AM Andrey Novoseltsev wrote: > > On Monday, 29 April 2019 14:20:39 UTC-6, Dima Pasechnik wrote: >> >> would it be easier to switch to libgap? > > > Do you mean this? > http://doc.sagemath.org/html/en/reference/libs/sage/libs/gap/libgap.html?highlight=libgap#sage.libs.

Re: [sage-devel] No output from GAP

2019-04-29 Thread Andrey Novoseltsev
On Monday, 29 April 2019 14:20:39 UTC-6, Dima Pasechnik wrote: > > would it be easier to switch to libgap? > Do you mean this? http://doc.sagemath.org/html/en/reference/libs/sage/libs/gap/libgap.html?highlight=libgap#sage.libs.gap.libgap.Gap.eval There is however a restriction on no trailing sem

Re: [sage-devel] No output from GAP

2019-04-29 Thread Dima Pasechnik
would it be easier to switch to libgap? On Mon, Apr 29, 2019 at 5:54 PM Andrey Novoseltsev wrote: > > Reminded me of this old issue with Macaulay2 many years ago: > https://trac.sagemath.org/ticket/5467 I wonder if it is something similar > here... > > -- > You received this message because you

Re: [sage-devel] No output from GAP

2019-04-29 Thread Andrey Novoseltsev
Reminded me of this old issue with Macaulay2 many years ago: https://trac.sagemath.org/ticket/5467 I wonder if it is something similar here... -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emai

Re: [sage-devel] No output from GAP

2019-04-29 Thread Andrey Novoseltsev
Thank you for the confirmation and debugging, Vincent! It was pointed out to me that we even have it documented: http://doc.sagemath.org/html/en/reference/interfaces/sage/interfaces/gap.html#long-input Is it really that difficult to fix??? Surely there has to be some reason and solution for this

Re: [sage-devel] No output from GAP

2019-04-28 Thread Vincent Delecroix
The option `allow_use_file` seems to be the problem as setting it to False make the issue disappear. sage: for i in range(10): : print(i) : gap.eval("D_4 := SmallGroup(8,3);;" + "IsSolvable(D_4);"*i, allow_use_file=False) 0 '' 1 'true' 2 'true\ntrue' 3 'true\ntrue\ntrue' 4 'true

Re: [sage-devel] No output from GAP

2019-04-28 Thread Vincent Delecroix
I confirm the bug on arch. It seems to me that there is something related to the "input length" (but nothing about the specific commands) sage: for i in range(10): : print(i) : gap.eval("D_4 := SmallGroup(8,3);;" + "IsSolvable(D_4);" * i) 0 '' 1 'true' 2 'true\ntrue' 3 'true\ntrue

[sage-devel] No output from GAP

2019-04-28 Thread Andrey Novoseltsev
Hello, I got a report about GAP problem in SageMathCell, but it looks like the GAP interface in Sage itself is having issues. I am getting an empty string from the following command: sage: print(gap.eval(""" : D_4 := SmallGroup(8,3); : IsAbelian( D_4 ); : List( ConjugacyClasses( D_4