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

sen_bills não funciona #56

Open
MartinsRodrigo opened this issue Oct 13, 2021 · 1 comment
Open

sen_bills não funciona #56

MartinsRodrigo opened this issue Oct 13, 2021 · 1 comment

Comments

@MartinsRodrigo
Copy link

MartinsRodrigo commented Oct 13, 2021

Prezados, a função sen_bills está dando erro mesmo quando tento rodar o exemplo que vocês utilizam. A mensagem que aparece é a seguinte:

Erro: `.x` must be a list, not NULL
Run `rlang::last_error()` to see where the error occurred.
@RobertMyles
Copy link
Collaborator

Oi Rodrigo, tudo bem? Vi agora que não está funcionando mesmo:

> congressbr::sen_bills(bill_id = 2021)
Error: `.x` must be a list, not NULL
Run `rlang::last_error()` to see where the error occurred.
> httr::GET("https://legis.senado.gov.br/dadosabertos/materia/2021")
Response [https://legis.senado.gov.br/dadosabertos/materia/2021]
  Date: 2021-10-20 19:53
  Status: 200
  Content-Type: application/json;charset=UTF-8
  Size: 4.25 kB
{
	"DetalheMateria" : {
		"@xmlns:xsi" : "http://www.w3.org/2001/XMLSchema-instance",
		"@xsi:noNamespaceSchemaLocation" : "http://legis.senado.leg.br/dadosabertos...
		"Metadados" : {
			"Versao" : "20/10/2021 16:52:52",
			"VersaoServico" : "7",
			"DataVersaoServico" : "2021-09-14",
			"DescricaoDataSet" : "Detalhes da matéria. ATENÇÃO: para pesquisar requeri...
		},
...

Vou tentar achar o que mudou no API mas infelizmente não tenho muito tempo no momento para ajudar com isso.
No enquanto, usando httr::GET("https://legis.senado.gov.br/dadosabertos/materia/2021") |> httr::content() vai te dar a informação numa lista, talvez seja util.

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