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

(character): Add support for fetching minions #23

Open
1 of 10 tasks
ReidWeb opened this issue Dec 5, 2021 · 2 comments
Open
1 of 10 tasks

(character): Add support for fetching minions #23

ReidWeb opened this issue Dec 5, 2021 · 2 comments
Assignees
Labels
feature-request New feature or request

Comments

@ReidWeb
Copy link
Member

ReidWeb commented Dec 5, 2021

The ability to fetch the set of minions a character has is required.

These minions are presently contained on a sub-page on the lodestone so require a second GET, to fetch.

Use Case

  1. As a consumer of the lodestone module I should be able to ask it to fetch a character, and return the ids of all the minions they have. (Default)
  2. As a consumer of the lodestone module I should be able to ask it to fetch a character, and return the names of all the minions they have. (Expand)
  3. As a consumer of the lodestone module I should be able to ask it to fetch a character but specify not to fetch minions. (Disabled)
  4. As a consumer of the lodestone module I should be able to ask it to fetch a character's minions (either as IDs or expanded names) without fetching the whole character.

Proposed Solution

  • Implement Item lookup function MVP (just name)
  • Implement function to lookup a series of provided IDs
  • Implement function for retrieval of ids of minions
  • Implement function that calls minion id retrieval function than passes values to item lookup
  • In lodestoneClient.getCharacter(..) add an options object, with parameter fetchMinionNames of type boolean
  • If fetchMinionNames is true in options call invoke the function that fetches and looks up names
  • In lodestoneClient.getCharacter(..) add an options object, with parameter fetchMoundIds of type boolean
  • If fetchMinionIds is true in options call invoke the function that fetches just ids

Other

No modifications to Character.fromPage are required.

Possibility to resuse code from mount fetching here, they're very similar.

  • 👋 I may be able to implement this feature request
  • ⚠️ This feature might incur a breaking change

This is a 🚀 Feature Request

@ReidWeb ReidWeb added the feature-request New feature or request label Dec 5, 2021
@ReidWeb ReidWeb self-assigned this Dec 5, 2021
@ReidWeb ReidWeb moved this to Todo in XIVStats Rebuild Dec 5, 2021
@ReidWeb
Copy link
Member Author

ReidWeb commented Dec 5, 2021

From investigation there does not appear to be a way to fetch the item id of a minion without interacting with the DOM.

Image URLs are consistent between characters, so we may have to build up a database of those.

Minion names are not presented on the DOM without interaction either the only accessible attribute that is available is image urls such as https://img.finalfantasyxiv.com/lds/pc/global/images/itemicon/9e/9ed9a88950ba83a052d6f7c32efe5bd89530bac7.png?n6.0

ReidWeb added a commit that referenced this issue Jan 17, 2022
* fix(ci): disable jest report step for dependavot

* fix(ci): enable automerge for dependabot prs

* chore(deps): bump tmpl from 1.0.4 to 1.0.5

Bumps [tmpl](https://github.com/daaku/nodejs-tmpl) from 1.0.4 to 1.0.5.
- [Release notes](https://github.com/daaku/nodejs-tmpl/releases)
- [Commits](https://github.com/daaku/nodejs-tmpl/commits/v1.0.5)

---
updated-dependencies:
- dependency-name: tmpl
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix(ci): remove branch conditions from build

* chore(deps): bump nth-check from 2.0.0 to 2.0.1

Bumps [nth-check](https://github.com/fb55/nth-check) from 2.0.0 to 2.0.1.
- [Release notes](https://github.com/fb55/nth-check/releases)
- [Commits](fb55/nth-check@v2.0.0...v2.0.1)

---
updated-dependencies:
- dependency-name: nth-check
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* test(character): add test for character with shield

* fix(character): rename server attribute to be homeWorld

* feat(character): add support for parsing Reaper and Sage levels and as active class

fixes #19

* feat(character): remove parsing of waist gear

Remove support for parsing waist gear due to deprecation with the introduction of 6.0, remove tests.

closes #20

* fix(character): fix parsing of free company

Resolve issue where free company was being incorrectly parsed.

Fixes #21

* chore(gh): move to v2 of issue template for bug form

* chore(gh): Add emoji to title of bug report form

* chore(gh): complete move to gh-issue-templates v2

* chore(gh): fix link to docs in issue template

[skip ci]

* ci(actions): add option to suppress build to release workflow

* feat(creature): add support for parsing of mount and minion tooltips

re #22, re #23

* feat(pvpteam): add support for fetching the name and ID of a pvp team associated to a character

Implements #25

* feat(freecompany): update free company parsing to return both id and name

* chore(freecompany): fix file issues

* feat(creature): add asMapping method

* fix(tests): fix issue in character tests where strings were being treated as arrays

* chore(formatting): fix formatting of file

* refactor(class): Refactor manner in which classes are handled
Add support for localizations
Restructure significant chunks of code
Add support for fetching non-english site versions

* refactor(character): update character class map to use new style class

* chore(character): add html sample for lodestone maintenance

* refactor(all): restructure package structure (phase 1)

Migrate towards package/diretory structure structured by logical entity

* refactor(all): simplify language mapping types & rename server to world

* refactor(all): restructure directory structure further

* fix(all): fix bugs added in prior commit

* refactor(client): restructure clients to decompose core client

* ci(mergify): resolve issues with mergify strict mode deprecation

* ci(mergify): Fix tabbing of yml

* ci(mergify): Remove deprecated commit_message property

* ci(mergify): Fix name of ci job being checked

* ci(mergify): Remove status checks
github handles these

* ci(mergify): Re-add status check

* chore(deps): bump follow-redirects from 1.14.3 to 1.14.7 (#29)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Peter Reid <peter@reidweb.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* ci(tests): decouple unit and integration tests

Unit and integration tests no run on separate commands

#18

* style(itest): fix lint errors following previous change

* fix(ci): fix unit test script command

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
@ReidWeb
Copy link
Member Author

ReidWeb commented Jan 21, 2022

  • Verify that character 33000006 does not produce an error, should yield empty array
  • Verify that character 33000061 does not produce an error, should yield empty array

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request New feature or request
Projects
Status: Todo
Development

No branches or pull requests

1 participant