Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Oct 27 12:18
    codecov[bot] commented #1191
  • Oct 27 12:18
    codecov[bot] commented #1191
  • Oct 27 12:15
    codecov[bot] commented #1191
  • Oct 27 12:15
    codecov[bot] commented #1191
  • Oct 27 12:10
    codecov[bot] commented #1191
  • Oct 27 12:10
    Grackins synchronize #1191
  • Oct 27 09:44
    codecov[bot] commented #1191
  • Oct 27 09:44
    Grackins synchronize #1191
  • Oct 26 11:46
    josalhor closed #1124
  • Oct 22 18:44

    andreyv on master

    BugFix: Italian contest exporte… (compare)

  • Oct 22 18:44
    andreyv closed #1196
  • Oct 22 18:44
    andreyv closed #1195
  • Oct 22 18:44
    andreyv commented #1196
  • Oct 21 17:37
    codecov[bot] commented #1196
  • Oct 21 17:37
    codecov[bot] commented #1196
  • Oct 21 17:33
    codecov[bot] commented #1196
  • Oct 21 17:33
    MarcoUCM commented #1196
  • Oct 21 17:33
    codecov[bot] commented #1196
  • Oct 21 17:28
    codecov[bot] commented #1196
  • Oct 21 17:28
    MarcoUCM synchronize #1196
