presence.nvim icon indicating copy to clipboard operation
presence.nvim copied to clipboard

Doesn't work with R files

Open leana8959 opened this issue 2 years ago • 3 comments
trafficstars

Description

presence.nvim doesn't show anything when buffer is an R file.

Shows this error(cf. logs):
[presence.nvim] Failed to set activity in Discord: Received error event - child "activity" fails because [child "assets" fails because [child "large_text" fails because ["large_text" length must be at least 2 characters long]]] (code 4000)

Neovim version

NVIM v0.8.3
Build type: Release
LuaJIT 2.1.0-beta3

OS information

macOS 13.2.1

Steps to reproduce

  1. Setup presence.nvim
    Here the part of my config that differs (or matters) from the default config. My blacklist is set to {}
require "presence".setup({
        ...
	auto_update         = true,
	neovim_image_text   = "I use NeoVim btw",
	main_image          = "file",
	log_level           = "debug",
	blacklist           = {},
	workspace_text      = "Natural Habitat: %s/",
        ...
})
  1. open R file nvim foo.r

Logs

[presence.nvim] Setting up plugin for macos
[presence.nvim] Using user-defined Discord client id
[presence.nvim] Using Discord IPC socket path: /var/folders/h_/y8rnhn092_x_rrvvfqwxlkb00000gn/T/discord-ipc-0
[presence.nvim] Checking Discord IPC socket at /var/folders/h_/y8rnhn092_x_rrvvfqwxlkb00000gn/T/discord-ipc-0...
[presence.nvim] Using id bbea6f3a-f68f-4231-a8fc-6587f5243d12
[presence.nvim] Completed plugin setup
[presence.nvim] Getting nvim socket paths...
[presence.nvim] Executing command: `netstat -u|grep --color=never "nvim.*/0"`
[presence.nvim] Checked Discord IPC socket, looks good!
[presence.nvim] Handling BufEnter event...
[presence.nvim] Connecting to Discord...
[presence.nvim] Connected to Discord
[presence.nvim] Authorizing with Discord...
[presence.nvim] Wrote message to pipe
[presence.nvim] Got nvim socket paths: {}
[presence.nvim] No other remote nvim instances
[presence.nvim] Authorized with Discord for [redacted]
[presence.nvim] Parsed filename foo.r with r extension
[presence.nvim] Getting project name for /Users/leana/repos/leana/learn-git...
[presence.nvim] Setting activity for /Users/leana/repos/leana/learn-git/foo.r...
[presence.nvim] Using file asset: { "R", "r" }
[presence.nvim] Repository URL has user specified: ssh://git@[redacted]/leana/learn-git.git
[presence.nvim] Adding button with repository URL: https://[redacted]/leana/learn-git.git
[presence.nvim] Attaching buttons to activity: { {^@    label = "View Repository",^@    url = "https://[redacted]/leana/learn-git.git"^@  } }
[presence.nvim] Detected project: learn-git
[presence.nvim] Sync activity to all peers...
[presence.nvim] Setting Discord activity...
[presence.nvim] Wrote message to pipe
[presence.nvim] Failed to set activity in Discord: Received error event - child "activity" fails because [child "assets" fails because [child "large_text" fails because ["large_text" length must be at least 2 characters long]]] (code 4000)

leana8959 avatar Apr 03 '23 22:04 leana8959

length must be at least 2 characters long

So .c and .h files don't work either? ;-;

Lamby777 avatar Jun 27 '23 23:06 Lamby777

@Lamby777 I'm not sure, could you verify that?
I actually stopped using this plugin for a while, since I open more than one instance of nvim, it doesn't know which one to show as the current file. But that's another story.
Also, I'll be travelling, so I won't be able help with issue for a while. Sorry :P

leana8959 avatar Jun 28 '23 18:06 leana8959

@Lamby777 I'm not sure, could you verify that? I actually stopped using this plugin for a while, since I open more than one instance of nvim, it doesn't know which one to show as the current file. But that's another story. Also, I'll be travelling, so I won't be able help with issue for a while. Sorry :P

I'm still trying to get it to work (last post on #116) but I'll try when it's up. Maybe someone else seeing this could try it sooner?

Lamby777 avatar Jun 28 '23 18:06 Lamby777