GithubHelp home page GithubHelp logo

campoy / todo Goto Github PK

View Code? Open in Web Editor NEW
567.0 567.0 88.0 203 KB

A task manager written in Go using TDD techniques, each commit should represent a step in the application development.

License: Apache License 2.0

Shell 0.34% CSS 6.07% JavaScript 5.90% Go 81.20% HTML 6.49%

todo's People

Contributors

adg avatar campoy avatar haddock avatar hyaocuk avatar inm avatar rselbach 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

todo's Issues

build failing with gae 1.9.1

go version go1.2.1 (appengine-1.9.1) windows/amd64

Failed parsing input: app file server.go conflicts with same file imported from GOPATH

Seems the same issue as this though I am not sure how to fix it..

TaskManager is not safe for concurrent use

HTTP handlers can and will be called concurrently from multiple goroutines, but the TaskManager doesn't protect against race conditions. The easiest thing would be to add a sync.Mutex to TaskManager and lock it during Save, All, and Find. Also All needs to copy the slice before returning so that the internal slice isn't used unprotected by the Mutex.

Deadlock on slide 13 when running on playground

When I click on the "Run" button on slide 13, I get the following compilation error message:

fatal error: all goroutines are asleep - deadlock!

goroutine 16 [semacquire]:
sync.runtime_Syncsemacquire(0x10626430, 0x1)
    /tmp/sandbox/go/src/pkg/runtime/sema.goc:257 +0x120
sync.(*Cond).Wait(0x10626428, 0x10626420)
    /tmp/sandbox/go/src/pkg/sync/cond.go:62 +0x100
syscall.(*queue).waitRead(0x10626420, 0x1, 0x0, 0x0, 0x43ca80, 0x0, 0x0, 0x4e8a)
    /tmp/sandbox/go/src/pkg/syscall/net_nacl.go:262 +0x1a0
syscall.(*msgq).read(0x10626420, 0x106280f0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/syscall/net_nacl.go:376 +0xe0
syscall.(*netFile).accept(0x10652200, 0x4e8a, 0x10652200, 0x0, 0x0, 0x0, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/syscall/net_nacl.go:538 +0x80
syscall.Accept(0x3, 0x0, 0x2f9e70, 0x0, 0x0, 0x0, 0x0, 0xfeee1d88)
    /tmp/sandbox/go/src/pkg/syscall/net_nacl.go:752 +0xc0
net.accept(0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xfefc0000)
    /tmp/sandbox/go/src/pkg/net/sys_cloexec.go:42 +0x60
net.(*netFD).accept(0x10652240, 0x364318, 0x0, 0x0, 0x0, 0x10652240)
    /tmp/sandbox/go/src/pkg/net/fd_unix.go:406 +0x340
net.(*TCPListener).AcceptTCP(0x1060e2c8, 0xfeee1e70, 0x10, 0x0, 0x0, 0x106183f0)
    /tmp/sandbox/go/src/pkg/net/tcpsock_posix.go:234 +0x80
net/http.tcpKeepAliveListener.Accept(0x1060e2c8, 0x10622960, 0x0, 0x0, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/net/http/server.go:1947 +0x60
net/http.(*Server).Serve(0x106521c0, 0xfefd0578, 0x1060e2c8, 0xfeee1f24, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/net/http/server.go:1698 +0xc0
net/http.(*Server).ListenAndServe(0x106521c0, 0x4e8a, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/net/http/server.go:1688 +0x1c0
net/http.ListenAndServe(0x2fa488, 0x5, 0x0, 0x0, 0x0, 0x0)
    /tmp/sandbox/go/src/pkg/net/http/server.go:1778 +0xc0
main.main()
    /tmpfs/gosandbox-46b43f26_5eebf313_c3ba907d_d69ba1e6_9c32ab09/prog.go:14 +0xa0

goroutine 19 [finalizer wait]:
runtime.park(0x38bc0, 0x43c004, 0x436b69, 0x0)
    /tmp/sandbox/go/src/pkg/runtime/proc.c:1369 +0xc0
runtime.parkunlock(0x43c004, 0x436b69)
    /tmp/sandbox/go/src/pkg/runtime/proc.c:1385 +0x60
runfinq()
    /tmp/sandbox/go/src/pkg/runtime/mgc0.c:2644 +0x100
runtime.goexit()
    /tmp/sandbox/go/src/pkg/runtime/proc.c:1445
 [process exited with non-zero status]

Program exited.

Is that something you can reproduce?
Cheers

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.