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

Jira_facts deprecation warnings #330

Closed
Kidswiss opened this issue Sep 29, 2020 · 1 comment · Fixed by #342
Closed

Jira_facts deprecation warnings #330

Kidswiss opened this issue Sep 29, 2020 · 1 comment · Fixed by #342
Assignees

Comments

@Kidswiss
Copy link

Kidswiss commented Sep 29, 2020

Affected Puppet, Ruby, OS and module versions/distributions

  • Puppet: 6.18.0
  • Ruby: ruby 2.7.0p0 (2019-12-25 revision 647ee6f091)
  • Distribution: Ubuntu 20.04
  • Module version: 4.0.1

How to reproduce (e.g Puppet code you use)

class { 'jira::facts': }

What are you seeing

Warning: Facter: external fact file "/etc/facter/facts.d/jira_facts.rb" had output on stderr: /etc/facter/facts.d/jira_facts.rb:17: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open

What behaviour did you expect instead

No warnings

Output log

Warning: Facter: external fact file "/etc/facter/facts.d/jira_facts.rb" had output on stderr: /etc/facter/facts.d/jira_facts.rb:17: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open
Info: Using configured environment 'CustomerInfra'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Retrieving locales
Info: Loading facts
Warning: Facter: external fact file "/etc/facter/facts.d/jira_facts.rb" had output on stderr: /etc/facter/facts.d/jira_facts.rb:17: warning: calling URI.open via Kernel#open is deprecated, call URI.open directly or use URI#open
Info: Caching catalog for jira01-qual.node.customer.cloud
Notice: Applied catalog in 14.88 seconds
@Kidswiss
Copy link
Author

Kidswiss commented Sep 29, 2020

Using following changes to /etc/facter/facts.d/jira_facts.rb seem to fix the problem:

+  info = OpenURI.open_uri(url, &:read)
-  info = open(url, &:read)

@kenyon kenyon self-assigned this Feb 3, 2021
kenyon added a commit to kenyon/puppet-jira that referenced this issue Feb 3, 2021
kenyon added a commit to kenyon/puppet-jira that referenced this issue Feb 10, 2021
kenyon added a commit to kenyon/puppet-jira that referenced this issue Feb 10, 2021
kenyon added a commit to kenyon/puppet-jira that referenced this issue Feb 14, 2021
kenyon added a commit to kenyon/puppet-jira that referenced this issue Feb 15, 2021
Fixes voxpupuli#330.

Co-authored-by: Ewoud Kohl van Wijngaarden <ewoud@kohlvanwijngaarden.nl>
cegeka-jenkins pushed a commit to cegeka/puppet-jira that referenced this issue Oct 13, 2021
Fixes voxpupuli#330.

Co-authored-by: Ewoud Kohl van Wijngaarden <ewoud@kohlvanwijngaarden.nl>
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 a pull request may close this issue.

2 participants