New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I lose at ACLs: load_acl: Exception with --no-db #269

Closed
supertylerc opened this Issue Apr 18, 2016 · 4 comments

Comments

Projects
None yet
2 participants
@supertylerc
Contributor

supertylerc commented Apr 18, 2016

I think this is failing because I specify --no-db but load_acl is still trying to use the database to manage the task queue. If I had to guess, I'd say this is where the queue gets set to None, but the complete method is still called on queue here.

I think that adding an if queue: immedately before this line would solve the problem, but there might be other problems or there might be a reason to not do this.

If that sounds reasonable, though, I'd be more than happy to submit a pull request.

Exception

$ load_acl --no-cm --bouncy --no-db acl.ios
Bouncy enabled, disabling multiple jobs.
Logging to /var/folders/k6/ppn9w1vx2dj7zj42v2sqpg6w0000gn/T/tmpO7LPBy_load_acl

Loading acl.ios OUT OF BOUNCE on 10.254.254.2

You are about to perform the following loads:

10.254.254.2                     acl.ios

NOTE: Parallel jobs disabled for out of bounce loads, this will take longer than usual.

Are you sure you want to proceed? yes

LOAD FAILED ON 10.254.254.2: [Failure instance: Traceback: <type 'exceptions.AttributeError'>: 'NoneType' object has no attribute 'complete'
/Users/tylerchristiansen/.virtualenvs/trigger/lib/python2.7/site-packages/twisted/internet/base.py:1087:connectionLost
/Users/tylerchristiansen/.virtualenvs/trigger/lib/python2.7/site-packages/trigger/twister.py:736:clientConnectionLost
/Users/tylerchristiansen/.virtualenvs/trigger/lib/python2.7/site-packages/twisted/internet/defer.py:393:callback
/Users/tylerchristiansen/.virtualenvs/trigger/lib/python2.7/site-packages/twisted/internet/defer.py:501:_startRunCallbacks
--- <exception caught here> ---
/Users/tylerchristiansen/.virtualenvs/trigger/lib/python2.7/site-packages/twisted/internet/defer.py:588:_runCallbacks
/Users/tylerchristiansen/.virtualenvs/trigger/bin/load_acl:551:complete
/Users/tylerchristiansen/.virtualenvs/trigger/bin/load_acl:501:clear_load_queue
]

                                                                _( (~\
         _ _                        /                          ( \> > \
     -/~/ / ~\                     :;                \       _  > /(~\/
    || | | /\ ;\                   |l      _____     |;     ( \/    > >
    _\\)\)\)/ ;;;                  `8o __-~     ~\   d|      \      //
   ///(())(__/~;;\                  "88p;.  -. _\_;.oP        (_._/ /
  (((__   __ \\   \                  `>,% (\  (\./)8"         ;:'  i
  )))--`.'-- (( ;,8 \               ,;%%%:  ./V^^^V'          ;.   ;.
  ((\   |   /)) .,88  `: ..,,;;;;,-::::::'_::\   ||\         ;[8:   ;
   )|  ~-~  |(|(888; ..``'::::8888oooooo.  :\`^^^/,,~--._    |88::  |
   |\ -===- /|  \8;; ``:.      oo.8888888888:`((( o.ooo8888Oo;:;:'  |
   |_~-___-~_|   `-\.   `        `o`88888888b` )) 888b88888P""'     ;
   ; ~~~~;~~         "`--_`.       b`888888888;(.,"888b888"  ..::;-'
     ;      ;              ~"-....  b`8888888:::::.`8888. .:;;;''
        ;    ;                 `:::. `:::OOO:::::::.`OO' ;;;''
   :       ;                     `.      "``::::::''    .'
      ;                           `.   \_              /
    ;       ;                       +:   ~~--  `:'  -';    ACL LOADS FAILED
                                     `:         : .::/
        ;                            ;;+_  :::. :..;;;         YOU LOSE
                                     ;;;;;;,;;;;;;;;,;

I'm pretty sure I love the severed head. Thanks. :)

Trigger Version

In [1]: import trigger

In [2]: trigger.__version__
Out[2]: (1, 5, 9)
@jathanism

This comment has been minimized.

Member

jathanism commented Apr 18, 2016

@supertylerc Hmm... We made some fixes to the acl machinery recently. What version of Trigger are you running?

@jathanism

This comment has been minimized.

Member

jathanism commented Apr 18, 2016

Well, no matter, you're linking against develop which is Trigger 1.5.10-pre. I think your assessment is spot-on! If you'd like to go ahead and patch it and see if that works, please submit it as a pull request and we can get it into Trigger 1.5.10 release and ship it! :)

@supertylerc

This comment has been minimized.

Contributor

supertylerc commented Apr 18, 2016

Oops. I suppose that would be helpful, huh? Sorry!

In [1]: import trigger

In [2]: trigger.__version__
Out[2]: (1, 5, 9)

@jathanism jathanism added the bug label Apr 18, 2016

@jathanism

This comment has been minimized.

Member

jathanism commented Apr 18, 2016

@supertylerc Hey, sorry, our responses got out of phase because I got jumpy. Plz my 2nd response right before your latest.

supertylerc added a commit to supertylerc/trigger that referenced this issue Apr 18, 2016

Don't complete when using `--no-db`
Specifying the `--no-db` switch causes `queue` to be set to `None`,
which is later send the `complete` message.  This makes it so that we
only call` queue.complete` if we didn't specify `--no-db`.

Fixes trigger#269.

supertylerc added a commit to supertylerc/trigger that referenced this issue Apr 18, 2016

Don't complete when using `--no-db`
Specifying the `--no-db` switch causes `queue` to be set to `None`,
which is later send the `complete` message.  This makes it so that we
only call` queue.complete` if we didn't specify `--no-db`.

Fixes trigger#269.

jathanism added a commit that referenced this issue Apr 18, 2016

Don't complete when using `--no-db` (#270)
Specifying the `--no-db` switch causes `queue` to be set to `None`,
which is later send the `complete` message.  This makes it so that we
only call` queue.complete` if we didn't specify `--no-db`.

Fixes #269.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment