Roi
11 בינואר, 2023, 12:55pm
1
As mentioned here I have errors when using some queries in the data explorer .
Here’s a query for the data explorer plugin :
SELECT user_id, updated_at, value from user_custom_fields
WHERE name = 'telegram_chat_id'
I get Internal Server Error when I copy this statement into a new data explorer query.
If I try the statement directly on the database, it works.
Strange. I tried some other of the standard queries available. Some work, but I also got the same error for other queries.
Other queries which came with Discourse installation also have the Internal Server Error, e.g.:
Who has been sending the most messages in the last week?
Most Common Likers
Others work.
And, as mentioned, when I use the Telegram query directly on the database, it works, too.
david
(David Taylor)
11 בינואר, 2023, 1:07pm
2
Can you check /logs on your site and see if there is any more detail on the errors?
Roi
11 בינואר, 2023, 1:13pm
3
Sure. Is that helping? I got it by copying it. But in the browser I see more.
Message (15 copies reported)
ActiveModel::MissingAttributeError (missing attribute: admin)
app/models/concerns/roleable.rb:14:in `staff?'
lib/plugin/instance.rb:297:in `public_send'
lib/plugin/instance.rb:297:in `block (2 levels) in add_to_class'
(eval):7:in `_fast_attributes'
app/controllers/application_controller.rb:414:in `block in with_resolved_locale'
app/controllers/application_controller.rb:414:in `with_resolved_locale'
lib/middleware/omniauth_bypass_middleware.rb:74:in `call'
lib/content_security_policy/middleware.rb:12:in `call'
lib/middleware/anonymous_cache.rb:366:in `call'
config/initializers/100-quiet_logger.rb:20:in `call'
config/initializers/100-silence_logger.rb:29:in `call'
lib/middleware/enforce_hostname.rb:24:in `call'
lib/middleware/request_tracker.rb:228:in `call'
Backtrace
activemodel (7.0.3.1) lib/active_model/attribute.rb:226:in `value'
activemodel (7.0.3.1) lib/active_model/attribute_set/builder.rb:43:in `fetch_value'
activerecord (7.0.3.1) lib/active_record/attribute_methods/read.rb:38:in `_read_attribute'
activemodel (7.0.3.1) lib/active_model/attribute_methods.rb:277:in `admin'
app/models/concerns/roleable.rb:14:in `staff?'
plugins/discourse-animated-avatars/plugin.rb:90:in `block (2 levels) in activate!'
lib/plugin/instance.rb:297:in `public_send'
lib/plugin/instance.rb:297:in `block (2 levels) in add_to_class'
activesupport (7.0.3.1) lib/active_support/core_ext/object/try.rb:15:in `public_send'
activesupport (7.0.3.1) lib/active_support/core_ext/object/try.rb:15:in `try'
Env
HTTP HOSTS: www.sidemount-forum.com
david
(David Taylor)
11 בינואר, 2023, 1:19pm
4
From that backtrace, it seems like it could be related to the animated-avatars plugin, which is very strange! (cc @featheredtoast - any ideas?)
Can you check that your site and all plugins are up-to-date?
FWIW I have just installed Animated Avatars to repro this bug - Incompatibility between Cakeday,Data-Explorer and Animated Avatar plugins - #3 by JammyDodger and I also cannot run the ‘Top 100 Likers’ query on my test site (but can here on Meta).
david
(David Taylor)
11 בינואר, 2023, 1:23pm
6
Oh that’s interesting - must be the same cause. Let’s keep things over in the other topic:
I have both of these plugins installed.
The URL to view anniversaries (/cakeday/anniversaries/today) gives this error:
[image]
Complete logs:
I tried to dig into the exact issue here, to me the most relevant lines are here:
app/models/concerns/roleable.rb:14:in `staff?'
plugins/discourse-animated-avatars/plugin.rb:90:in `block (2 levels) in activate!'
...
plugins/discourse-animated-avatars/plugin.rb:94:in `block (2 levels) in activate!'
...
app/controllers/application_controller.rb:519:…