Giter Site home page Giter Site logo

Comments (8)

clrxbl avatar clrxbl commented on June 28, 2024 1

If that's all, that the hooks config needs to be updated every time, I can fix the hooks processor (since I caused this). Unless you're already on this @clrxbl :)

I haven't had the time to look into this yet no; so feel free to.

from gitlabform.

amimas avatar amimas commented on June 28, 2024 1

that the hooks config needs to be updated every time

I can't think of an alternative. If there are ideas, please share.

I can fix the hooks processor (since I caused this)

If you're able to help out, that's wonderful but I wouldn't say you caused this. I believe we collectively discussed in the #635 to make an improvement so that less api call is made to gitlab. If I recall properly, there weren't even any existing acceptance tests for hooks config processor but there is now. Besides, bugs will show up. It's okay. Most importantly, contributor's time and effort is always appreciated. 🤗

from gitlabform.

amimas avatar amimas commented on June 28, 2024

Thanks for reporting. Could you share the config example? Is this happening for a new project config or just processing existing project? Also are you able to run gitlabform with debug enabled? Debug logs might be help.

from gitlabform.

clrxbl avatar clrxbl commented on June 28, 2024

Thanks for reporting. Could you share the config example? Is this happening for a new project config or just processing existing project? Also are you able to run gitlabform with debug enabled? Debug logs might be help.

Processing existing projects.

I can only provide an example config of how I've configured it:

group/*:
  hooks:
    "http://example.com":
      push_events: false
      job_events: true
      pipeline_events: true
      token: ${TOKEN}

from gitlabform.

amimas avatar amimas commented on June 28, 2024

This is probably breaking somewhere around the following line:

lambda k: hook_config[k] != gl_hook_dict[k],

Latest update tries to match what's configured in gitlab vs gitlabform config. If there's no change, no need to update the hook in gitlab; one less api call.

The issue is that token is special in a way that it's not available in the response when hooks are retrieved from gitlab; because it's treated as secret.

This is not being handled in the code right now. PR is welcome. Would you be able to help contribute a fix?

from gitlabform.

amimas avatar amimas commented on June 28, 2024

Also, since we can't confirm whether the token changed in the config file vs what's in gitlab, I guess we do need to update hook configuration every time.

from gitlabform.

TigreModerata avatar TigreModerata commented on June 28, 2024

If that's all, that the hooks config needs to be updated every time, I can fix the hooks processor (since I caused this). Unless you're already on this @clrxbl :)

from gitlabform.

amimas avatar amimas commented on June 28, 2024

The fix is now available in v3.9.1

from gitlabform.

Related Issues (20)

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.