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

Getting "ActiveModel::RangeError in NotificationsController#sync " errors #3612

Closed
1 of 2 tasks
joaopgrassi opened this issue Feb 22, 2024 · 4 comments
Closed
1 of 2 tasks

Comments

@joaopgrassi
Copy link

Are you experiencing this issue in octobox.io or your own instance?

  • octobox.io
  • My instance

If your issue is related to an Octobox.io subscription purchase please ensure you have installed the Octobox GitHub App for the repositories concerned.

Summary of Problem

(Please answer all 3)

  • What are you trying to do?
    Refresh the page or trigger sync manually

  • What happens?
    I get a error page "ActiveModel::RangeError in NotificationsController#sync "

2148162568 is out of range for ActiveModel::Type::Integer with limit 4 bytes

  def sync(remote_subject)
    update({
      repository_full_name: extract_full_name_from_remote_subject(remote_subject),
      github_id: remote_subject['id'],
      state: remote_subject['merged_at'].present? ? 'merged' : remote_subject['state'],

Rails.root: /usr/src/app

Application Trace | Framework Trace | Full Trace
app/models/subject.rb:48:in `sync'
app/models/subject.rb:75:in `sync'
lib/octobox/notifications/sync_subject.rb:25:in `update_subject_in_foreground'
app/workers/update_subject_worker.rb:8:in `perform'
config/initializers/custom_sidekiq_worker.rb:9:in `perform_async_if_configured'
lib/octobox/notifications/sync_subject.rb:14:in `update_subject'
app/models/notification.rb:160:in `update_from_api_response'
app/services/download_service.rb:65:in `block in process_notifications'
app/services/download_service.rb:60:in `each'
app/services/download_service.rb:60:in `process_notifications'
app/services/download_service.rb:47:in `fetch_new_notifications'
app/services/download_service.rb:26:in `download'
app/models/user.rb:88:in `sync_notifications_in_foreground'
app/controllers/notifications_controller.rb:139:in `sync' 
  • What should have happened?

No errors when syncing

Steps to Reproduce the Issue

Not sure exactly, I subscribe to several repos and sometimes this is happening. I didn't upgrade the version or anything.

Versions, Operating System and Hardware

  • Which version/commit of Octobox are you using?
    Docker image january-2024

  • Which browser are you accessing Octobo with?
    Firefox 122.0.1

  • Windows? Linux? Mac?
    Windows

  • How are you deploying Octobox (Docker, Heroku, Openshift, etc)
    Docker

@andrew
Copy link
Member

andrew commented Feb 22, 2024

I fixed it in 202d5f6 last night, would you like me to publish a new docker image?

@joaopgrassi
Copy link
Author

Wow nice! Yeah if that is not a hassle, it would be great! Thanks for the great work!

@andrew
Copy link
Member

andrew commented Feb 23, 2024

@joaopgrassi
Copy link
Author

Seems to work now! Thanks for the quick fix

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

No branches or pull requests

2 participants