Huseyn Hajiyev
@computerbox124
which one is important ?
Andrey Vihrov
@andreyv
The *.log files
Huseyn Hajiyev
@computerbox124
commands.log
isolate --box-id=88 --cg --cg-timing --chdir=/tmp --dir=/tmp=/tmp/cms-evaluate-lwu49ynb/home:rw --dir=/etc/alternatives=/etc/alternatives --env=HOME=/tmp --fsize=1048576 --stdin=/tmp/input.txt --cg-mem=66560 --stdout=/tmp/output.txt --processes=1000 --stderr=/tmp/stderr.txt --time=1 --wall-time=3 --meta=/tmp/cms-evaluate-lwu49ynb/run.log.0 --run -- /usr/bin/python3 Simple_Check
run.log.0
time:0.026
time-wall:0.067
max-rss:8964
csw-voluntary:5
csw-forced:5
cg-mem:4180
exitcode:0
Andrey Vihrov
@andreyv
Looks like this is the sandbox for the solution itself. What are the full errors from CMS?
Huseyn Hajiyev
@computerbox124
`evaluate on 4055 against dataset 32, testcase 2' failed, see worker logs and (possibly) sandboxes at '/tmp/cms-evaluate-b5mk7ws6 /tmp/cms-check-f5i0xjc7'.
Andrey Vihrov
@andreyv
Check the second sandbox at /tmp/cms-check-f5i0xjc7.
Huseyn Hajiyev
@computerbox124
root@localhost:/tmp/cms-check-f5i0xjc7/home# cat trusted_stderr_0.txt
terminate called after throwing an instance of 'std::logic_error'
what(): basic_string::_M_construct null not valid
Andrey Vihrov
@andreyv

OK, I see the problem.

int ans=ouf.readInt(1,100000,0);

The third argument is the variable name. Here it is 0, which is a null pointer literal. You should replace it with a real variable name, or omit the third argument.

Huseyn Hajiyev
@computerbox124
Thank you @andreyv ! I will check it
Huseyn Hajiyev
@computerbox124
Thank you @andreyv ! It works !
Andrey Vihrov
@andreyv
Good to hear that!
Huseyn Hajiyev
@computerbox124
how , is it possible to clear queue in cms ?
I have faced with situation when workers started to be disabled automatically
will restart of server help to solve this issue ?
Huseyn Hajiyev
@computerbox124
I have solved issue by making all problems output only and then restarting the server
Vu Duc Nhi
@vdnhi
Hi all, is there any way to extend contest time for a specific list of participation?
Andrey Vihrov
@andreyv
@vdnhi Contest time can be extended for individual participants in the admin interface. You can write a script or a database query to update it for many participants. Also you can extend the whole contest.
Vu Duc Nhi
@vdnhi
@andreyv thanks for your help, I'll try
Don-Khue Le
@khuebeo
Hi there, I recently setup a contest running with 32 workers on a 64-core machine
Lots of submissions got this verdict: Execution timed out (wall clock limit exceeded)
A quick google search helped me understanding what does it mean
But my question is how to avoid that?
Andrey Vihrov
@andreyv
@khuebeo Do you have enough RAM for 32 evaluations? Do you have swap and is swap used? Also, did you check disk I/O load, perhaps I/O wait is stalling evaluations?
Don-Khue Le
@khuebeo
yes, I believe I have enough RAM
but probably the I/O load is high
Marco Romagnoli
@romagnolimarco
Hi everybody. I'd like to import all Users and luckly as many Tasks as possible, from and old CMS (1.3) running on a VPS to a new VPS running the new cms 1.4.rc1. Is there a less painfull as possible solution to this? I'll be forever gratefull for your precius advices. Thanks. (For user something like cmsImportUser --all, ok, but how to export, is there a cmsexportUser ?)
Andrey Vihrov
@andreyv
@romagnolimarco Check out cmsDumpExporter and cmsDumpImporter, these should do what you need. See https://cms.readthedocs.io/en/v1.4/Installation.html#updating-cms. Although, I think, users who are not added to the dumped contests won't be exported.
Marco Romagnoli
@romagnolimarco
Thank You Andrey. I tried but it give me an error: The dump you're trying to import has been created by an old version of CMS (it declares data model version 25). It may take a while to adapt it to the current data model (which is version 39). You can use cmsDumpUpdater to update the on-disk dump and speed up future imports.
No problem I saved the Compiled tasks and reimported one by one.
Actually the Error Msg was " TypeError: Found incompatible key 'Da decimale a binario.%l' for value <cms.db.submission.File object at 0x7fe69cf57278>; this collection's keying function requires a key of 'Da20decimale20a__20binario.%l' for this value."
As I mentioned I solved importing the Tasks one by one.
Andrey Vihrov
@andreyv
@romagnolimarco Oh, codenames can't contain spaces, and there was a fix for this a while ago in cms-dev/cms@9da2d14. Though you should have gotten a better error message, maybe some fields were missed in the fix. You could work around this by replacing spaces with _ in the relevant fields before export. Anyway, glad to hear that you solved it.
Marco Romagnoli
@romagnolimarco
@andreyv : Thank You, sooo much. I removed the submissions with spaces and run again cmsDumpExporter and cmsDumpImporter, Now I could import all Users, plus previous submissions and Tasks.
Marco Romagnoli
@romagnolimarco
I'd like to propose one little improvement in the documentation regarding the installation af cms 1.4. on page: https://cms.readthedocs.io/en/v1.4/Running%20CMS.html#running-cms-configuring-cms , reading the paragraph : "Configuring the DB" there is a kind of "spaghetti" GOTO in the middle of the explained process with postgress console active: " Then you may need to adjust the CMS configuration to contain the correct database parameters. See Configuring CMS." Actually without explaining how to exit postgres. Doing step by step (spaghetti goto included) exactly as the documentation suggest bring two warnings plus an error when running cmsInitDB: " WARNING [<unknown>] I/O error while opening file /usr/local/etc/cms.conf: [EACCES] Permission denied
  • WARNING [<unknown>] No configuration file found: falling back to default values.
    • CRITICAL [<unknown>] Operational error while talking to the DB. Is the connection string in cms.conf correct?" I suggest to add the detail of how to exit postgress before running the command "cmsInitDB". Than need to underline the necessity of running sudo ./prerequisites.py install after the changhe in cms.conf, before running cmsInitDB. Newbies (like me long ago) can stuck there without idea how to get rid of it and complete the installation in a proper way. Thanks.
Andrey Vihrov
@andreyv

@romagnolimarco Thanks, good suggestion. How does this line look before "Then you may need to adjust…":

After running these commands, return to the initial shell by executing exit or pressing Ctrl+D.

Regarding the second question, there already is a note about prerequisites.py in the end.

Marco Romagnoli
@romagnolimarco
Yes, it looks O.K. to me.
1 reply
Marco Romagnoli
@romagnolimarco
The Note about prerequisites.py to re-run is there, But the sentence " or you could simply edit the previously installed configuration files (which are usually found in /usr/local/etc/ or /etc/), if you do not plan on running that command ever again." is misleading, in the sense that is indeed Necessary to Re-Run the script, if You followed the tutorial step by step and modified the files cms.conf ... than You have to do it. So my suggestion is to write a more clear sentence and give more evidence to it: Underlining, using bold font etc.. Thanks.
Marco Romagnoli
@romagnolimarco
I'd like to be more clear, but it will take a lot of lines of text to explain me (I beg Your Pardon, sorry). Long ago when I tired for the first time to install CMS, I went under a lot of Database Errors, and I was indeed following the cms.readthedocs.io. Then after some painfull "try and try again" I finally find "my" solution, it is written in the txt file that come with the Video Tutorial on how to install CMS (version 1.3) . You can find the link here: http://cms-dev.github.io/related.html (Tutorial
A video tutorial on how to install and run CMS, by Marco Romagnoli.) So I could finally run the cms, FIRST modifing ( changing the connection string given in database; changing username, password and database name) , saving cms.conf and cms.ranking.conf and running : sudo ./prerequisites.py install. Only Then I entered Postgres and create the user and the database. So Inverting the steps compared to the Docs it works, without errors. That is.
Marco Romagnoli
@romagnolimarco
Of course the process can be done in many different way, but following carefully ReadtheDocs should bring Newbies to Success not leaving them helpless in the middle of night . A good Sleep is better :-) .
Marco Romagnoli
@romagnolimarco
From my side, to contribute to the cause, my umble contribution can be, to update the Video Tutorial with the v1.4.rc1 Version (or maybe with the new 1.5) , when I'll find the time. Thanks for taking your time to read all this stuff.
Grace Hawkins
@Grackins
Hi! Anyone aware of how we can decrease randomness in workers' evaluation process?
I've already reduced the number of workers per machine to 1 and run isolate-check-environment script. Is there antoher option?
Andrey Vihrov
@andreyv
@Grackins Which language do you use for submissions? How much volatility do you observe? Is the machine a VM or a physical machine?
Java, for example, requires additional tuning, and even then is not completely deterministic. If the machines are virtual, then it is important to pin machine CPUs instead of sharing them with other VMs.
mihaitutu
@mihaitutu

Hello! My name is Mihai Tuțu and I am a teacher at a private school back in Romania. Because CMS is highly popular in the competitions my students go to, I want to implement it for practice contests. I have read much of the documentation and this communication channel, but still I have some questions.

For a contest of 3 hours with 40 participants, with solutions in C / C++, is one computer with CMS installed enough? What physical resources should this computer have?

Thanks!

4 replies
Vu Truong Giang
@goldenskygiang
Hi. I am interested in adding Logisim support to CMS, as my school has lab practices where students need to build digital circuits in Logisim and test them using text input files similar to programming problems. I think it will be similar to creating custom language and task type in CMS. However, I see that the CMS documentation does not cover in details about how programming task evaluation is handled and there is little information on implementing custom support. Could anyone here elaborate more on that?
Andrey Vihrov
@andreyv

@goldenskygiang To create a custom language, you need to add a language plugin, which will return compilation and evaluation commands for the language. See https://github.com/cms-dev/cms/blob/master/cms/grading/language.py#L29 for the interface and https://github.com/cms-dev/cms/tree/master/cms/grading/languages for examples.

About task types, you can see https://cms.readthedocs.io/en/latest/Task%20types.html to get a general understanding and then look at https://github.com/cms-dev/cms/tree/master/cms/grading/tasktypes for implementation examples.

If your tasks will have text inputs and text outputs, then likely you don't need a new task type, Batch should do fine.

5 replies
Jossemar Cordero
@jossemarGT

Hi CMS Community. I have been using CMS to bootstrap another idea. At the moment, I stumbled with the challenge of integrating other applications alongside all the CMS core ones. So I wanted to ask, how much complex do you think would be migrating CMS into gRPC? and could you give me some pointers where I should look at?

I am aware there is a custom RPC server implementation and models somewhere but I cannot spot them.

10 replies