Title: Not possible to create note in issue · Issue #1477 · python-gitlab/python-gitlab · GitHub
Open Graph Title: Not possible to create note in issue · Issue #1477 · python-gitlab/python-gitlab
X Title: Not possible to create note in issue · Issue #1477 · python-gitlab/python-gitlab
Description: Description of the problem, including code/CLI snippet I am unable to create notes. I am simply trying to do: project = ctx.projects.get(265) issue = project.issues.get(729) issue.notes.create({'body': 'note content'}) (Lifted pretty muc...
Open Graph Description: Description of the problem, including code/CLI snippet I am unable to create notes. I am simply trying to do: project = ctx.projects.get(265) issue = project.issues.get(729) issue.notes.create({'bo...
X Description: Description of the problem, including code/CLI snippet I am unable to create notes. I am simply trying to do: project = ctx.projects.get(265) issue = project.issues.get(729) issue.notes.create({...
Opengraph URL: https://github.com/python-gitlab/python-gitlab/issues/1477
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Not possible to create note in issue","articleBody":"## Description of the problem, including code/CLI snippet\r\nI am unable to create notes. I am simply trying to do:\r\n```\r\n project = ctx.projects.get(265)\r\n issue = project.issues.get(729)\r\n issue.notes.create({'body': 'note content'})\r\n```\r\n(Lifted pretty much strait from documentation)\r\n\r\n## Expected Behavior\r\nNote is posted\r\n\r\n## Actual Behavior\r\nAn exception is thrown:\r\n```\r\nTraceback (most recent call last):\r\n File \"./turris-os-milestone-rename.py\", line 60, in \u003cmodule\u003e\r\n main()\r\n File \"./turris-os-milestone-rename.py\", line 20, in main\r\n issue.notes.create({'body': 'note content'})\r\n File \"/usr/lib/python3.8/site-packages/gitlab/exceptions.py\", line 287, in wrapped_f\r\n return f(*args, **kwargs)\r\n File \"/usr/lib/python3.8/site-packages/gitlab/mixins.py\", line 325, in create\r\n return self._obj_cls(self, server_data)\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 62, in __init__\r\n self._create_managers()\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 151, in _create_managers\r\n manager = cls(self.manager.gitlab, parent=self)\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 290, in __init__\r\n self._computed_path = self._compute_path()\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 305, in _compute_path\r\n data = {\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 306, in \u003cdictcomp\u003e\r\n self_attr: getattr(self._parent, parent_attr, None)\r\n File \"/usr/lib/python3.8/site-packages/gitlab/base.py\", line 80, in __getattr__\r\n value = self.__dict__[\"_attrs\"][name]\r\nTypeError: list indices must be integers or slices, not str\r\n```\r\n\r\n## Specifications\r\n\r\n - python-gitlab version: 2.7.1\r\n - API version you are using (v3/v4): v4\r\n - Gitlab server version (or gitlab.com): 13.11.3","author":{"url":"https://github.com/Cynerd","@type":"Person","name":"Cynerd"},"datePublished":"2021-05-27T07:40:19.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":10},"url":"https://github.com/1477/python-gitlab/issues/1477"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:0a75570d-b375-d91c-eba7-035ab2149971 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BC3A:3F1336:908D8E3:BA7719F:69770B01 |
| html-safe-nonce | fc8d25440b1f16c6ad430cb8140fdcf451e4300a3289fe599881daec841847d4 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQzNBOjNGMTMzNjo5MDhEOEUzOkJBNzcxOUY6Njk3NzBCMDEiLCJ2aXNpdG9yX2lkIjoiMzAwMDUxODAwOTM0OTkzMzgyNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | f99d9294c979c5dbe755fa53e208156ac4317baa11bdb4379d9e35c4bed9077c |
| hovercard-subject-tag | issue:903345319 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python-gitlab/python-gitlab/1477/issue_layout |
| twitter:image | https://opengraph.githubassets.com/9bbdcd903479aeb8e328500d50147eba5422a6a658057a2f2a61b656f53bbe57/python-gitlab/python-gitlab/issues/1477 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/9bbdcd903479aeb8e328500d50147eba5422a6a658057a2f2a61b656f53bbe57/python-gitlab/python-gitlab/issues/1477 |
| og:image:alt | Description of the problem, including code/CLI snippet I am unable to create notes. I am simply trying to do: project = ctx.projects.get(265) issue = project.issues.get(729) issue.notes.create({'bo... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Cynerd |
| hostname | github.com |
| expected-hostname | github.com |
| None | 01d198479908d09a841b2febe8eb105a81af2af7d81830960fe0971e1f4adc09 |
| turbo-cache-control | no-preview |
| go-import | github.com/python-gitlab/python-gitlab git https://github.com/python-gitlab/python-gitlab.git |
| octolytics-dimension-user_id | 28886265 |
| octolytics-dimension-user_login | python-gitlab |
| octolytics-dimension-repository_id | 8077625 |
| octolytics-dimension-repository_nwo | python-gitlab/python-gitlab |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 8077625 |
| octolytics-dimension-repository_network_root_nwo | python-gitlab/python-gitlab |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f752335dbbea672610081196a1998e39aec5e14b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width