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

Add srpm-build to replace tito build #232

Merged
merged 1 commit into from
Aug 12, 2020

Conversation

ehelms
Copy link
Member

@ehelms ehelms commented Mar 19, 2020

I'm sure this could use some cleaning up, and tests. I would appreciate some early feedback.

obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
@ehelms ehelms force-pushed the add-srpm-build branch 2 times, most recently from 70629a8 to fa2a7d6 Compare April 7, 2020 01:32
@ehelms ehelms marked this pull request as ready for review April 7, 2020 01:42
ekohl
ekohl previously requested changes Apr 7, 2020
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
@ehelms ehelms force-pushed the add-srpm-build branch 3 times, most recently from 192b683 to 378e080 Compare April 7, 2020 13:41
@ehelms
Copy link
Member Author

ehelms commented Apr 7, 2020

@evgeni Can you help me understand this error? Coming from pylint but locally the code works.

E:  6, 0: No name 'chdir' in module 'ansible.module_utils' (no-name-in-module)
E:  6, 0: Unable to import 'ansible.module_utils.chdir' (import-error)

@evgeni
Copy link
Member

evgeni commented Apr 7, 2020

You can ignore that.
Ansible does weird things for importing from module_utils, and pylint doesn't know about that. So it can't find the code and bails.

@ehelms ehelms force-pushed the add-srpm-build branch 6 times, most recently from 36a05c1 to 3562873 Compare April 7, 2020 19:45
@ehelms
Copy link
Member Author

ehelms commented Apr 8, 2020

@evgeni Curious if you had any thoughts. The error is:

TASK [build_srpm : Build SRPM] *************************************************
fatal: [hello]: FAILED! => changed=false 
  msg: Failed to build srpm
  output: |-
    unlock hello-2.10.tar.gz
      this has not yet been committed to git; cannot unlock it
    failed
    git-annex: unlock: 1 failed

I do not see this error locally. As I understand it, the test code copies the source in, and does the git annex add and commit before this would be ran: https://github.com/theforeman/obal/blob/master/tests/test_functional.py#L24

@ehelms ehelms added this to the 1.0.0 milestone May 13, 2020
@ehelms ehelms force-pushed the add-srpm-build branch 3 times, most recently from 3696e9f to 43f0491 Compare August 7, 2020 19:41
@ehelms
Copy link
Member Author

ehelms commented Aug 7, 2020

@evgeni From your experience, since this passes locally, does this look like an issue with how the repository gets set up, my code or version of git annex?

@evgeni
Copy link
Member

evgeni commented Aug 7, 2020

Most probably the annex version used. Given to this runs on old Ubuntu... You could reconfigure the tests to run on Ubuntu 20.04 (need to explicitly config that, latest still points at 18.04).

@ehelms ehelms force-pushed the add-srpm-build branch 2 times, most recently from 859ecec to 9bee451 Compare August 7, 2020 20:15
@ehelms
Copy link
Member Author

ehelms commented Aug 7, 2020

That did it, thanks @evgeni !

obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Show resolved Hide resolved
obal/data/roles/build_srpm/tasks/main.yaml Outdated Show resolved Hide resolved
obal/data/module_utils/chdir.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Show resolved Hide resolved
tests/test_functional.py Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
obal/data/modules/srpm.py Outdated Show resolved Hide resolved
@ehelms ehelms force-pushed the add-srpm-build branch 2 times, most recently from f50b6a1 to f46166d Compare August 11, 2020 13:47
@evgeni evgeni merged commit bec3997 into theforeman:master Aug 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants