Code Monkey home page Code Monkey logo

Comments (11)

zignig avatar zignig commented on September 26, 2024

They appear in the server logs at the moment, the intent is to display them formatted in the web pages going forward.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

Where are the server logs? I don't see any on disk in the src/server directory, and I still don't have any errors showing up in the terminal when I should.

from cqparts-server.

zignig avatar zignig commented on September 26, 2024

they should come up in the STDOUT of the bin server. it runs python in a cmd in /src/server/build.go the cmd is running python2.7 on my system so that may be the issue.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

I don't know if it will help, but here's my terminal output.

$ ./server -d ~/Downloads/cqparts_demo/ 
[GIN-debug] [WARNING] Creating an Engine instance with the Logger and Recovery middleware already attached.

[GIN-debug] [WARNING] Running in "debug" mode. Switch to "release" mode in production.
 - using env:	export GIN_MODE=release
 - using code:	gin.SetMode(gin.ReleaseMode)

index.tmpl
[GIN-debug] GET    /                         --> main.main.func1 (3 handlers)
[GIN-debug] GET    /static/*name             --> main.Static (3 handlers)
[GIN-debug] GET    /model/*filepath          --> github.com/gin-gonic/gin.(*RouterGroup).createStaticHandler.func1 (3 handlers)
[GIN-debug] HEAD   /model/*filepath          --> github.com/gin-gonic/gin.(*RouterGroup).createStaticHandler.func1 (3 handlers)
[GIN-debug] GET    /events                   --> main.event (3 handlers)
[GIN-debug] POST   /notify                   --> main.notify (3 handlers)
[GIN-debug] POST   /snapshot                 --> main.snapshot (3 handlers)
watching : /home/jwright/Downloads/cqparts_demo/
[GIN-debug] Listening and serving HTTP on :8080
test.py

[GIN] 2018/05/26 - 22:02:36 | 200 |     563.958µs |       127.0.0.1 | GET      /
[GIN] 2018/05/26 - 22:02:36 | 404 |         668ns |       127.0.0.1 | GET      /favicon.ico
[GIN] 2018/05/26 - 22:03:37 | 404 |         830ns |       127.0.0.1 | GET      /favicon.ico
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next
event "/home/jwright/Downloads/cqparts_demo/test.py": WRITE
next

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

Nothing seems to make it to STDOUT for me. One of the things I tried was the logging method outlined here. I was hoping to log out the version of Python the script sees, but can't seem to do it.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

On my 17.10 system if Go just calls python it will use 2.7.14. I have to explicitly run python3 to get 3.6.

from cqparts-server.

zignig avatar zignig commented on September 26, 2024

OK I know what's going on. I do my editing in a Vim editor when it is saved it does an atomic move of the file and the server catches the REMOVE , when you are saving your file it's doing a WRITE and it's not triggering the execution. What editor are you using ?

Some minor code changes and it will work, Probably get to it tonight (UTC+8) as I have RealLife(TM) interrupting my quality coding time.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

I'm using Atom, but have been known to use GEdit and Vim depending on the situation. The editor in the FreeCAD module saves in a similar way to Atom I think. I'm not sure if any users will ever be mixing this server and the FreeCAD module though.

Probably get to it tonight (UTC+8)

No hurry. I'm UTC-5 and will be going to bed soon-ish. It's a holiday weekend in the US too, so not sure when I'll be able to fit tinkering in.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

Thanks!

from cqparts-server.

zignig avatar zignig commented on September 26, 2024

Try a fresh pull and build it should fix your notify issue.

from cqparts-server.

jmwright avatar jmwright commented on September 26, 2024

I can see the errors now. Thanks.

from cqparts-server.

Related Issues (2)

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.