Skip to content
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

git.latest reports deleted tags in remote repo as new_tags in changes #48299

dosercz opened this issue Jun 25, 2018 · 3 comments


None yet
4 participants
Copy link

commented Jun 25, 2018

After deleting tag deleted-tag in github repo (deleted-tag is present in local git repo) git.latest produced these output:

          ID: repo
    Function: git.latest
      Result: True
     Comment: Repository /home/me/repo is up-to-date
     Started: 17:02:53.334089
    Duration: 4084.445 ms
                  - deleted-tag

It's strange and confusing that this is reported as new_tags, because this is not newly added. It was there before and was only deleted in remote repo. I have not seen this change with older salt versions.
IMO this tag should be deleted in this case to keep repo up-to-date.


    - name:
    - rev: master
    - target: /home/me/repo
    - force_checkout: True
    - force_fetch: True
    - force_reset: True

Versions Report

Salt Version:
           Salt: 2018.3.1

Dependency Versions:
           cffi: Not Installed
       cherrypy: Not Installed
       dateutil: 2.5.3
      docker-py: Not Installed
          gitdb: 2.0.0
      gitpython: 2.1.1
          ioflo: Not Installed
         Jinja2: 2.9.4
        libgit2: Not Installed
        libnacl: Not Installed
       M2Crypto: 0.24.0
           Mako: 1.0.6
   msgpack-pure: Not Installed
 msgpack-python: 0.4.8
   mysql-python: 1.3.7
      pycparser: Not Installed
       pycrypto: 2.6.1
   pycryptodome: Not Installed
         pygit2: Not Installed
         Python: 2.7.13 (default, Nov 24 2017, 17:33:09)
   python-gnupg: Not Installed
         PyYAML: 3.12
          PyZMQ: 16.0.2
           RAET: Not Installed
          smmap: 2.0.1
        timelib: Not Installed
        Tornado: 4.4.3
            ZMQ: 4.2.1

System Versions:
           dist: debian 9.4
         locale: UTF-8
        machine: x86_64
        release: 4.9.0-6-amd64
         system: Linux
        version: debian 9.4

This comment has been minimized.

Copy link

commented Jun 25, 2018

@terminalmage Thoughts?


This comment has been minimized.

Copy link

commented Aug 23, 2018

This is because the current code is just using a symmetric difference of the two sets of tags. I've corrected that and am writing a test for this case now.


This comment has been minimized.

Copy link

commented Aug 24, 2018

Fixed in #49305.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.