Project

Profile

Help

Issue #2722

closed

Local variable 'published_after_predistributor' referenced before assignment"

Added by ipanova@redhat.com almost 7 years ago. Updated over 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
2.13.1
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Sprint 19
Quarter:

Description

1. create repo with yum and rsync dist
2. publish with rsync --> observe skipped publish result
3. publish with rsync again and observe the traceback

Operations:       publish
Resources:        test-repo380 (repository)
State:            Failed
Start Time:       2017-04-19T12:12:41Z
Finish Time:      2017-04-19T12:12:41Z
Result:           N/A
Task Id:          497cf91a-350c-4fd8-83b9-72b386dd3aff
Progress Report:  
Traceback:        Traceback (most recent call last):   File
                  "/usr/lib/python2.7/site-packages/celery/app/trace.py", line
                  240, in trace_task     R = retval = fun(*args, **kwargs)  
                  File
                  "/home/ipanova/pulp_development/pulp/server/pulp/server/async/
                  tasks.py", line 506, in __call__     return super(Task,
                  self).__call__(*args, **kwargs)   File
                  "/home/ipanova/pulp_development/pulp/server/pulp/server/async/
                  tasks.py", line 107, in __call__     return super(PulpTask,
                  self).__call__(*args, **kwargs)   File
                  "/usr/lib/python2.7/site-packages/celery/app/trace.py", line
                  437, in __protected_call__     return self.run(*args,
                  **kwargs)   File
                  "/home/ipanova/pulp_development/pulp/server/pulp/server/contro
                  llers/repository.py", line 1106, in publish     result =
                  check_publish(repo_obj, dist_id, dist_inst, transfer_repo,
                  conduit, call_config)   File
                  "/home/ipanova/pulp_development/pulp/server/pulp/server/contro
                  llers/repository.py", line 1164, in check_publish    
                  skip_for_predistributor = (predistributor_id and
                  (published_after_predistributor or UnboundLocalError: local
                  variable 'published_after_predistributor' referenced before
                  assignment 
Actions #1

Updated by ttereshc almost 7 years ago

  • Sprint/Milestone set to 37
  • Triaged changed from No to Yes
Actions #2

Updated by dalley almost 7 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to dalley
Actions #3

Updated by dalley almost 7 years ago

  • Status changed from ASSIGNED to POST

Added by dalley almost 7 years ago

Revision 417b88e3 | View on GitHub

Fix 'referenced before assignment' errors

Fix several cases where variables defined behind conditionals are referenced elsewhere in the code from an upper scope.

closes #2722 https://pulp.plan.io/issues/2722

Actions #4

Updated by jortel@redhat.com almost 7 years ago

  • Sprint/Milestone changed from 37 to 38
Actions #5

Updated by dalley almost 7 years ago

  • Status changed from POST to MODIFIED
Actions #7

Updated by bizhang almost 7 years ago

  • Platform Release set to 2.13.1
Actions #8

Updated by bizhang almost 7 years ago

  • Status changed from MODIFIED to 5
Actions #10

Updated by bizhang almost 7 years ago

  • Status changed from 5 to CLOSED - CURRENTRELEASE
Actions #11

Updated by bmbouter about 6 years ago

  • Sprint set to Sprint 19
Actions #12

Updated by bmbouter about 6 years ago

  • Sprint/Milestone deleted (38)
Actions #13

Updated by bmbouter almost 5 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF