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

the extension doesn't work on trove.nla.gov.au #183

Open
bruh-creater opened this issue Aug 21, 2022 · 4 comments
Open

the extension doesn't work on trove.nla.gov.au #183

bruh-creater opened this issue Aug 21, 2022 · 4 comments

Comments

@bruh-creater
Copy link

bruh-creater commented Aug 21, 2022

I tried zooming in and out and nothing happened. Also, I tried tiles.yauml method. Dezoomify wont download the image.

the yauml code

# This is a tiles.yaml file for dezoomify-rs
# For more information about how to adapt this file to your use case, see:
# https://github.com/lovasoa/dezoomify-rs/wiki/Usage-example-for-the-custom-YAML-dezoomer

# The url of individual tiles, where {{ expressions }} will be evaluated using the variables below
url_template: "https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-{{X}}-{{Y}}"

# x_template and y_template tell dezoomify-rs where to place a tile on the canvas once it has been downloaded
# Here, for instance, the tile at (x=1, y=1) goes to position (256, 256)
x_template: "x * tile_size"
y_template: "y * tile_size"

variables:
  - { name: x, from: 0, to: 23 } # Image width, in tiles
  - { name: y, from: 0, to: 26 } # Image height, in tiles
  - { name: tile_size, value: 256 }

headers:
  # Specifying a Referer makes the server believe we come from that URL.
  Referer: "https://trove.nla.gov.au/7"

# The title is not mandatory either, but it makes dezoomify-rs
# create a file with an appropriate filename
title: "A Palace"

Hello everyone,

I am having issues when trying to download https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-{{x}}-{{y}}

Dezoomify reports:

Uncaught Error: Unable to find a proper dezoomer for:
https://trove.nla.gov.au/newspaper/static/page.js?_=NEWS-11.2.0

(https://dezoomify.ophir.dev/dezoomers/automatic.js:30)

I don't understand this message. Can someone please help me ?

@lovasoa
Copy link
Owner

lovasoa commented Aug 21, 2022

https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-{{X}}-{{Y}} doesn't seem to be a valid image pattern :

https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-0-0

@lovasoa lovasoa transferred this issue from lovasoa/dezoomify Aug 21, 2022
@bruh-creater
Copy link
Author

now I got this error
Uncaught Error: Unable to find a proper dezoomer for:
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-0-0

(https://dezoomify.ophir.dev/dezoomers/automatic.js:30)

@bruh-creater
Copy link
Author

bruh-creater commented Aug 22, 2022

since tile7 is the highest quality image
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-3
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-4
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-5
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-6
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-7
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-8
.
.
.
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-28

https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-7-3
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-8-3
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-9-3
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-10-3
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-11-3
.
.
.
https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-24-3

I put those into the yauml file as follows...

This is a tiles.yaml file for dezoomify-rs

For more information about how to adapt this file to your use case, see:

https://github.com/lovasoa/dezoomify-rs/wiki/Usage-example-for-the-custom-YAML-dezoomer

The url of individual tiles, where {{ expressions }} will be evaluated using the variables below

url_template: "https://trove.nla.gov.au/imageservice/nla.news-page5653/tile7-{{X}}-{{Y}}"

x_template and y_template tell dezoomify-rs where to place a tile on the canvas once it has been downloaded

Here, for instance, the tile at (x=1, y=1) goes to position (256, 256)

x_template: "x * tile_size"
y_template: "y * tile_size"

variables:

  • { name: x, from: 7, to: 24 } # Image width, in tiles
  • { name: y, from: 3, to: 28 } # Image height, in tiles
  • { name: tile_size, value: 256 }

headers:

Specifying a Referer makes the server believe we come from that URL.

Referer: "https://trove.nla.gov.au/7"

The title is not mandatory either, but it makes dezoomify-rs

create a file with an appropriate filename

title: "A Palace"


when I run the yauml file I got

Enter an URL or a path to a tiles.yaml file:
D:\Downloads\tiles.yaml
[ETA:0s] ######################################## 0/0 Computing the URLs of the image tiles...
[2022-08-22T01:00:50Z ERROR dezoomify_rs::custom_yaml] Invalid tiles.yaml file: Variable identifier is not bound to anything by context: "X".
ERROR PNG encoding error: Zero width not allowed
Enter an URL or a path to a tiles.yaml file:
D:\Downloads\tiles.yaml
[ETA:0s] ######################################## 0/0 Computing the URLs of the image tiles...
[2022-08-22T01:06:43Z ERROR dezoomify_rs::custom_yaml] Invalid tiles.yaml file: Variable identifier is not bound to anything by context: "X".
ERROR PNG encoding error: Zero width not allowed
Enter an URL or a path to a tiles.yaml file:

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